From c963d75dfdeec11f82e79e727062fbf89afa2c04 Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Sun, 22 Apr 2012 09:19:23 +1000 Subject: Update EFL to latest beta. --- libraries/evas/src/lib/Evas.h | 310 +++++++++++++------ libraries/evas/src/lib/Evas_GL.h | 2 +- libraries/evas/src/lib/Makefile.am | 10 +- libraries/evas/src/lib/Makefile.in | 21 +- libraries/evas/src/lib/cache/Makefile.am | 1 - libraries/evas/src/lib/cache/Makefile.in | 9 +- libraries/evas/src/lib/cache/evas_cache_image.c | 338 +++++++++++---------- libraries/evas/src/lib/canvas/Makefile.am | 1 - libraries/evas/src/lib/canvas/Makefile.in | 15 +- libraries/evas/src/lib/canvas/evas_callbacks.c | 9 + libraries/evas/src/lib/canvas/evas_events.c | 17 +- libraries/evas/src/lib/canvas/evas_map.c | 34 ++- libraries/evas/src/lib/canvas/evas_object_image.c | 40 ++- libraries/evas/src/lib/canvas/evas_object_main.c | 19 +- .../evas/src/lib/canvas/evas_object_textblock.c | 180 ++++++++--- libraries/evas/src/lib/canvas/evas_render.c | 63 +++- libraries/evas/src/lib/cserve/Makefile.in | 8 +- libraries/evas/src/lib/engines/Makefile.in | 8 +- libraries/evas/src/lib/engines/common/Makefile.am | 2 +- libraries/evas/src/lib/engines/common/Makefile.in | 10 +- .../evas/src/lib/engines/common/evas_draw_main.c | 65 +++- .../evas/src/lib/engines/common/evas_font_load.c | 8 +- .../evas/src/lib/engines/common/evas_image_main.c | 77 ++++- .../src/lib/engines/common/evas_op_add/Makefile.in | 8 +- .../lib/engines/common/evas_op_blend/Makefile.am | 6 +- .../lib/engines/common/evas_op_blend/Makefile.in | 13 +- .../lib/engines/common/evas_op_copy/Makefile.in | 8 +- .../lib/engines/common/evas_op_mask/Makefile.in | 8 +- .../src/lib/engines/common/evas_op_mul/Makefile.in | 8 +- .../src/lib/engines/common/evas_op_sub/Makefile.in | 8 +- .../src/lib/engines/common/evas_polygon_main.c | 8 +- .../src/lib/engines/common/evas_scale_sample.c | 3 +- .../common/evas_scale_smooth_scaler_downx.c | 6 +- .../common/evas_scale_smooth_scaler_downx_downy.c | 6 +- .../common/evas_scale_smooth_scaler_downy.c | 6 +- libraries/evas/src/lib/engines/common/evas_tiler.c | 96 ++++-- .../evas/src/lib/engines/common_16/Makefile.in | 8 +- .../evas/src/lib/engines/common_8/Makefile.in | 8 +- libraries/evas/src/lib/file/Makefile.am | 3 - libraries/evas/src/lib/file/Makefile.in | 10 +- libraries/evas/src/lib/file/evas_module.c | 4 - libraries/evas/src/lib/file/evas_path.c | 4 +- libraries/evas/src/lib/include/Makefile.in | 8 +- libraries/evas/src/lib/include/evas_blend_ops.h | 12 +- libraries/evas/src/lib/include/evas_common.h | 92 +++--- libraries/evas/src/lib/include/evas_private.h | 3 + 46 files changed, 1029 insertions(+), 554 deletions(-) (limited to 'libraries/evas/src/lib') diff --git a/libraries/evas/src/lib/Evas.h b/libraries/evas/src/lib/Evas.h index b85bbeb..67d3018 100644 --- a/libraries/evas/src/lib/Evas.h +++ b/libraries/evas/src/lib/Evas.h @@ -2,9 +2,10 @@ @mainpage Evas @version 1.1 -@date 2000-2011 +@date 2000-2012 Please see the @ref authors page for contact details. +@link Evas.h Evas API @endlink @link Evas.h Evas API @endlink @@ -489,7 +490,7 @@ typedef enum _Evas_Event_Flags { EVAS_EVENT_FLAG_NONE = 0, /**< No fancy flags set */ EVAS_EVENT_FLAG_ON_HOLD = (1 << 0), /**< This event is being delivered but should be put "on hold" until the on hold flag is unset. the event should be used for informational purposes and maybe some indications visually, but not actually perform anything */ - EVAS_EVENT_FLAG_ON_SCROLL = (1 << 1) /**< This event flag indicates the event occurs while scrolling; for exameple, DOWN event occurs during scrolling; the event should be used for informational purposes and maybe some indications visually, but not actually perform anything */ + EVAS_EVENT_FLAG_ON_SCROLL = (1 << 1) /**< This event flag indicates the event occurs while scrolling; for example, DOWN event occurs during scrolling; the event should be used for informational purposes and maybe some indications visually, but not actually perform anything */ } Evas_Event_Flags; /**< Flags for Events */ /** @@ -501,7 +502,7 @@ typedef enum _Evas_Touch_Point_State EVAS_TOUCH_POINT_UP, /**< Touch point is released */ EVAS_TOUCH_POINT_MOVE, /**< Touch point is moved */ EVAS_TOUCH_POINT_STILL, /**< Touch point is not moved after pressed */ - EVAS_TOUCH_POINT_CANCEL /**< Touch point is calcelled */ + EVAS_TOUCH_POINT_CANCEL /**< Touch point is cancelled */ } Evas_Touch_Point_State; /** @@ -527,7 +528,7 @@ typedef enum _Evas_Colorspace EVAS_COLORSPACE_YCBCR422P709_PL,/**< YCbCr 4:2:2 Planar, ITU.BT-709 specifications. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb, then Cr rows */ EVAS_COLORSPACE_RGB565_A5P, /**< 16bit rgb565 + Alpha plane at end - 5 bits of the 8 being used per alpha byte */ EVAS_COLORSPACE_GRY8, /**< 8bit grayscale */ - EVAS_COLORSPACE_YCBCR422601_PL, /**< YCbCr 4:2:2, ITU.BT-601 specifications. The data poitned to is just an array of row pointer, pointing to line of Y,Cb,Y,Cr bytes */ + EVAS_COLORSPACE_YCBCR422601_PL, /**< YCbCr 4:2:2, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to line of Y,Cb,Y,Cr bytes */ EVAS_COLORSPACE_YCBCR420NV12601_PL, /**< YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb,Cr rows. */ EVAS_COLORSPACE_YCBCR420TM12601_PL, /**< YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of tiled row pointer, pointing to the Y rows, then the Cb,Cr rows. */ } Evas_Colorspace; /**< Colorspaces for pixel data supported by Evas */ @@ -536,7 +537,7 @@ typedef enum _Evas_Colorspace * How to pack items into cells in a table. * @ingroup Evas_Object_Table * - * @see evas_object_table_homogeneous_set() for an explanation of the funcion of + * @see evas_object_table_homogeneous_set() for an explanation of the function of * each one. */ typedef enum _Evas_Object_Table_Homogeneous_Mode @@ -693,7 +694,7 @@ typedef enum _Evas_Load_Error EVAS_LOAD_ERROR_NONE = 0, /**< No error on load */ EVAS_LOAD_ERROR_GENERIC = 1, /**< A non-specific error occurred */ EVAS_LOAD_ERROR_DOES_NOT_EXIST = 2, /**< File (or file path) does not exist */ - EVAS_LOAD_ERROR_PERMISSION_DENIED = 3, /**< Permission deinied to an existing file (or path) */ + EVAS_LOAD_ERROR_PERMISSION_DENIED = 3, /**< Permission denied to an existing file (or path) */ EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED = 4, /**< Allocation of resources failure prevented load */ EVAS_LOAD_ERROR_CORRUPT_FILE = 5, /**< File corrupt (but was detected as a known format) */ EVAS_LOAD_ERROR_UNKNOWN_FORMAT = 6 /**< File is not a known format */ @@ -721,7 +722,7 @@ typedef enum _Evas_Pixel_Import_Pixel_Format { EVAS_PIXEL_FORMAT_NONE = 0, /**< No pixel format */ EVAS_PIXEL_FORMAT_ARGB32 = 1, /**< ARGB 32bit pixel format with A in the high byte per 32bit pixel word */ - EVAS_PIXEL_FORMAT_YUV420P_601 = 2 /**< YUV 420 Planar format with CCIR 601 color encoding wuth contiguous planes in the order Y, U and V */ + EVAS_PIXEL_FORMAT_YUV420P_601 = 2 /**< YUV 420 Planar format with CCIR 601 color encoding with contiguous planes in the order Y, U and V */ } Evas_Pixel_Import_Pixel_Format; /**< Pixel format for import call. See evas_object_image_pixels_import() */ struct _Evas_Pixel_Import_Source @@ -809,10 +810,10 @@ typedef enum _Evas_Render_Op EVAS_RENDER_BLEND_REL = 1, /**< d = d*(1 - sa) + s*da */ EVAS_RENDER_COPY = 2, /**< d = s */ EVAS_RENDER_COPY_REL = 3, /**< d = s*da */ - EVAS_RENDER_ADD = 4, /**< d = d + s */ + EVAS_RENDER_ADD = 4, /* d = d + s */ EVAS_RENDER_ADD_REL = 5, /**< d = d + s*da */ EVAS_RENDER_SUB = 6, /**< d = d - s */ - EVAS_RENDER_SUB_REL = 7, /**< d = d - s*da */ + EVAS_RENDER_SUB_REL = 7, /* d = d - s*da */ EVAS_RENDER_TINT = 8, /**< d = d*s + d*(1 - sa) + s*(1 - da) */ EVAS_RENDER_TINT_REL = 9, /**< d = d*(1 - sa + s) */ EVAS_RENDER_MASK = 10, /**< d = d*sa */ @@ -1280,7 +1281,7 @@ EAPI Eina_Bool evas_async_events_put (const void *target, Ev * directly, too, and not yet with its @b objects. They are the * functions you need to use at a minimum to get a working canvas. * - * Some of the funcions in this group are exemplified @ref + * Some of the functions in this group are exemplified @ref * Example_Evas_Events "here". */ @@ -1422,13 +1423,13 @@ EAPI void evas_damage_rectangle_add (Evas *e, int x, int y, * was just after this function took place. * * We call it "obscured region" because the most common use case for - * this rendering (partial) freeze is something else (most problaby + * this rendering (partial) freeze is something else (most probably * other canvas) being on top of the specified rectangular region, * thus shading it completely from the user's final scene in a * display. To avoid unnecessary processing, one should indicate to the * obscured canvas not to bother about the non-important area. * - * The majority of users won't have to worry about this funcion, as + * The majority of users won't have to worry about this function, as * they'll be using just one canvas in their applications, with * nothing inset or on top of it in any form. * @@ -2077,7 +2078,7 @@ EAPI void evas_pointer_canvas_xy_get (const Evas *e, Evas_Co * Returns a bitmask with the mouse buttons currently pressed, set to 1 * * @param e The pointer to the Evas Canvas - * @return A bitmask of the currently depressed buttons on the cavas + * @return A bitmask of the currently depressed buttons on the canvas * @ingroup Evas_Pointer_Group * * Calling this function will return a 32-bit integer with the @@ -2150,7 +2151,7 @@ EAPI Eina_Bool evas_pointer_inside_get (const Evas *e) EINA_WA * its internal states changing (an object got focused, the rendering * is updated, etc). * - * Some of the funcions in this group are exemplified @ref + * Some of the functions in this group are exemplified @ref * Example_Evas_Events "here". * * @ingroup Evas_Canvas @@ -2308,14 +2309,14 @@ EAPI void *evas_event_callback_del_full (Evas *e, Evas_Callb * @param data The data pointer to be passed to the callback * * Evas has a stack of callbacks that get called after all the callbacks for - * an event have triggered (all the objects it triggers on and al the callbacks + * an event have triggered (all the objects it triggers on and all the callbacks * in each object triggered). When all these have been called, the stack is * unwond from most recently to least recently pushed item and removed from the * stack calling the callback set for it. * * This is intended for doing reverse logic-like processing, example - when a * child object that happens to get the event later is meant to be able to - * "steal" functions from a parent and thus on unwind of this stack hav its + * "steal" functions from a parent and thus on unwind of this stack have its * function called first, thus being able to set flags, or return 0 from the * post-callback that stops all other post-callbacks in the current stack from * being called (thus basically allowing a child to take control, if the event @@ -2359,7 +2360,7 @@ EAPI void evas_post_event_callback_remove_full (Evas *e, Evas_Objec * an Evas canvas. * * There might be scenarios during a graphical user interface - * program's use when the developer whishes the users wouldn't be able + * program's use when the developer wishes the users wouldn't be able * to deliver input events to this application. It may, for example, * be the time for it to populate a view or to change some * layout. Assuming proper behavior with user interaction during this @@ -2367,7 +2368,14 @@ EAPI void evas_post_event_callback_remove_full (Evas *e, Evas_Objec * programmer can then tell the canvas to ignore input events, * bringing it back to normal behavior when he/she wants. * - * Some of the funcions in this group are exemplified @ref + * Most of the time use of freezing events is done like this: + * @code + * evas_event_freeze(my_evas_canvas); + * function_that_does_work_which_cant_be_interrupted_by_events(); + * evas_event_thaw(my_evas_canvas); + * @endcode + * + * Some of the functions in this group are exemplified @ref * Example_Evas_Events "here". * * @ingroup Evas_Canvas_Events @@ -2416,7 +2424,7 @@ EAPI Evas_Event_Flags evas_event_default_flags_get (const Evas *e) EINA_AR * of this kind during the freeze will get @b discarded. Every freeze * call must be matched by a thaw call in order to completely thaw out * a canvas (i.e. these calls may be nested). The most common use is - * when you don't want the user to interect with your user interface + * when you don't want the user to interact with your user interface * when you're populating a view or changing the layout. * * Example: @@ -2494,13 +2502,18 @@ EAPI void evas_event_thaw_eval (Evas *e) EINA_ARG_NONN * Functions to tell Evas that input events happened and should be * processed. * + * @warning Most of the time these functions are @b not what you're looking for. + * These functions should only be used if you're not working with ecore evas(or + * another input handling system). If you're not using ecore evas please + * consider using it, in most situation it will make life a lot easier. + * * As explained in @ref intro_not_evas, Evas does not know how to poll * for input events, so the developer should do it and then feed such * events to the canvas to be processed. This is only required if * operating Evas directly. Modules such as Ecore_Evas do that for * you. * - * Some of the funcions in this group are exemplified @ref + * Some of the functions in this group are exemplified @ref * Example_Evas_Events "here". * * @ingroup Evas_Canvas_Events @@ -2928,7 +2941,7 @@ EAPI const Eina_List *evas_font_path_list (const Evas *e) EINA_WA * - textblock and * - image. * - * These functions apply to @b any Evas object, whichever type thay + * These functions apply to @b any Evas object, whichever type that * may have. * * @note The built-in types which are most used are rectangles, text @@ -2939,14 +2952,21 @@ EAPI const Eina_List *evas_font_path_list (const Evas *e) EINA_WA /** * @defgroup Evas_Object_Group_Basic Basic Object Manipulation * - * Methods that are broadly used, like those that change the color, - * clippers and geometry of an Evas object. - * - * An example on the most used functions in this group can be seen @ref - * Example_Evas_Object_Manipulation "here". - * - * For function dealing with stacking, the examples are gathered @ref - * Example_Evas_Stacking "here". + * Almost every evas object created will have some generic function used to + * manipulate it. That's because there are a number of basic actions to be done + * to objects that are irrespective of the object's type, things like: + * @li Showing/Hiding + * @li Setting(and getting) geometry + * @li Bring up or down a layer + * @li Color management + * @li Handling focus + * @li Clipping + * @li Reference counting + * + * All of this issues are handled through the functions here grouped. Examples + * of these function can be seen in @ref Example_Evas_Object_Manipulation(which + * deals with the most common ones) and in @ref Example_Evas_Stacking(which + * deals with stacking functions). * * @ingroup Evas_Object_Group */ @@ -3444,7 +3464,7 @@ EAPI void evas_object_hide (Evas_Object *obj) EINA * @return @c EINA_TRUE if the object is visible, @c EINA_FALSE * otherwise. * - * This retrieves an object's visibily as the one enforced by + * This retrieves an object's visibility as the one enforced by * evas_object_show() and evas_object_hide(). * * @note The value returned isn't, by any means, influenced by @@ -3492,7 +3512,7 @@ EAPI void evas_object_color_set (Evas_Object *obj, int * Retrieves the “main” color's RGB component (and alpha channel) * values, which range from 0 to 255. For the alpha channel, * which defines the object's transparency level, 0 means totally - * trasparent, while 255 means opaque. These color values are + * transparent, while 255 means opaque. These color values are * premultiplied by the alpha value. * * Usually you’ll use this attribute for text and rectangle objects, @@ -4406,7 +4426,7 @@ EAPI Eina_Bool evas_object_freeze_events_get(const Evas_Object *obj) EIN * @image rtf map-uv-mapping-1.png * @image latex map-uv-mapping-1.eps * - * Images need some special handlign when mapped. Evas can easily take care + * Images need some special handling when mapped. Evas can easily take care * of objects and do almost anything with them, but it's completely oblivious * to the content of images, so each point in the map needs to be told to what * pixel in the source image it belongs. Failing to do may sometimes result @@ -4572,7 +4592,7 @@ EAPI void evas_object_map_set (Evas_Object *obj, cons * Get current object transformation map. * * This returns the current internal map set on the indicated object. It is - * intended for read-only acces and is only valid as long as the object is + * intended for read-only access and is only valid as long as the object is * not deleted or the map on the object is not changed. If you wish to modify * the map and set it back do the following: * @@ -4678,7 +4698,7 @@ EAPI void evas_map_util_points_color_set (Evas_Map * * * This rotates the indicated map's coordinates around the center coordinate * given by @p cx and @p cy as the rotation center. The points will have their - * X and Y coordinates rotated clockwise by @p degrees degress (360.0 is a + * X and Y coordinates rotated clockwise by @p degrees degrees (360.0 is a * full rotation). Negative values for degrees will rotate counter-clockwise * by that amount. All coordinates are canvas global coordinates. * @@ -4698,7 +4718,7 @@ EAPI void evas_map_util_rotate (Evas_Map * * Like evas_map_util_rotate(), this zooms the points of the map from a center * point. That center is defined by @p cx and @p cy. The @p zoomx and @p zoomy * parameters specify how much to zoom in the X and Y direction respectively. - * A value of 1.0 means "don't zoom". 2.0 means "dobule the size". 0.5 is + * A value of 1.0 means "don't zoom". 2.0 means "double the size". 0.5 is * "half the size" etc. All coordinates are canvas global coordinates. * * @param m map to change. @@ -4723,9 +4743,9 @@ EAPI void evas_map_util_zoom (Evas_Map * * evas_map_util_rotate() you provide a center point to rotate around (in 3D). * * @param m map to change. - * @param dx amount of degrees from 0.0 to 360.0 to rotate arount X axis. - * @param dy amount of degrees from 0.0 to 360.0 to rotate arount Y axis. - * @param dz amount of degrees from 0.0 to 360.0 to rotate arount Z axis. + * @param dx amount of degrees from 0.0 to 360.0 to rotate around X axis. + * @param dy amount of degrees from 0.0 to 360.0 to rotate around Y axis. + * @param dz amount of degrees from 0.0 to 360.0 to rotate around Z axis. * @param cx rotation's center horizontal position. * @param cy rotation's center vertical position. * @param cz rotation's center vertical position. @@ -4794,8 +4814,8 @@ EAPI void evas_map_util_3d_lighting (Evas_Map * * This applies a given perspective (3D) to the map coordinates. X, Y and Z * values are used. The px and py points specify the "infinite distance" point * in the 3D conversion (where all lines converge to like when artists draw - * 3D by hand). The @p z0 value specifis the z value at which there is a 1:1 - * mapping between spatial coorinates and screen coordinates. Any points + * 3D by hand). The @p z0 value specifies the z value at which there is a 1:1 + * mapping between spatial coordinates and screen coordinates. Any points * on this z value will not have their X and Y values modified in the transform. * Those further away (Z value higher) will shrink into the distance, and * those less than this value will expand and become bigger. The @p foc value @@ -4805,8 +4825,8 @@ EAPI void evas_map_util_3d_lighting (Evas_Map * * control and @p foc must be greater than 0. * * @param m map to change. - * @param px The pespective distance X coordinate - * @param py The pespective distance Y coordinate + * @param px The perspective distance X coordinate + * @param py The perspective distance Y coordinate * @param z0 The "0" z plane value * @param foc The focal distance */ @@ -4885,7 +4905,7 @@ EAPI void evas_map_alpha_set (Evas_Map *m, Eina_Bool /** * get the alpha flag for map rendering * - * This gets the alph flag for map rendering. + * This gets the alpha flag for map rendering. * * @param m map to get the alpha from. Must not be NULL. */ @@ -4926,17 +4946,17 @@ EAPI int evas_map_count_get (const Evas_Map *m) EINA * * This sets the fixed point's coordinate in the map. Note that points * describe the outline of a quadrangle and are ordered either clockwise - * or anit-clock-wise. It is suggested to keep your quadrangles concave and + * or anti-clock-wise. It is suggested to keep your quadrangles concave and * non-complex, though these polygon modes may work, they may not render * a desired set of output. The quadrangle will use points 0 and 1 , 1 and 2, - * 2 and 3, and 3 and 0 to describe the edges of the quandrangle. + * 2 and 3, and 3 and 0 to describe the edges of the quadrangle. * * The X and Y and Z coordinates are in canvas units. Z is optional and may * or may not be honored in drawing. Z is a hint and does not affect the * X and Y rendered coordinates. It may be used for calculating fills with * perspective correct rendering. * - * Remember all coordinates are canvas global ones like with move and reize + * Remember all coordinates are canvas global ones like with move and resize * in evas. * * @param m map to change point. Must not be @c NULL. @@ -5466,7 +5486,7 @@ EAPI void evas_object_size_hint_padding_set (Evas_Object *obj, Evas * * @param obj The object to attach the data pointer to * @param key The string key for the data to access it - * @param data The ponter to the data to be attached + * @param data The pointer to the data to be attached * * This attaches the pointer @p data to the object @p obj, given the * access string @p key. This pointer will stay "hooked" to the object @@ -6124,13 +6144,99 @@ EAPI void *evas_object_intercept_move_callback_del (Evas_Obje * * @brief Function to create evas rectangle objects. * - * This function may seem useless given there are no functions to manipulate - * the created rectangle, however the rectangle is actually very useful and can - * be manipulate using the generic @ref Evas_Object_Group - * "evas object functions". + * There is only one function to deal with rectangle objects, this may make this + * function seem useless given there are no functions to manipulate the created + * rectangle, however the rectangle is actually very useful and should be + * manipulated using the generic @ref Evas_Object_Group "evas object functions". + * + * The evas rectangle server a number of key functions when working on evas + * programs: + * @li Background + * @li Debugging + * @li Clipper + * + * @section Background * - * For an example of use of an evas_object_rectangle see @ref - * Example_Evas_Object_Manipulation "here". + * One extremely common requirement of evas programs is to have a solid color + * background, this can be accomplished with the following very simple code: + * @code + * Evas_Object *bg = evas_object_rectangle_add(evas_canvas); + * //Here we set the rectangles red, green, blue and opacity levels + * evas_object_color_set(bg, 255, 255, 255, 255); // opaque white background + * evas_object_resize(bg, WIDTH, HEIGHT); // covers full canvas + * evas_object_show(bg); + * @endcode + * + * This however will have issues if the @c evas_canvas is resized, however most + * windows are created using ecore evas and that has a solution to using the + * rectangle as a background: + * @code + * Evas_Object *bg = evas_object_rectangle_add(ecore_evas_get(ee)); + * //Here we set the rectangles red, green, blue and opacity levels + * evas_object_color_set(bg, 255, 255, 255, 255); // opaque white background + * evas_object_resize(bg, WIDTH, HEIGHT); // covers full canvas + * evas_object_show(bg); + * ecore_evas_object_associate(ee, bg, ECORE_EVAS_OBJECT_ASSOCIATE_BASE); + * @endcode + * So this gives us a white background to our window that will be resized + * together with it. + * + * @section Debugging + * + * Debugging is a major part of any programmers task and when debugging visual + * issues with evas programs the rectangle is an extremely useful tool. The + * rectangle's simplicity means that it's easier to pinpoint issues with it than + * with more complex objects. Therefore a common technique to use when writing + * an evas program and not getting the desired visual result is to replace the + * misbehaving object for a solid color rectangle and seeing how it interacts + * with the other elements, this often allows us to notice clipping, parenting + * or positioning issues. Once the issues have been identified and corrected the + * rectangle can be replaced for the original part and in all likelihood any + * remaining issues will be specific to that object's type. + * + * @section clipping Clipping + * + * Clipping serves two main functions: + * @li Limiting visibility(i.e. hiding portions of an object). + * @li Applying a layer of color to an object. + * + * @subsection hiding Limiting visibility + * + * It is often necessary to show only parts of an object, while it may be + * possible to create an object that corresponds only to the part that must be + * shown(and it isn't always possible) it's usually easier to use a a clipper. A + * clipper is a rectangle that defines what's visible and what is not. The way + * to do this is to create a solid white rectangle(which is the default, no need + * to call evas_object_color_set()) and give it a position and size of what + * should be visible. The following code exemplifies showing the center half of + * @c my_evas_object: + * @code + * Evas_Object *clipper = evas_object_rectangle_add(evas_canvas); + * evas_object_move(clipper, my_evas_object_x / 4, my_evas_object_y / 4); + * evas_object_resize(clipper, my_evas_object_width / 2, my_evas_object_height / 2); + * evas_object_clip_set(my_evas_object, clipper); + * evas_object_show(clipper); + * @endcode + * + * @subsection color Layer of color + * + * In the @ref clipping section we used a solid white clipper, which produced no + * change in the color of the clipped object, it just hid what was outside the + * clippers area. It is however sometimes desirable to change the of color an + * object, this can be accomplished using a clipper that has a non-white color. + * Clippers with color work by multiplying the colors of clipped object. The + * following code will show how to remove all the red from an object: + * @code + * Evas_Object *clipper = evas_object_rectangle_add(evas); + * evas_object_move(clipper, my_evas_object_x, my_evas_object_y); + * evas_object_resize(clipper, my_evas_object_width, my_evas_object_height); + * evas_object_color_set(clipper, 0, 255, 255, 255); + * evas_object_clip_set(obj, clipper); + * evas_object_show(clipper); + * @endcode + * + * For an example that more fully exercise the use of an evas object rectangle + * see @ref Example_Evas_Object_Manipulation. * * @ingroup Evas_Object_Specific */ @@ -6172,7 +6278,7 @@ EAPI Evas_Object *evas_object_rectangle_add (Evas *e) EINA_WARN_UNU * object's area with that given pixel data. One could use just a * sub-region of the original image or even have it tiled repeatedly * on the image object. For the common case of having the whole source - * image to be displayed on the image object, streched to the + * image to be displayed on the image object, stretched to the * destination's size, there's also a function helper, to be used * instead of evas_object_image_fill_set(): * @code @@ -6208,7 +6314,7 @@ EAPI Evas_Object *evas_object_rectangle_add (Evas *e) EINA_WARN_UNU * at a given image, at full size, and will desire that the navigation * to the adjacent images on his/her album be fluid and fast. Thus, * while displaying a given image, the program can be on the - * background loading the next and previous imagens already, so that + * background loading the next and previous images already, so that * displaying them on the sequence is just a matter of repainting the * screen (and not decoding image data). * @@ -6247,7 +6353,7 @@ EAPI Evas_Object *evas_object_rectangle_add (Evas *e) EINA_WARN_UNU * are also some tips on how to boost the performance of your * application. If the animation involves resizing of an image (thus, * re-scaling), you'd better turn off smooth scaling on it @b during - * the animation, turning it back on afterwrads, for less + * the animation, turning it back on afterwards, for less * computations. Also, in this case you'd better flag the image object * in question not to cache scaled versions of it: * @code @@ -6290,7 +6396,7 @@ EAPI Evas_Object *evas_object_rectangle_add (Evas *e) EINA_WARN_UNU * your own data as an image's pixel data, fetch an image's pixel data * for saving/altering, convert images between different color spaces * and even advanced operations like setting a native surface as image - * objecs' data. + * objects' data. * * @section Evas_Object_Image_Color_Spaces Color spaces * @@ -6679,7 +6785,7 @@ EAPI double evas_object_image_border_scale_get (const Ev * * See the following image to better understand the effects of this * call. On this diagram, both image object and original image source - * have @c a x @c a dimentions and the image itself is a circle, with + * have @c a x @c a dimensions and the image itself is a circle, with * empty space around it: * * @image html image-fill.png @@ -6689,7 +6795,7 @@ EAPI double evas_object_image_border_scale_get (const Ev * @warning The default values for the fill parameters are @p x = 0, * @p y = 0, @p w = 0 and @p h = 0. Thus, if you're not using the * evas_object_image_filled_add() helper and want your image - * displayed, you'll have to set valid values with this fuction on + * displayed, you'll have to set valid values with this function on * your object. * * @note evas_object_image_filled_set() is a helper function which @@ -6823,7 +6929,7 @@ EAPI void evas_object_image_data_set (Evas_Obj * This is best suited for when you want to modify an existing image, * without changing its dimensions. * - * @note The contents' formart returned by it depend on the color + * @note The contents' format returned by it depend on the color * space of the given image object. * * @note You may want to use evas_object_image_data_update_add() to @@ -7022,7 +7128,7 @@ EAPI Eina_Bool evas_object_image_save (const Ev EAPI Eina_Bool evas_object_image_pixels_import (Evas_Object *obj, Evas_Pixel_Import_Source *pixels) EINA_ARG_NONNULL(1, 2); /** - * Set the callback function to get pixels from a canva's image. + * Set the callback function to get pixels from a canvas' image. * * @param obj The given canvas pointer. * @param func The callback function. @@ -7403,7 +7509,7 @@ EAPI Eina_Bool evas_object_image_extension_can_load_get(const char *file); * Check if a file extension may be supported by @ref Evas_Object_Image. * * @param file The file to check, it should be an Eina_Stringshare. - * @return EINA_TRUE if we may be able to opeen it, EINA_FALSE if it's unlikely. + * @return EINA_TRUE if we may be able to open it, EINA_FALSE if it's unlikely. * @since 1.1.0 * * This functions is threadsafe. @@ -7607,7 +7713,7 @@ EAPI void evas_object_image_animated_frame_set(Evas_Object *obj, int frame_num); /** * Text style type creation macro. This one will impose shadow * directions on the style type variable -- use the @c - * EVAS_TEXT_STYLE_SHADOW_DIRECTION_* values on 's', incremmentally. + * EVAS_TEXT_STYLE_SHADOW_DIRECTION_* values on 's', incrementally. */ #define EVAS_TEXT_STYLE_SHADOW_DIRECTION_SET(x, s) \ do { x = ((x) & ~EVAS_TEXT_STYLE_MASK_SHADOW_DIRECTION) | (s); } while (0) @@ -7686,7 +7792,7 @@ EAPI const char *evas_object_text_font_source_get (const Evas_Object *obj * * This function allows the font name and size of a text object to be * set. The @p font string has to follow fontconfig's convention on - * naming fonts, as it's the underlying lybrary used to query system + * naming fonts, as it's the underlying library used to query system * fonts by Evas (see the @c fc-list command's output, on your system, * to get an idea). * @@ -8286,6 +8392,40 @@ EAPI void evas_object_textblock_style_set(Evas_Object *o EAPI const Evas_Textblock_Style *evas_object_textblock_style_get(const Evas_Object *obj) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1); /** + * Push ts to the top of the user style stack. + * + * FIXME: API is solid but currently only supports 1 style in the stack. + * + * The user style overrides the corresponding elements of the regular style. + * This is the proper way to do theme overrides in code. + * @param obj the Evas object to set the style to. + * @param ts the style to set. + * @return Returns no value. + * @see evas_object_textblock_style_set + * @since 1.2.0 + */ +EAPI void evas_object_textblock_style_user_push(Evas_Object *obj, Evas_Textblock_Style *ts) EINA_ARG_NONNULL(1); + +/** + * Del the from the top of the user style stack. + * + * @param obj the object to get the style from. + * @see evas_object_textblock_style_get + * @since 1.2.0 + */ +EAPI void evas_object_textblock_style_user_pop(Evas_Object *obj) EINA_ARG_NONNULL(1); + +/** + * Get (don't remove) the style at the top of the user style stack. + * + * @param obj the object to get the style from. + * @return the style of the object. + * @see evas_object_textblock_style_get + * @since 1.2.0 + */ +EAPI const Evas_Textblock_Style *evas_object_textblock_style_user_peek(const Evas_Object *obj) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1); + +/** * @brief Set the "replacement character" to use for the given textblock object. * * @param obj The given textblock object. @@ -8320,7 +8460,7 @@ EAPI void evas_object_textblock_valign_set(Evas_Object * * @brief Gets the vertical alignment of a textblock * * @param obj The given textblock object. - * @return The elignment set for the object + * @return The alignment set for the object * @since 1.1.0 */ EAPI double evas_object_textblock_valign_get(const Evas_Object *obj); @@ -8524,7 +8664,7 @@ EAPI void evas_textblock_node_format_remove_pair(Evas_Ob * @param n the format node to update according. * @deprecated duplicate of evas_textblock_cursor_at_format_set */ -EINA_DEPRECATED EAPI void evas_textblock_cursor_set_at_format(Evas_Textblock_Cursor *cur, const Evas_Object_Textblock_Node_Format *n) EINA_ARG_NONNULL(1, 2); +EAPI void evas_textblock_cursor_set_at_format(Evas_Textblock_Cursor *cur, const Evas_Object_Textblock_Node_Format *n) EINA_ARG_NONNULL(1, 2); /** * Return the format node at the position pointed by cur. @@ -8847,7 +8987,7 @@ EAPI char *evas_textblock_cursor_content_get(const Evas_T * get, except for the case of the last char of a line which depends on the * paragraph direction. * - * in '|' cursor mode (i.e a line between two chars) it is very varyable. + * in '|' cursor mode (i.e a line between two chars) it is very variable. * For example consider the following visual string: * "abcCBA" (ABC are rtl chars), a cursor pointing on A should actually draw * a '|' between the c and the C. @@ -9348,7 +9488,7 @@ struct _Evas_Smart_Cb_Description return; \ if (!prefix##_parent_sc) \ prefix##_parent_sc = parent_func(); \ - evas_smart_class_inherit(sc, (const Evas_Smart_Class *)prefix##_parent_sc); \ + evas_smart_class_inherit(sc, prefix##_parent_sc); \ prefix##_smart_set_user(api); \ } \ static Evas_Smart * prefix##_smart_class_new(void) \ @@ -9557,7 +9697,7 @@ EAPI int evas_smart_usage_get(const Evas_Smart *s); * @return 1 on success, 0 on failure. * @ingroup Evas_Smart_Group */ -#define evas_smart_class_inherit(sc, parent_sc) evas_smart_class_inherit_full(sc, parent_sc, sizeof(*parent_sc)) +#define evas_smart_class_inherit(sc, parent_sc) evas_smart_class_inherit_full(sc, (Evas_Smart_Class *)parent_sc, sizeof(*parent_sc)) /** * @} @@ -9576,13 +9716,13 @@ EAPI int evas_smart_usage_get(const Evas_Smart *s); * used on the icon object. * * Besides that, generally smart objects implement a specific - * API, so that users interect with its own custom features. The + * API, so that users interact with its own custom features. The * API takes form of explicit exported functions one may call and * smart callbacks. * * @section Evas_Smart_Object_Group_Callbacks Smart events and callbacks * - * Smart objects can elect events (smart events, from now on) ocurring + * Smart objects can elect events (smart events, from now on) occurring * inside of them to be reported back to their users via callback * functions (smart callbacks). This way, you can extend Evas' own * object events. They are defined by an event string, which @@ -9590,7 +9730,7 @@ EAPI int evas_smart_usage_get(const Evas_Smart *s); * definition for the callback functions: #Evas_Smart_Cb. * * When defining an #Evas_Smart_Class, smart object implementors are - * strongly encorauged to properly set the Evas_Smart_Class::callbacks + * strongly encouraged to properly set the Evas_Smart_Class::callbacks * callbacks description array, so that the users of the smart object * can have introspection on its events API at run time. * @@ -9890,7 +10030,7 @@ EAPI void *evas_object_smart_callback_del_full(Evas_Object *obj, con * object should include a list of possible events and what type of @p * event_info to expect for each of them. Also, when defining an * #Evas_Smart_Class, smart object implementors are strongly - * encorauged to properly set the Evas_Smart_Class::callbacks + * encouraged to properly set the Evas_Smart_Class::callbacks * callbacks description array, so that the users of the smart object * can have introspection on its events API at run time. * @@ -9949,7 +10089,7 @@ EAPI Eina_Bool evas_object_smart_callbacks_descriptions_set(Evas_Object * @param instance_count Returns how many instance callbacks * descriptions are known. * - * This call searchs for registered callback descriptions for both + * This call searches for registered callback descriptions for both * instance and class of the given smart object. These arrays will be * sorted by Evas_Smart_Cb_Description::name and also @c NULL * terminated, so both @a class_count and @a instance_count can be @@ -10052,7 +10192,7 @@ EAPI void evas_object_smart_need_recalculate_set(Evas_Object *obj, EAPI Eina_Bool evas_object_smart_need_recalculate_get(const Evas_Object *obj) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1); /** - * Call the @b calculate() smart function immediataly on a given smart + * Call the @b calculate() smart function immediately on a given smart * object. * * @param obj the smart object's handle @@ -10091,7 +10231,7 @@ EAPI void evas_smart_objects_calculate (Evas *e); * that this function returns the value of. It starts at the value of 0 and * will increase (and eventually wrap around to negative values and so on) by * 1 every time objects are calculated. You can use this counter to ensure - * you dont re-do calculations withint the same calculation generation/run + * you don't re-do calculations withint the same calculation generation/run * if the calculations maybe cause self-feeding effects. * * @ingroup Evas_Smart_Object_Group @@ -10348,7 +10488,7 @@ EAPI const Evas_Smart_Class *evas_object_smart_clipped_class_get (void) EINA Evas_Object_Box_Option *(*prepend) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child); /**< Smart function to prepend child elements in boxes */ Evas_Object_Box_Option *(*insert_before) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child, const Evas_Object *reference); /**< Smart function to insert a child element before another in boxes */ Evas_Object_Box_Option *(*insert_after) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child, const Evas_Object *reference); /**< Smart function to insert a child element after another in boxes */ - Evas_Object_Box_Option *(*insert_at) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child, unsigned int pos); /**< Smart function to insert a child element at a given positon on boxes */ + Evas_Object_Box_Option *(*insert_at) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child, unsigned int pos); /**< Smart function to insert a child element at a given position on boxes */ Evas_Object *(*remove) (Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child); /**< Smart function to remove a child element from boxes */ Evas_Object *(*remove_at) (Evas_Object *o, Evas_Object_Box_Data *priv, unsigned int pos); /**< Smart function to remove a child element from boxes, by its position */ Eina_Bool (*property_set) (Evas_Object *o, Evas_Object_Box_Option *opt, int property, va_list args); /**< Smart function to set a custom property on a box child */ @@ -10472,7 +10612,7 @@ EAPI const Evas_Smart_Class *evas_object_smart_clipped_class_get (void) EINA * with the default values. May be used to extend that API. * * @param api The box API struct to set back, most probably with - * overriden fields (on class extensions scenarios) + * overridden fields (on class extensions scenarios) */ EAPI void evas_object_box_smart_set (Evas_Object_Box_Api *api) EINA_ARG_NONNULL(1); @@ -10697,7 +10837,7 @@ EAPI void evas_object_box_layout_homogeneous_horizontal * of this overall child width in its allocated cell (@c 0.0 to * extreme left, @c 1.0 to extreme right). A value of @c -1.0 to * @c align_x makes the box try to resize this child element to the exact - * width of its cell (respecting the minimun and maximum size hints on + * width of its cell (respecting the minimum and maximum size hints on * the child's width and accounting for its horizontal padding * hints). The child's @c padding_t, @c padding_b and @c align_y * properties apply for padding/alignment relative to the overall @@ -10978,7 +11118,7 @@ EAPI Evas_Object_Box_Option *evas_object_box_insert_at * On removal, you'll get an unparented object again, just as it was * before you inserted it in the box. The * _Evas_Object_Box_Api::option_free box smart callback will be called - * automatilly for you and, also, the @c "child,removed" smart event + * automatically for you and, also, the @c "child,removed" smart event * will take place. * * @note This call will trigger the box's _Evas_Object_Box_Api::remove @@ -10997,7 +11137,7 @@ EAPI Eina_Bool evas_object_box_remove * * On removal, you'll get an unparented object again, just as it was * before you inserted it in the box. The @c option_free() box smart - * callback will be called automatilly for you and, also, the + * callback will be called automatically for you and, also, the * @c "child,removed" smart event will take place. * * @note This function will fail if the given position is invalid, @@ -11589,8 +11729,8 @@ EAPI Eina_List *evas_object_grid_children_get (const { int saved_memory; /**< current amount of saved memory, in bytes */ int wasted_memory; /**< current amount of wasted memory, in bytes */ - int saved_memory_peak; /**< peak ammount of saved memory, in bytes */ - int wasted_memory_peak; /**< peak ammount of wasted memory, in bytes */ + int saved_memory_peak; /**< peak amount of saved memory, in bytes */ + int wasted_memory_peak; /**< peak amount of wasted memory, in bytes */ double saved_time_image_header_load; /**< time, in seconds, saved in header loads by sharing cached loads instead */ double saved_time_image_data_load; /**< time, in seconds, saved in data loads by sharing cached loads instead */ }; @@ -11803,7 +11943,7 @@ EAPI void evas_color_rgb_to_hsv (int r, int g, int b, f * @param g The Green component of the color. * @param b The Blue component of the color. * - * This function pre-multiplies a given rbg triplet by an alpha + * This function pre-multiplies a given rgb triplet by an alpha * factor. Alpha factor is used to define transparency. * * @ingroup Evas_Utils @@ -12233,7 +12373,7 @@ EAPI Evas_Modifier_Mask evas_key_modifier_mask_get (const Evas *e, const c * modifiers that must and mustn't, respectively, be pressed along * with @p keyname key in order to trigger this new key * grab. Modifiers can be things such as Shift and Ctrl as well as - * user defigned types via evas_key_modifier_add(). Retrieve them with + * user defined types via evas_key_modifier_add(). Retrieve them with * evas_key_modifier_mask_get() or use @c 0 for empty masks. * * @p exclusive will make the given object the only one permitted to diff --git a/libraries/evas/src/lib/Evas_GL.h b/libraries/evas/src/lib/Evas_GL.h index fdfbaad..76937eb 100644 --- a/libraries/evas/src/lib/Evas_GL.h +++ b/libraries/evas/src/lib/Evas_GL.h @@ -404,7 +404,7 @@ EAPI void evas_gl_free (Evas_GL *evas_gl) EINA * As long as the Evas creates a config object for the user, it takes care * of the backward compatibility issue. */ -EAPI Evas_GL_Config *evas_gl_config_new (); +EAPI Evas_GL_Config *evas_gl_config_new (void); /** * Frees a config object created from evas_gl_config_new. diff --git a/libraries/evas/src/lib/Makefile.am b/libraries/evas/src/lib/Makefile.am index 2a1a92d..1240b2b 100644 --- a/libraries/evas/src/lib/Makefile.am +++ b/libraries/evas/src/lib/Makefile.am @@ -76,13 +76,11 @@ SUBDIRS += ../modules/engines/software_8_x11/ EVAS_STATIC_MODULE += ../modules/engines/software_8_x11/libevas_engine_software_8_x11.la EVAS_STATIC_LIBADD += @evas_engine_software_8_x11_libs@ endif -if EVAS_STATIC_BUILD_SOFTWARE_SDL +if EVAS_STATIC_BUILD_SOFTWARE_16_SDL SUBDIRS += \ - ../modules/engines/software_16_sdl/ \ - ../modules/engines/software_sdl/ + ../modules/engines/software_16_sdl/ EVAS_STATIC_MODULE += \ - ../modules/engines/software_16_sdl/libevas_engine_software_16_sdl.la \ - ../modules/engines/software_sdl/libevas_engine_software_sdl.la + ../modules/engines/software_16_sdl/libevas_engine_software_16_sdl.la EVAS_STATIC_LIBADD += @SDL_LIBS@ endif if EVAS_STATIC_BUILD_SOFTWARE_DDRAW @@ -201,8 +199,6 @@ AM_CPPFLAGS = \ @pthread_cflags@ \ @PIXMAN_CFLAGS@ -AM_CFLAGS = @WIN32_CFLAGS@ - lib_LTLIBRARIES = libevas.la includes_HEADERS = Evas.h Evas_GL.h diff --git a/libraries/evas/src/lib/Makefile.in b/libraries/evas/src/lib/Makefile.in index ffe71d1..cb04330 100644 --- a/libraries/evas/src/lib/Makefile.in +++ b/libraries/evas/src/lib/Makefile.in @@ -83,15 +83,13 @@ host_triplet = @host@ @EVAS_STATIC_BUILD_SOFTWARE_8_X11_TRUE@am__append_36 = ../modules/engines/software_8_x11/ @EVAS_STATIC_BUILD_SOFTWARE_8_X11_TRUE@am__append_37 = ../modules/engines/software_8_x11/libevas_engine_software_8_x11.la @EVAS_STATIC_BUILD_SOFTWARE_8_X11_TRUE@am__append_38 = @evas_engine_software_8_x11_libs@ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@am__append_39 = \ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@ ../modules/engines/software_16_sdl/ \ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@ ../modules/engines/software_sdl/ +@EVAS_STATIC_BUILD_SOFTWARE_16_SDL_TRUE@am__append_39 = \ +@EVAS_STATIC_BUILD_SOFTWARE_16_SDL_TRUE@ ../modules/engines/software_16_sdl/ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@am__append_40 = \ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@ ../modules/engines/software_16_sdl/libevas_engine_software_16_sdl.la \ -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@ ../modules/engines/software_sdl/libevas_engine_software_sdl.la +@EVAS_STATIC_BUILD_SOFTWARE_16_SDL_TRUE@am__append_40 = \ +@EVAS_STATIC_BUILD_SOFTWARE_16_SDL_TRUE@ ../modules/engines/software_16_sdl/libevas_engine_software_16_sdl.la -@EVAS_STATIC_BUILD_SOFTWARE_SDL_TRUE@am__append_41 = @SDL_LIBS@ +@EVAS_STATIC_BUILD_SOFTWARE_16_SDL_TRUE@am__append_41 = @SDL_LIBS@ @EVAS_STATIC_BUILD_SOFTWARE_DDRAW_TRUE@am__append_42 = ../modules/engines/software_ddraw/ @EVAS_STATIC_BUILD_SOFTWARE_DDRAW_TRUE@am__append_43 = ../modules/engines/software_ddraw/libevas_engine_software_ddraw.la @EVAS_STATIC_BUILD_SOFTWARE_DDRAW_TRUE@am__append_44 = @evas_engine_software_ddraw_libs@ @@ -346,6 +344,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -396,6 +396,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -414,8 +416,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -489,8 +489,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -625,7 +623,6 @@ AM_CPPFLAGS = \ @pthread_cflags@ \ @PIXMAN_CFLAGS@ -AM_CFLAGS = @WIN32_CFLAGS@ lib_LTLIBRARIES = libevas.la includes_HEADERS = Evas.h Evas_GL.h includesdir = $(includedir)/evas-@VMAJ@ diff --git a/libraries/evas/src/lib/cache/Makefile.am b/libraries/evas/src/lib/cache/Makefile.am index d417262..78d58d2 100644 --- a/libraries/evas/src/lib/cache/Makefile.am +++ b/libraries/evas/src/lib/cache/Makefile.am @@ -7,7 +7,6 @@ AM_CPPFLAGS = -I. \ -DPACKAGE_BIN_DIR=\"$(bindir)\" \ -DPACKAGE_LIB_DIR=\"$(libdir)\" \ -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \ - @WIN32_CPPFLAGS@ \ @EVIL_CFLAGS@ \ @FREETYPE_CFLAGS@ \ @PIXMAN_CFLAGS@ \ diff --git a/libraries/evas/src/lib/cache/Makefile.in b/libraries/evas/src/lib/cache/Makefile.in index 2b50c81..fce77cc 100644 --- a/libraries/evas/src/lib/cache/Makefile.in +++ b/libraries/evas/src/lib/cache/Makefile.in @@ -147,6 +147,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -197,6 +199,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -215,8 +219,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -290,8 +292,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -381,7 +381,6 @@ AM_CPPFLAGS = -I. \ -DPACKAGE_BIN_DIR=\"$(bindir)\" \ -DPACKAGE_LIB_DIR=\"$(libdir)\" \ -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \ - @WIN32_CPPFLAGS@ \ @EVIL_CFLAGS@ \ @FREETYPE_CFLAGS@ \ @PIXMAN_CFLAGS@ \ diff --git a/libraries/evas/src/lib/cache/evas_cache_image.c b/libraries/evas/src/lib/cache/evas_cache_image.c index 73e4f8a..d5b72c5 100644 --- a/libraries/evas/src/lib/cache/evas_cache_image.c +++ b/libraries/evas/src/lib/cache/evas_cache_image.c @@ -42,10 +42,10 @@ static void _evas_cache_image_entry_preload_remove(Image_Entry *ie, const void * #define FREESTRC(Var) \ if (Var) \ - { \ - eina_stringshare_del(Var); \ - Var = NULL; \ - } +{ \ + eina_stringshare_del(Var); \ + Var = NULL; \ +} static void _evas_cache_image_dirty_add(Image_Entry *im); static void _evas_cache_image_dirty_del(Image_Entry *im); @@ -210,9 +210,9 @@ _evas_cache_image_entry_delete(Evas_Cache_Image *cache, Image_Entry *ie) if (ie->flags.delete_me == 1) return; if (ie->preload) { - ie->flags.delete_me = 1; - _evas_cache_image_entry_preload_remove(ie, NULL); - return; + ie->flags.delete_me = 1; + _evas_cache_image_entry_preload_remove(ie, NULL); + return; } #endif @@ -247,10 +247,10 @@ _timestamp_compare(Image_Timestamp *tstamp, struct stat *st) #ifdef _STAT_VER_LINUX #if (defined __USE_MISC && defined st_mtime) if (tstamp->mtime_nsec != (unsigned long int)st->st_mtim.tv_nsec) - return EINA_FALSE; + return EINA_FALSE; #else if (tstamp->mtime_nsec != (unsigned long int)st->st_mtimensec) - return EINA_FALSE; + return EINA_FALSE; #endif #endif return EINA_TRUE; @@ -285,8 +285,8 @@ _evas_cache_image_entry_new(Evas_Cache_Image *cache, ie = cache->func.alloc(); if (!ie) { - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - return NULL; + *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; + return NULL; } ie->cache = cache; if (hkey) ie->cache_key = eina_stringshare_add(hkey); @@ -307,7 +307,7 @@ _evas_cache_image_entry_new(Evas_Cache_Image *cache, LKI(ie->lock); LKI(ie->lock_cancel); #endif - + if (lo) ie->load_opts = *lo; if (ie->file) { @@ -326,8 +326,8 @@ _evas_cache_image_entry_new(Evas_Cache_Image *cache, static void _evas_cache_image_entry_surface_alloc__locked(Evas_Cache_Image *cache, - Image_Entry *ie, - unsigned int wmin, + Image_Entry *ie, + unsigned int wmin, unsigned int hmin) { if ((ie->allocated.w == wmin) && (ie->allocated.h == hmin)) return; @@ -376,16 +376,16 @@ _evas_cache_image_async_heavy(void *data) if ((!current->flags.loaded) && ((Evas_Image_Load_Func*) current->info.module)->threadable) { - error = cache->func.load(current); - if (cache->func.debug) cache->func.debug("load", current); + error = cache->func.load(current); + if (cache->func.debug) cache->func.debug("load", current); current->load_error = error; - if (error != EVAS_LOAD_ERROR_NONE) - { - current->flags.loaded = 0; - _evas_cache_image_entry_surface_alloc(cache, current, - current->w, current->h); - } - else + if (error != EVAS_LOAD_ERROR_NONE) + { + current->flags.loaded = 0; + _evas_cache_image_entry_surface_alloc(cache, current, + current->w, current->h); + } + else { current->flags.loaded = 1; } @@ -416,11 +416,11 @@ _evas_cache_image_async_end(void *data) ie->flags.preload_done = ie->flags.loaded; while ((tmp = ie->targets)) { - evas_object_inform_call_image_preloaded((Evas_Object*) tmp->target); - ie->targets = (Evas_Cache_Target *) + evas_object_inform_call_image_preloaded((Evas_Object*) tmp->target); + ie->targets = (Evas_Cache_Target *) eina_inlist_remove(EINA_INLIST_GET(ie->targets), EINA_INLIST_GET(ie->targets)); - free(tmp); + free(tmp); } } @@ -429,14 +429,14 @@ _evas_cache_image_async_cancel(void *data) { Evas_Cache_Image *cache = NULL; Image_Entry *ie = (Image_Entry *)data; - + ie->preload = NULL; ie->cache->pending = eina_list_remove(ie->cache->pending, ie); if ((ie->flags.delete_me) || (ie->flags.dirty)) { - ie->flags.delete_me = 0; - _evas_cache_image_entry_delete(ie->cache, ie); - return; + ie->flags.delete_me = 0; + _evas_cache_image_entry_delete(ie->cache, ie); + return; } if (ie->flags.loaded) _evas_cache_image_async_end(ie); #ifdef EVAS_FRAME_QUEUING @@ -485,41 +485,41 @@ _evas_cache_image_entry_preload_remove(Image_Entry *ie, const void *target) { if (target) { - Evas_Cache_Target *tg; - - EINA_INLIST_FOREACH(ie->targets, tg) - { - if (tg->target == target) - { - // FIXME: No callback when we cancel only for one target ? - ie->targets = (Evas_Cache_Target *) + Evas_Cache_Target *tg; + + EINA_INLIST_FOREACH(ie->targets, tg) + { + if (tg->target == target) + { + // FIXME: No callback when we cancel only for one target ? + ie->targets = (Evas_Cache_Target *) eina_inlist_remove(EINA_INLIST_GET(ie->targets), EINA_INLIST_GET(tg)); - free(tg); - break; - } - } + free(tg); + break; + } + } } else { - Evas_Cache_Target *tg; + Evas_Cache_Target *tg; - while (ie->targets) - { - tg = ie->targets; - ie->targets = (Evas_Cache_Target *) + while (ie->targets) + { + tg = ie->targets; + ie->targets = (Evas_Cache_Target *) eina_inlist_remove(EINA_INLIST_GET(ie->targets), EINA_INLIST_GET(tg)); - free(tg); - } + free(tg); + } } if ((!ie->targets) && (ie->preload) && (!ie->flags.pending)) { - ie->cache->preload = eina_list_remove(ie->cache->preload, ie); - ie->cache->pending = eina_list_append(ie->cache->pending, ie); - ie->flags.pending = 1; - evas_preload_thread_cancel(ie->preload); + ie->cache->preload = eina_list_remove(ie->cache->preload, ie); + ie->cache->pending = eina_list_append(ie->cache->pending, ie); + ie->flags.pending = 1; + evas_preload_thread_cancel(ie->preload); } } #endif @@ -566,7 +566,7 @@ evas_cache_image_init(const Evas_Cache_Image_Func *cb) { LKI(engine_lock); LKI(wakeup); - eina_condition_new(&cond_wakeup, &wakeup); + eina_condition_new(&cond_wakeup, &wakeup); } #endif @@ -616,9 +616,9 @@ evas_cache_image_shutdown(Evas_Cache_Image *cache) #ifdef BUILD_ASYNC_PRELOAD EINA_LIST_FREE(cache->preload, im) { - /* By doing that we are protecting us from destroying image when the cache is no longer available. */ - im->flags.delete_me = 1; - _evas_cache_image_entry_preload_remove(im, NULL); + /* By doing that we are protecting us from destroying image when the cache is no longer available. */ + im->flags.delete_me = 1; + _evas_cache_image_entry_preload_remove(im, NULL); } evas_async_events_process(); #endif @@ -642,21 +642,21 @@ evas_cache_image_shutdown(Evas_Cache_Image *cache) eina_hash_foreach(cache->activ, _evas_cache_image_free_cb, &delete_list); while (delete_list) { - _evas_cache_image_entry_delete(cache, eina_list_data_get(delete_list)); - delete_list = eina_list_remove_list(delete_list, delete_list); + _evas_cache_image_entry_delete(cache, eina_list_data_get(delete_list)); + delete_list = eina_list_remove_list(delete_list, delete_list); } #ifdef BUILD_ASYNC_PRELOAD /* Now wait for all pending image to die */ while (cache->pending) { - evas_async_events_process(); - LKL(wakeup); + evas_async_events_process(); + LKL(wakeup); // the lazy bum who did eain threads and converted this code // didn't bother to worry about Eina_Lock being a different type // to a pthread mutex. - if (cache->pending) eina_condition_wait(&cond_wakeup); - LKU(wakeup); + if (cache->pending) eina_condition_wait(&cond_wakeup); + LKU(wakeup); } #endif eina_hash_free(cache->activ); @@ -666,7 +666,7 @@ evas_cache_image_shutdown(Evas_Cache_Image *cache) #ifdef BUILD_ASYNC_PRELOAD if (--_evas_cache_mutex_init == 0) { - eina_condition_free(&cond_wakeup); + eina_condition_free(&cond_wakeup); LKD(engine_lock); LKD(wakeup); } @@ -690,8 +690,8 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, if ((!file) || ((!file) && (!key))) { - *error = EVAS_LOAD_ERROR_GENERIC; - return NULL; + *error = EVAS_LOAD_ERROR_GENERIC; + return NULL; } /* generate hkey from file+key+load opts */ @@ -712,45 +712,45 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, (lo->dpi == 0.0) && ((lo->w == 0) || (lo->h == 0)) && ((lo->region.w == 0) || (lo->region.h == 0)) && - (lo->orientation == 0) - )) + (lo->orientation == 0) + )) { lo = &prevent; } else { - memcpy(hkey + size, "//@/", 4); - size += 4; - size += eina_convert_xtoa(lo->scale_down_by, hkey + size); - hkey[size] = '/'; - size += 1; - size += eina_convert_dtoa(lo->dpi, hkey + size); - hkey[size] = '/'; - size += 1; - size += eina_convert_xtoa(lo->w, hkey + size); - hkey[size] = 'x'; - size += 1; - size += eina_convert_xtoa(lo->h, hkey + size); - hkey[size] = '/'; - size += 1; - size += eina_convert_xtoa(lo->region.x, hkey + size); - hkey[size] = '+'; - size += 1; - size += eina_convert_xtoa(lo->region.y, hkey + size); - hkey[size] = '.'; - size += 1; - size += eina_convert_xtoa(lo->region.w, hkey + size); - hkey[size] = 'x'; - size += 1; - size += eina_convert_xtoa(lo->region.h, hkey + size); - - if (lo->orientation) - { + memcpy(hkey + size, "//@/", 4); + size += 4; + size += eina_convert_xtoa(lo->scale_down_by, hkey + size); + hkey[size] = '/'; + size += 1; + size += eina_convert_dtoa(lo->dpi, hkey + size); + hkey[size] = '/'; + size += 1; + size += eina_convert_xtoa(lo->w, hkey + size); + hkey[size] = 'x'; + size += 1; + size += eina_convert_xtoa(lo->h, hkey + size); + hkey[size] = '/'; + size += 1; + size += eina_convert_xtoa(lo->region.x, hkey + size); + hkey[size] = '+'; + size += 1; + size += eina_convert_xtoa(lo->region.y, hkey + size); + hkey[size] = '.'; + size += 1; + size += eina_convert_xtoa(lo->region.w, hkey + size); + hkey[size] = 'x'; + size += 1; + size += eina_convert_xtoa(lo->region.h, hkey + size); + + if (lo->orientation) + { hkey[size] = '/'; size += 1; hkey[size] = 'o'; size += 1; - } + } } hkey[size] = '\0'; @@ -768,10 +768,10 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, stat_done = 1; if (stat(file, &st) < 0) - { - stat_failed = 1; - ok = 0; - } + { + stat_failed = 1; + ok = 0; + } else if (!_timestamp_compare(&(im->tstamp), &st)) ok = 0; if (ok) goto on_ok; /* image we found doesn't match what's on disk (stat info wise) @@ -816,10 +816,12 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, } /* as avtive cache find - if we match in lru and its invalid, dirty */ _evas_cache_image_dirty_add(im); + /* this image never used, so it have to be deleted */ + _evas_cache_image_entry_delete(cache, im); im = NULL; } if (stat_failed) goto on_stat_error; - + if (!stat_done) { if (stat(file, &st) < 0) goto on_stat_error; @@ -830,7 +832,7 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, if (!im) goto on_stat_error; if (cache->func.debug) cache->func.debug("request", im); - on_ok: +on_ok: *error = EVAS_LOAD_ERROR_NONE; #ifdef EVAS_FRAME_QUEUING LKL(im->lock_references); @@ -841,24 +843,24 @@ evas_cache_image_request(Evas_Cache_Image *cache, const char *file, #endif return im; - on_stat_error: +on_stat_error: #ifndef _WIN32 if ((errno == ENOENT) || (errno == ENOTDIR) || (errno == ENAMETOOLONG) || (errno == ELOOP)) #else - if (errno == ENOENT) + if (errno == ENOENT) #endif - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; + *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; #ifndef _WIN32 - else if ((errno == ENOMEM) || (errno == EOVERFLOW)) + else if ((errno == ENOMEM) || (errno == EOVERFLOW)) #else - else if (errno == ENOMEM) + else if (errno == ENOMEM) #endif - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - else if (errno == EACCES) - *error = EVAS_LOAD_ERROR_PERMISSION_DENIED; - else - *error = EVAS_LOAD_ERROR_GENERIC; + *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; + else if (errno == EACCES) + *error = EVAS_LOAD_ERROR_PERMISSION_DENIED; + else + *error = EVAS_LOAD_ERROR_GENERIC; if (im) _evas_cache_image_entry_delete(cache, im); return NULL; @@ -879,7 +881,7 @@ evas_cache_image_drop(Image_Entry *im) #ifdef EVAS_FRAME_QUEUING LKU(im->lock_references); #endif - + cache = im->cache; if (references == 0) @@ -893,25 +895,25 @@ evas_cache_image_drop(Image_Entry *im) LKU(im->ref_fq_del); return; } - LKU(im->ref_fq_add); - LKU(im->ref_fq_del); + LKU(im->ref_fq_add); + LKU(im->ref_fq_del); #endif #ifdef BUILD_ASYNC_PRELOAD - if (im->preload) - { - _evas_cache_image_entry_preload_remove(im, NULL); - return; - } -#endif - - if (im->flags.dirty) - { - _evas_cache_image_entry_delete(cache, im); - return; - } + if (im->preload) + { + _evas_cache_image_entry_preload_remove(im, NULL); + return; + } +#endif + + if (im->flags.dirty) + { + _evas_cache_image_entry_delete(cache, im); + return; + } _evas_cache_image_lru_add(im); - if (cache) evas_cache_image_flush(cache); + if (cache) evas_cache_image_flush(cache); } } @@ -974,10 +976,10 @@ evas_cache_image_dirty(Image_Entry *im, unsigned int x, unsigned int y, unsigned } _evas_cache_image_dirty_add(im_dirty); } - + if (cache->func.debug) cache->func.debug("dirty-region", im_dirty); if (cache->func.dirty_region) - cache->func.dirty_region(im_dirty, x, y, w, h); + cache->func.dirty_region(im_dirty, x, y, w, h); return im_dirty; on_error: @@ -1026,7 +1028,7 @@ evas_cache_image_alone(Image_Entry *im) evas_cache_image_drop(im); } return im_dirty; - + on_error: if (im_dirty) _evas_cache_image_entry_delete(cache, im_dirty); evas_cache_image_drop(im); @@ -1039,12 +1041,12 @@ evas_cache_image_copied_data(Evas_Cache_Image *cache, DATA32 *image_data, int alpha, int cspace) { Image_Entry *im; - + if ((cspace == EVAS_COLORSPACE_YCBCR422P601_PL) || (cspace == EVAS_COLORSPACE_YCBCR422P709_PL) || (cspace == EVAS_COLORSPACE_YCBCR422601_PL)) - w &= ~0x1; - + w &= ~0x1; + im = _evas_cache_image_entry_new(cache, NULL, NULL, NULL, NULL, NULL, NULL); if (!im) return NULL; im->space = cspace; @@ -1074,8 +1076,8 @@ evas_cache_image_data(Evas_Cache_Image *cache, unsigned int w, unsigned int h, D if ((cspace == EVAS_COLORSPACE_YCBCR422P601_PL) || (cspace == EVAS_COLORSPACE_YCBCR422P709_PL) || (cspace == EVAS_COLORSPACE_YCBCR422601_PL)) - w &= ~0x1; - + w &= ~0x1; + im = _evas_cache_image_entry_new(cache, NULL, NULL, NULL, NULL, NULL, NULL); if (!im) return NULL; im->w = w; @@ -1101,7 +1103,7 @@ EAPI void evas_cache_image_surface_alloc(Image_Entry *im, unsigned int w, unsigned int h) { Evas_Cache_Image *cache = im->cache; - + if ((im->space == EVAS_COLORSPACE_YCBCR422P601_PL) || (im->space == EVAS_COLORSPACE_YCBCR422P709_PL) || (im->space == EVAS_COLORSPACE_YCBCR422601_PL)) @@ -1145,7 +1147,7 @@ evas_cache_image_size_set(Image_Entry *im, unsigned int w, unsigned int h) if (cache->func.debug) cache->func.debug("size_set", im2); return im2; - on_error: +on_error: if (im2) _evas_cache_image_entry_delete(cache, im2); evas_cache_image_drop(im); return NULL; @@ -1163,26 +1165,26 @@ evas_cache_image_load_data(Image_Entry *im) #ifdef BUILD_ASYNC_PRELOAD if (im->preload) { - preload = EINA_TRUE; - if (!im->flags.pending) - { - im->cache->preload = eina_list_remove(im->cache->preload, im); - im->cache->pending = eina_list_append(im->cache->pending, im); - im->flags.pending = 1; - evas_preload_thread_cancel(im->preload); - } - evas_async_events_process(); - LKL(wakeup); - while (im->preload) - { + preload = EINA_TRUE; + if (!im->flags.pending) + { + im->cache->preload = eina_list_remove(im->cache->preload, im); + im->cache->pending = eina_list_append(im->cache->pending, im); + im->flags.pending = 1; + evas_preload_thread_cancel(im->preload); + } + evas_async_events_process(); + LKL(wakeup); + while (im->preload) + { eina_condition_wait(&cond_wakeup); - LKU(wakeup); - evas_async_events_process(); - LKL(wakeup); - } - LKU(wakeup); + LKU(wakeup); + evas_async_events_process(); + LKL(wakeup); + } + LKU(wakeup); } - + if ((im->flags.loaded) && (!im->flags.animated)) return error; LKL(im->lock); #endif @@ -1226,7 +1228,7 @@ evas_cache_image_unload_data(Image_Entry *im) #ifdef BUILD_ASYNC_PRELOAD LKU(im->lock); #endif - return; + return; } im->cache->func.destructor(im); #ifdef BUILD_ASYNC_PRELOAD @@ -1256,8 +1258,8 @@ evas_cache_image_unload_all(Evas_Cache_Image *cache) EAPI Eina_Bool evas_cache_image_is_loaded(Image_Entry *im) { - if (im->flags.loaded) return EINA_TRUE; - return EINA_FALSE; + if (im->flags.loaded) return EINA_TRUE; + return EINA_FALSE; } EAPI void @@ -1265,15 +1267,15 @@ evas_cache_image_preload_data(Image_Entry *im, const void *target) { #ifdef BUILD_ASYNC_PRELOAD RGBA_Image *img = (RGBA_Image *)im; - + if ((im->flags.loaded) && (img->image.data)) { - evas_object_inform_call_image_preloaded((Evas_Object *)target); - return; + evas_object_inform_call_image_preloaded((Evas_Object *)target); + return; } im->flags.loaded = 0; if (!_evas_cache_image_entry_preload_add(im, target)) - evas_object_inform_call_image_preloaded((Evas_Object *)target); + evas_object_inform_call_image_preloaded((Evas_Object *)target); #else evas_cache_image_load_data(im); evas_object_inform_call_image_preloaded((Evas_Object *)target); @@ -1319,7 +1321,7 @@ static void _dump_cache(Evas_Cache_Image *cache) { Image_Entry *im; - + printf("--CACHE DUMP----------------------------------------------------\n"); printf("cache: %ikb / %ikb\n", cache->usage / 1024, @@ -1342,22 +1344,22 @@ EAPI int evas_cache_image_flush(Evas_Cache_Image *cache) { #ifdef CACHEDUMP - _dump_cache(cache); + _dump_cache(cache); #endif if (cache->limit == (unsigned int)-1) return -1; while ((cache->lru) && (cache->limit < (unsigned int)cache->usage)) { Image_Entry *im; - + im = (Image_Entry *)cache->lru->last; _evas_cache_image_entry_delete(cache, im); } - + while ((cache->lru_nodata) && (cache->limit < (unsigned int)cache->usage)) { Image_Entry *im; - + im = (Image_Entry *) cache->lru_nodata->last; _evas_cache_image_lru_nodata_del(im); cache->func.surface_delete(im); diff --git a/libraries/evas/src/lib/canvas/Makefile.am b/libraries/evas/src/lib/canvas/Makefile.am index 79544aa..e302668 100644 --- a/libraries/evas/src/lib/canvas/Makefile.am +++ b/libraries/evas/src/lib/canvas/Makefile.am @@ -8,7 +8,6 @@ AM_CPPFLAGS = \ -DPACKAGE_BIN_DIR=\"$(bindir)\" \ -DPACKAGE_LIB_DIR=\"$(libdir)\" \ -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \ -@WIN32_CPPFLAGS@ \ @FREETYPE_CFLAGS@ \ @EET_CFLAGS@ \ @FONTCONFIG_CFLAGS@ \ diff --git a/libraries/evas/src/lib/canvas/Makefile.in b/libraries/evas/src/lib/canvas/Makefile.in index 75da67a..c7e48bc 100644 --- a/libraries/evas/src/lib/canvas/Makefile.in +++ b/libraries/evas/src/lib/canvas/Makefile.in @@ -161,6 +161,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -211,6 +213,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -229,8 +233,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -304,8 +306,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -393,10 +393,9 @@ AM_CPPFLAGS = -I. -I$(top_srcdir)/src/lib \ -I$(top_srcdir)/src/lib/include -I$(top_srcdir)/src/lib/cserve \ -DPACKAGE_BIN_DIR=\"$(bindir)\" \ -DPACKAGE_LIB_DIR=\"$(libdir)\" \ - -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" @WIN32_CPPFLAGS@ \ - @FREETYPE_CFLAGS@ @EET_CFLAGS@ @FONTCONFIG_CFLAGS@ \ - @EVAS_CFLAGS@ @EINA_CFLAGS@ @EVIL_CFLAGS@ @PIXMAN_CFLAGS@ \ - $(am__append_1) + -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" @FREETYPE_CFLAGS@ \ + @EET_CFLAGS@ @FONTCONFIG_CFLAGS@ @EVAS_CFLAGS@ @EINA_CFLAGS@ \ + @EVIL_CFLAGS@ @PIXMAN_CFLAGS@ $(am__append_1) noinst_LTLIBRARIES = libevas_canvas.la libevas_canvas_la_SOURCES = \ evas_callbacks.c \ diff --git a/libraries/evas/src/lib/canvas/evas_callbacks.c b/libraries/evas/src/lib/canvas/evas_callbacks.c index 93f34f2..47cfb0c 100644 --- a/libraries/evas/src/lib/canvas/evas_callbacks.c +++ b/libraries/evas/src/lib/canvas/evas_callbacks.c @@ -172,6 +172,15 @@ evas_object_event_callback_call(Evas_Object *obj, Evas_Callback_Type type, void if ((obj->delete_me) || (!obj->layer)) return; if ((obj->last_event == event_id) && (obj->last_event_type == type)) return; + if (obj->last_event > event_id) + { + if ((obj->last_event_type == EVAS_CALLBACK_MOUSE_OUT) && + ((type >= EVAS_CALLBACK_MOUSE_DOWN) && + (type <= EVAS_CALLBACK_MULTI_MOVE))) + { + return; + } + } obj->last_event = event_id; obj->last_event_type = type; if (!(e = obj->layer->evas)) return; diff --git a/libraries/evas/src/lib/canvas/evas_events.c b/libraries/evas/src/lib/canvas/evas_events.c index 9b7077e..1ee8388 100644 --- a/libraries/evas/src/lib/canvas/evas_events.c +++ b/libraries/evas/src/lib/canvas/evas_events.c @@ -486,8 +486,9 @@ evas_event_feed_mouse_up(Evas *e, int b, Evas_Button_Flags flags, unsigned int t } if (!obj->delete_me) { - if (e->events_frozen <= 0) - evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_UP, &ev, event_id); + if ((e->events_frozen <= 0) && + (!evas_event_freezes_through(obj))) + evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_UP, &ev, event_id); } if (e->delete_me) break; if (obj->pointer_mode == EVAS_OBJECT_POINTER_MODE_NOGRAB_NO_REPEAT_UPDOWN) @@ -1668,18 +1669,6 @@ evas_object_freeze_events_set(Evas_Object *obj, Eina_Bool freeze) if (obj->freeze_events == freeze) return; obj->freeze_events = freeze; evas_object_smart_member_cache_invalidate(obj, EINA_FALSE, EINA_TRUE); - if (evas_object_is_in_output_rect(obj, - obj->layer->evas->pointer.x, - obj->layer->evas->pointer.y, 1, 1) && - ((!obj->precise_is_inside) || - (evas_object_is_inside(obj, - obj->layer->evas->pointer.x, - obj->layer->evas->pointer.y)))) - evas_event_feed_mouse_move(obj->layer->evas, - obj->layer->evas->pointer.x, - obj->layer->evas->pointer.y, - obj->layer->evas->last_timestamp, - NULL); } EAPI Eina_Bool diff --git a/libraries/evas/src/lib/canvas/evas_map.c b/libraries/evas/src/lib/canvas/evas_map.c index 2359d5a..5dcb760 100644 --- a/libraries/evas/src/lib/canvas/evas_map.c +++ b/libraries/evas/src/lib/canvas/evas_map.c @@ -35,7 +35,7 @@ _evas_map_calc_geom_change(Evas_Object *obj) static void _evas_map_calc_map_geometry(Evas_Object *obj) { - Evas_Coord x1, x2, y1, y2; + Evas_Coord x1, x2, yy1, yy2; const Evas_Map_Point *p, *p_end; Eina_Bool ch = EINA_FALSE; @@ -82,7 +82,7 @@ _evas_map_calc_map_geometry(Evas_Object *obj) p = obj->cur.map->points; p_end = p + obj->cur.map->count; x1 = x2 = lround(p->x); - y1 = y2 = lround(p->y); + yy1 = yy2 = lround(p->y); p++; for (; p < p_end; p++) { @@ -92,21 +92,21 @@ _evas_map_calc_map_geometry(Evas_Object *obj) y = lround(p->y); if (x < x1) x1 = x; if (x > x2) x2 = x; - if (y < y1) y1 = y; - if (y > y2) y2 = y; + if (y < yy1) yy1 = y; + if (y > yy2) yy2 = y; } // this causes clip-out bugs now mapped objs canbe opaque!!! // // add 1 pixel of fuzz around the map region to ensure updates are correct -// x1 -= 1; y1 -= 1; -// x2 += 1; y2 += 1; +// x1 -= 1; yy1 -= 1; +// x2 += 1; yy2 += 1; if (obj->cur.map->normal_geometry.x != x1) ch = 1; - if (obj->cur.map->normal_geometry.y != y1) ch = 1; + if (obj->cur.map->normal_geometry.y != yy1) ch = 1; if (obj->cur.map->normal_geometry.w != (x2 - x1)) ch = 1; - if (obj->cur.map->normal_geometry.h != (y2 - y1)) ch = 1; + if (obj->cur.map->normal_geometry.h != (yy2 - yy1)) ch = 1; obj->cur.map->normal_geometry.x = x1; - obj->cur.map->normal_geometry.y = y1; + obj->cur.map->normal_geometry.y = yy1; obj->cur.map->normal_geometry.w = (x2 - x1); - obj->cur.map->normal_geometry.h = (y2 - y1); + obj->cur.map->normal_geometry.h = (yy2 - yy1); if (ch) _evas_map_calc_geom_change(obj); } @@ -374,9 +374,11 @@ evas_object_map_enable_set(Evas_Object *obj, Eina_Bool enabled) MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ); return; MAGIC_CHECK_END(); + Eina_Bool pchange = EINA_FALSE; enabled = !!enabled; if (obj->cur.usemap == enabled) return; + pchange = obj->changed; obj->cur.usemap = enabled; if (enabled) { @@ -405,6 +407,8 @@ evas_object_map_enable_set(Evas_Object *obj, Eina_Bool enabled) /* This is a bit heavy handed, but it fixes the case of same geometry, but * changed colour or UV settings. */ evas_object_change(obj); + if (!obj->changed_pchange) obj->changed_pchange = pchange; + obj->changed_map = EINA_TRUE; } EAPI Eina_Bool @@ -896,7 +900,7 @@ evas_map_util_3d_lighting(Evas_Map *m, for (i = 0; i < m->count; i++) { double x, y, z; - double nx, ny, nz, x1, y1, z1, x2, y2, z2, ln, br; + double nx, ny, nz, x1, yy1, z1, x2, yy2, z2, ln, br; int h, j, mr, mg, mb; x = m->points[i].x; @@ -907,15 +911,15 @@ evas_map_util_3d_lighting(Evas_Map *m, j = (i + 1) % 4 + (i & ~0x3); // next point x1 = m->points[h].x - x; - y1 = m->points[h].y - y; + yy1 = m->points[h].y - y; z1 = m->points[h].z - z; x2 = m->points[j].x - x; - y2 = m->points[j].y - y; + yy2 = m->points[j].y - y; z2 = m->points[j].z - z; - nx = (y1 * z2) - (z1 * y2); + nx = (yy1 * z2) - (z1 * yy2); ny = (z1 * x2) - (x1 * z2); - nz = (x1 * y2) - (y1 * x2); + nz = (x1 * yy2) - (yy1 * x2); ln = (nx * nx) + (ny * ny) + (nz * nz); ln = sqrt(ln); diff --git a/libraries/evas/src/lib/canvas/evas_object_image.c b/libraries/evas/src/lib/canvas/evas_object_image.c index d9f6378..4ebea08 100644 --- a/libraries/evas/src/lib/canvas/evas_object_image.c +++ b/libraries/evas/src/lib/canvas/evas_object_image.c @@ -2908,11 +2908,31 @@ evas_object_image_render(Evas_Object *obj, void *output, void *context, void *su { Evas_Coord idw, idh, idx, idy; int ix, iy, iw, ih; + int img_set = 0; if (o->dirty_pixels) { if (o->func.get_pixels) { + // Set img object for direct rendering optimization + // Check for image w/h against image geometry w/h + // Check for image color r,g,b,a = {255,255,255,255} + // Check and make sure that there are no maps. + if ( (obj->cur.geometry.w == o->cur.image.w) && + (obj->cur.geometry.h == o->cur.image.h) && + (obj->cur.color.r == 255) && + (obj->cur.color.g == 255) && + (obj->cur.color.b == 255) && + (obj->cur.color.a == 255) && + (!obj->cur.map) ) + { + if (obj->layer->evas->engine.func->gl_img_obj_set) + { + obj->layer->evas->engine.func->gl_img_obj_set(output, obj, o->cur.has_alpha); + img_set = 1; + } + } + o->func.get_pixels(o->func.get_pixels_data, obj); if (o->engine_data != pixels) pixels = o->engine_data; @@ -3152,7 +3172,17 @@ evas_object_image_render(Evas_Object *obj, void *output, void *context, void *su idy = ydy; if (dobreak_w) break; } - } + } + + // Unset img object + if (img_set) + { + if (obj->layer->evas->engine.func->gl_img_obj_set) + { + obj->layer->evas->engine.func->gl_img_obj_set(output, NULL, 0); + img_set = 0; + } + } } } @@ -3371,10 +3401,10 @@ evas_object_image_render_pre(Evas_Object *obj) y = idy; h = ((int)(idy + idh)) - y; - r.x = ((rr->x - 1) * w) / o->cur.image.w; - r.y = ((rr->y - 1) * h) / o->cur.image.h; - r.w = ((rr->w + 2) * w) / o->cur.image.w; - r.h = ((rr->h + 2) * h) / o->cur.image.h; + r.x = (rr->x * w) / o->cur.image.w; + r.y = (rr->y * h) / o->cur.image.h; + r.w = ((rr->w * w) + (o->cur.image.w * 2) - 1) / o->cur.image.w; + r.h = ((rr->h * h) + (o->cur.image.h * 2) - 1) / o->cur.image.h; r.x += obj->cur.geometry.x + x; r.y += obj->cur.geometry.y + y; RECTS_CLIP_TO_RECT(r.x, r.y, r.w, r.h, diff --git a/libraries/evas/src/lib/canvas/evas_object_main.c b/libraries/evas/src/lib/canvas/evas_object_main.c index 86ab498..81fc858 100644 --- a/libraries/evas/src/lib/canvas/evas_object_main.c +++ b/libraries/evas/src/lib/canvas/evas_object_main.c @@ -230,7 +230,7 @@ evas_object_clip_changes_clean(Evas_Object *obj) } void -evas_object_render_pre_effect_updates(Eina_Array *rects, Evas_Object *obj, int is_v, int was_v) +evas_object_render_pre_effect_updates(Eina_Array *rects, Evas_Object *obj, int is_v, int was_v __UNUSED__) { Eina_Rectangle *r; Evas_Object *clipper; @@ -241,7 +241,6 @@ evas_object_render_pre_effect_updates(Eina_Array *rects, Evas_Object *obj, int i if (obj->smart.smart) goto end; /* FIXME: was_v isn't used... why? */ - was_v = 0; if (!obj->clip.clipees) { EINA_ARRAY_ITER_NEXT(rects, i, r, it) @@ -1042,6 +1041,22 @@ evas_object_color_set(Evas_Object *obj, int r, int g, int b, int a) if (g > 255) g = 255; if (g < 0) g = 0; if (b > 255) b = 255; if (b < 0) b = 0; if (a > 255) a = 255; if (a < 0) a = 0; + if (r > a) + { + r = a; + ERR("Evas only handle pre multiplied color !"); + } + if (g > a) + { + g = a; + ERR("Evas only handle pre multiplied color !"); + } + if (b > a) + { + b = a; + ERR("Evas only handle pre multiplied color !"); + } + if (evas_object_intercept_call_color_set(obj, r, g, b, a)) return; if (obj->smart.smart) { diff --git a/libraries/evas/src/lib/canvas/evas_object_textblock.c b/libraries/evas/src/lib/canvas/evas_object_textblock.c index 568911c..ee07e20 100644 --- a/libraries/evas/src/lib/canvas/evas_object_textblock.c +++ b/libraries/evas/src/lib/canvas/evas_object_textblock.c @@ -430,6 +430,7 @@ struct _Evas_Object_Textblock { DATA32 magic; Evas_Textblock_Style *style; + Evas_Textblock_Style *style_user; Evas_Textblock_Cursor *cursor; Eina_List *cursors; Evas_Object_Textblock_Node_Text *text_nodes; @@ -4185,11 +4186,27 @@ _layout(const Evas_Object *obj, int w, int h, int *w_ret, int *h_ret) /* Start of logical layout creation */ /* setup default base style */ - if ((c->o->style) && (c->o->style->default_tag)) { - c->fmt = _layout_format_push(c, NULL, NULL); - _format_fill(c->obj, c->fmt, c->o->style->default_tag); - _format_finalize(c->obj, c->fmt); + Eina_Bool finalize = EINA_FALSE; + if ((c->o->style) && (c->o->style->default_tag)) + { + c->fmt = _layout_format_push(c, NULL, NULL); + _format_fill(c->obj, c->fmt, c->o->style->default_tag); + finalize = EINA_TRUE; + } + + if ((c->o->style_user) && (c->o->style_user->default_tag)) + { + if (!c->fmt) + { + c->fmt = _layout_format_push(c, NULL, NULL); + } + _format_fill(c->obj, c->fmt, c->o->style_user->default_tag); + finalize = EINA_TRUE; + } + + if (finalize) + _format_finalize(c->obj, c->fmt); } if (!c->fmt) { @@ -4485,9 +4502,9 @@ evas_textblock_style_set(Evas_Textblock_Style *ts, const char *text) { // format MUST be KEY='VALUE'[KEY='VALUE']... const char *p; - const char *key_start, *key_stop, *val_start, *val_stop; + const char *key_start, *key_stop, *val_start; - key_start = key_stop = val_start = val_stop = NULL; + key_start = key_stop = val_start = NULL; p = ts->style_text; while (*p) { @@ -4504,19 +4521,54 @@ evas_textblock_style_set(Evas_Textblock_Style *ts, const char *text) else if (!val_start) { if (((*p) == '\'') && (*(p + 1))) - val_start = p + 1; - } - else if (!val_stop) - { - if (((*p) == '\'') && (p > ts->style_text) && (p[-1] != '\\')) - val_stop = p; + { + val_start = ++p; + } } - if ((key_start) && (key_stop) && (val_start) && (val_stop)) + if ((key_start) && (key_stop) && (val_start)) { - char *tags, *replaces; + char *tags, *replaces = NULL; Evas_Object_Style_Tag *tag; - size_t tag_len = key_stop - key_start; - size_t replace_len = val_stop - val_start; + const char *val_stop = NULL; + size_t tag_len; + size_t replace_len; + + { + Eina_Strbuf *buf = eina_strbuf_new(); + val_stop = val_start; + while(*p) + { + if (*p == '\'') + { + /* Break if we found the tag end */ + if (p[-1] != '\\') + { + eina_strbuf_append_length(buf, val_stop, + p - val_stop); + break; + } + else + { + eina_strbuf_append_length(buf, val_stop, + p - val_stop - 1); + eina_strbuf_append_char(buf, '\''); + val_stop = p + 1; + } + } + p++; + } + replaces = eina_strbuf_string_steal(buf); + eina_strbuf_free(buf); + } + /* If we didn't find an end, just aboart. */ + if (!*p) + { + if (replaces) free(replaces); + break; + } + + tag_len = key_stop - key_start; + replace_len = val_stop - val_start; tags = malloc(tag_len + 1); if (tags) @@ -4525,12 +4577,6 @@ evas_textblock_style_set(Evas_Textblock_Style *ts, const char *text) tags[tag_len] = 0; } - replaces = malloc(replace_len + 1); - if (replaces) - { - memcpy(replaces, val_start, replace_len); - replaces[replace_len] = 0; - } if ((tags) && (replaces)) { if (!strcmp(tags, "DEFAULT")) @@ -4561,7 +4607,7 @@ evas_textblock_style_set(Evas_Textblock_Style *ts, const char *text) if (tags) free(tags); if (replaces) free(replaces); } - key_start = key_stop = val_start = val_stop = NULL; + key_start = key_stop = val_start = NULL; } p++; } @@ -4576,13 +4622,15 @@ evas_textblock_style_get(const Evas_Textblock_Style *ts) } /* textblock styles */ -EAPI void -evas_object_textblock_style_set(Evas_Object *obj, Evas_Textblock_Style *ts) + +static void +_textblock_style_generic_set(Evas_Object *obj, Evas_Textblock_Style *ts, + Evas_Textblock_Style **obj_ts) { TB_HEAD(); - if (ts == o->style) return; + if (ts == *obj_ts) return; if ((ts) && (ts->delete_me)) return; - if (o->style) + if (*obj_ts) { Evas_Textblock_Style *old_ts; if (o->markup_text) @@ -4591,7 +4639,7 @@ evas_object_textblock_style_set(Evas_Object *obj, Evas_Textblock_Style *ts) o->markup_text = NULL; } - old_ts = o->style; + old_ts = *obj_ts; old_ts->objects = eina_list_remove(old_ts->objects, obj); if ((old_ts->delete_me) && (!old_ts->objects)) evas_textblock_style_free(old_ts); @@ -4600,12 +4648,19 @@ evas_object_textblock_style_set(Evas_Object *obj, Evas_Textblock_Style *ts) { ts->objects = eina_list_append(ts->objects, obj); } - o->style = ts; + *obj_ts = ts; _evas_textblock_invalidate_all(o); _evas_textblock_changed(o, obj); } +EAPI void +evas_object_textblock_style_set(Evas_Object *obj, Evas_Textblock_Style *ts) +{ + TB_HEAD(); + _textblock_style_generic_set(obj, ts, &(o->style)); +} + EAPI const Evas_Textblock_Style * evas_object_textblock_style_get(const Evas_Object *obj) { @@ -4614,6 +4669,27 @@ evas_object_textblock_style_get(const Evas_Object *obj) } EAPI void +evas_object_textblock_style_user_push(Evas_Object *obj, Evas_Textblock_Style *ts) +{ + TB_HEAD(); + _textblock_style_generic_set(obj, ts, &(o->style_user)); +} + +EAPI const Evas_Textblock_Style * +evas_object_textblock_style_user_peek(const Evas_Object *obj) +{ + TB_HEAD_RETURN(NULL); + return o->style_user; +} + +EAPI void +evas_object_textblock_style_user_pop(Evas_Object *obj) +{ + TB_HEAD(); + _textblock_style_generic_set(obj, NULL, &(o->style_user)); +} + +EAPI void evas_object_textblock_replace_char_set(Evas_Object *obj, const char *ch) { TB_HEAD(); @@ -4902,7 +4978,7 @@ evas_object_textblock_text_markup_set(Evas_Object *obj, const char *text) o->markup_text = NULL; } _nodes_clear(obj); - if (!o->style) + if (!o->style && !o->style_user) { if (text != o->markup_text) { @@ -5244,7 +5320,7 @@ evas_textblock_text_markup_to_utf8(const Evas_Object *obj, const char *text) const char *escape; escape = _escaped_char_get(esc_start, esc_end + 1); - eina_strbuf_append(sbuf, escape); + if (escape) eina_strbuf_append(sbuf, escape); esc_start = esc_end = NULL; } else if (*p == 0) @@ -5650,7 +5726,6 @@ EAPI Eina_Bool evas_textblock_cursor_is_format(const Evas_Textblock_Cursor *cur) { if (!cur || !cur->node) return EINA_FALSE; - if (evas_textblock_cursor_format_is_visible_get(cur)) return EINA_TRUE; return (_evas_textblock_cursor_node_format_at_pos_get(cur)) ? EINA_TRUE : EINA_FALSE; } @@ -5977,9 +6052,9 @@ evas_textblock_cursor_format_prev(Evas_Textblock_Cursor *cur) #else #define BREAK_AFTER(i) \ - ((!str[i + 1]) || \ - (_is_white(str[i]) && !_is_white(str[i + 1])) || \ - (!_is_white(str[i]) && _is_white(str[i + 1]))) + ((!text[i + 1]) || \ + (_is_white(text[i]) && !_is_white(text[i + 1])) || \ + (!_is_white(text[i]) && _is_white(text[i + 1]))) #endif @@ -7241,7 +7316,13 @@ _evas_textblock_node_format_new(Evas_Object_Textblock *o, const char *_format) } } - match = _style_match_tag(o->style, format, format_len, &replace_len); + if (!o->style_user || !(match = _style_match_tag(o->style_user, format, + format_len, &replace_len))) + { + match = _style_match_tag(o->style, format, format_len, + &replace_len); + } + if (match) { if (match[0] != '-') @@ -7633,6 +7714,7 @@ evas_textblock_cursor_range_delete(Evas_Textblock_Cursor *cur1, Evas_Textblock_C } fnode = _evas_textblock_cursor_node_format_at_pos_get(cur1); + n1->dirty = n2->dirty = EINA_TRUE; if (should_merge) { /* We call this function instead of the cursor one because we already @@ -7646,7 +7728,6 @@ evas_textblock_cursor_range_delete(Evas_Textblock_Cursor *cur1, Evas_Textblock_C evas_textblock_cursor_copy(cur1, o->cursor); _evas_textblock_changed(o, cur1->obj); - n1->dirty = n2->dirty = EINA_TRUE; } @@ -8022,6 +8103,7 @@ evas_textblock_cursor_format_is_visible_get(const Evas_Textblock_Cursor *cur) if (!cur) return EINA_FALSE; if (!cur->node) return EINA_FALSE; + if (!evas_textblock_cursor_is_format(cur)) return EINA_FALSE; text = eina_ustrbuf_string_get(cur->node->unicode); return EVAS_TEXTBLOCK_IS_VISIBLE_FORMAT_CHAR(text[cur->pos]); } @@ -9016,12 +9098,22 @@ _size_native_calc_line_finalize(const Evas_Object *obj, Eina_List *items, Eina_List *i; it = eina_list_data_get(items); - /* If there are no text items yet, calc ascent/descent - * according to the current format. */ - if (it && (*ascent + *descent == 0)) - _layout_format_ascent_descent_adjust(obj, ascent, descent, it->format); - *w = 0; + + if (it) + { + /* If there are no text items yet, calc ascent/descent + * according to the current format. */ + if (*ascent + *descent == 0) + _layout_format_ascent_descent_adjust(obj, ascent, descent, + it->format); + + /* Add margins. */ + if (it->format) + *w = it->format->margin.l + it->format->margin.r; + } + + /* Adjust all the item sizes according to the final line size, * and update the x positions of all the items of the line. */ EINA_LIST_FOREACH(items, i, it) @@ -9226,6 +9318,10 @@ evas_object_textblock_free(Evas_Object *obj) evas_object_textblock_clear(obj); evas_object_textblock_style_set(obj, NULL); + while (evas_object_textblock_style_user_peek(obj)) + { + evas_object_textblock_style_user_pop(obj); + } o = (Evas_Object_Textblock *)(obj->object_data); free(o->cursor); while (o->cursors) diff --git a/libraries/evas/src/lib/canvas/evas_render.c b/libraries/evas/src/lib/canvas/evas_render.c index cdedaec..32ce988 100644 --- a/libraries/evas/src/lib/canvas/evas_render.c +++ b/libraries/evas/src/lib/canvas/evas_render.c @@ -612,6 +612,8 @@ pending_change(void *data, void *gdata __UNUSED__) obj->changed_move_only = 0; obj->changed_nomove = 0; obj->changed_move = 0; + obj->changed_map = 0; + obj->changed_pchange = 0; } return obj->changed ? EINA_TRUE : EINA_FALSE; } @@ -984,6 +986,8 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface, o2->changed_move_only = 0; o2->changed_nomove = 0; o2->changed_move = 0; + o2->changed_map = 0; + o2->changed_pchange = 0; continue; } if (o2->changed) @@ -994,6 +998,8 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface, o2->changed_move_only = 0; o2->changed_nomove = 0; o2->changed_move = 0; + o2->changed_map = 0; + o2->changed_pchange = 0; break; } } @@ -1002,16 +1008,21 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface, obj->changed_move_only = 0; obj->changed_nomove = 0; obj->changed_move = 0; + obj->changed_map = 0; + obj->changed_pchange = 0; } else { if (obj->changed) { - changed = 1; + if ((obj->changed_pchange) && (obj->changed_map)) + changed = 1; obj->changed = 0; obj->changed_move_only = 0; obj->changed_nomove = 0; obj->changed_move = 0; + obj->changed_map = 0; + obj->changed_pchange = 0; } } @@ -1144,10 +1155,12 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface, e->engine.data.context, ecx, ecy, ecw, ech); if (obj->cur.cache.clip.visible) - obj->layer->evas->engine.func->image_map_draw - (e->engine.data.output, e->engine.data.context, surface, - obj->cur.map->surface, obj->cur.map->count, pts, - obj->cur.map->smooth, 0); + { + obj->layer->evas->engine.func->image_map_draw + (e->engine.data.output, e->engine.data.context, surface, + obj->cur.map->surface, obj->cur.map->count, pts, + obj->cur.map->smooth, 0); + } // FIXME: needs to cache these maps and // keep them only rendering updates // obj->layer->evas->engine.func->image_map_surface_free @@ -1500,6 +1513,12 @@ evas_render_updates_internal(Evas *e, off_x = cx - ux; off_y = cy - uy; /* build obscuring objects list (in order from bottom to top) */ + if (alpha) + { + e->engine.func->context_clip_set(e->engine.data.output, + e->engine.data.context, + ux + off_x, uy + off_y, uw, uh); + } for (i = 0; i < e->obscuring_objects.count; ++i) { obj = (Evas_Object *)eina_array_data_get @@ -1515,9 +1534,6 @@ evas_render_updates_internal(Evas *e, } if (alpha) { - e->engine.func->context_clip_set(e->engine.data.output, - e->engine.data.context, - ux + off_x, uy + off_y, uw, uh); e->engine.func->context_color_set(e->engine.data.output, e->engine.data.context, 0, 0, 0, 0); @@ -1548,7 +1564,7 @@ evas_render_updates_internal(Evas *e, (obj->cur.visible) && (!obj->delete_me) && (obj->cur.cache.clip.visible) && - // (!obj->smart.smart) && +// (!obj->smart.smart) && ((obj->cur.color.a > 0 || obj->cur.render_op != EVAS_RENDER_BLEND))) { int x, y, w, h; @@ -1579,6 +1595,9 @@ evas_render_updates_internal(Evas *e, else e->engine.func->context_mask_unset(e->engine.data.output, e->engine.data.context); + e->engine.func->context_clip_set(e->engine.data.output, + e->engine.data.context, + x, y, w, h); #if 1 /* FIXME: this can slow things down... figure out optimum... coverage */ for (j = offset; j < e->temporary_objects.count; ++j) { @@ -1589,9 +1608,6 @@ evas_render_updates_internal(Evas *e, _evas_render_cutout_add(e, obj2, off_x, off_y); } #endif - e->engine.func->context_clip_set(e->engine.data.output, - e->engine.data.context, - x, y, w, h); clean_them |= evas_render_mapped(e, obj, e->engine.data.context, surface, off_x, off_y, 0, cx, cy, cw, ch @@ -1637,6 +1653,8 @@ evas_render_updates_internal(Evas *e, obj->changed_move_only = 0; obj->changed_nomove = 0; obj->changed_move = 0; + obj->changed_map = 0; + obj->changed_pchange = 0; } else if ((obj->cur.map != obj->prev.map) || (obj->cur.usemap != obj->prev.usemap)) @@ -1648,6 +1666,8 @@ evas_render_updates_internal(Evas *e, obj->changed_move_only = 0; obj->changed_nomove = 0; obj->changed_move = 0; + obj->changed_map = 0; + obj->changed_pchange = 0; } /* moved to other pre-process phase 1 if (obj->delete_me == 2) @@ -1684,6 +1704,7 @@ evas_render_updates_internal(Evas *e, e->framespace.changed = 0; e->invalidate = 0; + // always clean... lots of mem waste! /* If their are some object to restack or some object to delete, * it's useless to keep the render object list around. */ if (clean_them) @@ -1693,6 +1714,17 @@ evas_render_updates_internal(Evas *e, eina_array_clean(&e->restack_objects); eina_array_clean(&e->delete_objects); eina_array_clean(&e->obscuring_objects); + eina_array_clean(&e->temporary_objects); + eina_array_clean(&e->clip_changes); +/* we should flush here and have a mempool system for this + eina_array_flush(&e->active_objects); + eina_array_flush(&e->render_objects); + eina_array_flush(&e->restack_objects); + eina_array_flush(&e->delete_objects); + eina_array_flush(&e->obscuring_objects); + eina_array_flush(&e->temporary_objects); + eina_array_flush(&e->clip_changes); + */ e->invalidate = 1; } @@ -1768,11 +1800,14 @@ evas_render_idle_flush(Evas *e) (e->engine.data.output)) e->engine.func->output_idle_flush(e->engine.data.output); - eina_array_flush(&e->delete_objects); eina_array_flush(&e->active_objects); - eina_array_flush(&e->restack_objects); eina_array_flush(&e->render_objects); + eina_array_flush(&e->restack_objects); + eina_array_flush(&e->delete_objects); + eina_array_flush(&e->obscuring_objects); + eina_array_flush(&e->temporary_objects); eina_array_flush(&e->clip_changes); + eina_array_flush(&e->temporary_objects); e->invalidate = 1; } diff --git a/libraries/evas/src/lib/cserve/Makefile.in b/libraries/evas/src/lib/cserve/Makefile.in index 7599ca2..caff4d6 100644 --- a/libraries/evas/src/lib/cserve/Makefile.in +++ b/libraries/evas/src/lib/cserve/Makefile.in @@ -148,6 +148,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -198,6 +200,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -216,8 +220,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -291,8 +293,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/Makefile.in b/libraries/evas/src/lib/engines/Makefile.in index 4c3c1da..b5cf292 100644 --- a/libraries/evas/src/lib/engines/Makefile.in +++ b/libraries/evas/src/lib/engines/Makefile.in @@ -158,6 +158,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -208,6 +210,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -226,8 +230,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -301,8 +303,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/Makefile.am b/libraries/evas/src/lib/engines/common/Makefile.am index 9c9918d..0937394 100644 --- a/libraries/evas/src/lib/engines/common/Makefile.am +++ b/libraries/evas/src/lib/engines/common/Makefile.am @@ -13,7 +13,7 @@ AM_CPPFLAGS = -I. \ @FREETYPE_CFLAGS@ @VALGRIND_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EET_CFLAGS@ @pthread_cflags@ \ - @WIN32_CFLAGS@ @EINA_CFLAGS@ \ + @EINA_CFLAGS@ \ @FRIBIDI_CFLAGS@ @HARFBUZZ_CFLAGS@ \ @PIXMAN_CFLAGS@ diff --git a/libraries/evas/src/lib/engines/common/Makefile.in b/libraries/evas/src/lib/engines/common/Makefile.in index 7d1f20a..08526cd 100644 --- a/libraries/evas/src/lib/engines/common/Makefile.in +++ b/libraries/evas/src/lib/engines/common/Makefile.in @@ -202,6 +202,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -252,6 +254,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -270,8 +274,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -345,8 +347,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -441,7 +441,7 @@ AM_CPPFLAGS = -I. \ @FREETYPE_CFLAGS@ @VALGRIND_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EET_CFLAGS@ @pthread_cflags@ \ - @WIN32_CFLAGS@ @EINA_CFLAGS@ \ + @EINA_CFLAGS@ \ @FRIBIDI_CFLAGS@ @HARFBUZZ_CFLAGS@ \ @PIXMAN_CFLAGS@ diff --git a/libraries/evas/src/lib/engines/common/evas_draw_main.c b/libraries/evas/src/lib/engines/common/evas_draw_main.c index def19a8..d08e788 100644 --- a/libraries/evas/src/lib/engines/common/evas_draw_main.c +++ b/libraries/evas/src/lib/engines/common/evas_draw_main.c @@ -559,7 +559,7 @@ evas_common_draw_context_cutout_split(Cutout_Rects* res, int idx, Cutout_Rect *s EAPI Cutout_Rects* evas_common_draw_context_apply_cutouts(RGBA_Draw_Context *dc) { - Cutout_Rects* res; + Cutout_Rects* res, *res2; int i; int j; @@ -583,6 +583,69 @@ evas_common_draw_context_apply_cutouts(RGBA_Draw_Context *dc) active--; } } + /* merge rects */ +#define RI res->rects[i] +#define RJ res->rects[j] + if (res->active > 1) + { + int found = 1; + + while (found) + { + found = 0; + for (i = 0; i < res->active; i++) + { + for (j = i + 1; j < res->active; j++) + { + /* skip empty rects we are removing */ + if (RJ.w == 0) continue; + /* check if its same width, immediately above or below */ + if ((RJ.w == RI.w) && (RJ.x == RI.x)) + { + if ((RJ.y + RJ.h) == RI.y) /* above */ + { + RI.y = RJ.y; + RI.h += RJ.h; + RJ.w = 0; + found = 1; + } + else if ((RI.y + RI.h) == RJ.y) /* below */ + { + RI.h += RJ.h; + RJ.w = 0; + found = 1; + } + } + /* check if its same height, immediately left or right */ + else if ((RJ.h == RI.h) && (RJ.y == RI.y)) + { + if ((RJ.x + RJ.w) == RI.x) /* left */ + { + RI.x = RJ.x; + RI.w += RJ.w; + RJ.w = 0; + found = 1; + } + else if ((RI.x + RI.w) == RJ.x) /* right */ + { + RI.w += RJ.w; + RJ.w = 0; + found = 1; + } + } + } + } + } + res2 = evas_common_draw_context_cutouts_new(); + for (i = 0; i < res->active; i++) + { + if (RI.w == 0) continue; + evas_common_draw_context_cutouts_add(res2, RI.x, RI.y, RI.w, RI.h); + } + free(res->rects); + free(res); + return res2; + } return res; } diff --git a/libraries/evas/src/lib/engines/common/evas_font_load.c b/libraries/evas/src/lib/engines/common/evas_font_load.c index 3fc4521..abba9e3 100644 --- a/libraries/evas/src/lib/engines/common/evas_font_load.c +++ b/libraries/evas/src/lib/engines/common/evas_font_load.c @@ -71,9 +71,7 @@ _evas_common_font_int_free(RGBA_Font_Int *fi) _evas_common_font_int_clear(fi); eina_hash_free(fi->kerning); -#ifdef HAVE_PTHREAD - pthread_mutex_destroy(&fi->ft_mutex); -#endif + LKD(fi->ft_mutex); #ifdef USE_HARFBUZZ hb_font_destroy(fi->ft.hb_font); #endif @@ -301,9 +299,7 @@ _evas_common_font_int_cache_init(RGBA_Font_Int *fi) EINA_KEY_CMP(_evas_common_font_double_int_cmp), EINA_KEY_HASH(_evas_common_font_double_int_hash), free, 3); -#ifdef HAVE_PTHREAD - pthread_mutex_init(&fi->ft_mutex, NULL); -#endif + LKI(fi->ft_mutex); } EAPI RGBA_Font_Int * diff --git a/libraries/evas/src/lib/engines/common/evas_image_main.c b/libraries/evas/src/lib/engines/common/evas_image_main.c index d2f8c0b..9c233b3 100644 --- a/libraries/evas/src/lib/engines/common/evas_image_main.c +++ b/libraries/evas/src/lib/engines/common/evas_image_main.c @@ -16,6 +16,8 @@ # include #endif +//#define SURFDBG 1 + static Evas_Cache_Image * eci = NULL; static int reference = 0; @@ -212,6 +214,30 @@ evas_common_rgba_image_free(Image_Entry *ie) _evas_common_rgba_image_delete(ie); } +#ifdef SURFDBG +static Eina_List *surfs = NULL; + +static void +surf_debug(void) +{ + Eina_List *l; + Image_Entry *ie; + RGBA_Image *im; + int i = 0; + + printf("----SURFS----\n"); + EINA_LIST_FOREACH(surfs, l, ie) + { + im = ie; + printf("%i - %p - %ix%i [%s][%s]\n", + i, im->image.data, ie->allocated.w, ie->allocated.h, + ie->file, ie->key + ); + i++; + } +} +#endif + EAPI void evas_common_rgba_image_unload(Image_Entry *ie) { @@ -252,7 +278,12 @@ evas_common_rgba_image_unload(Image_Entry *ie) #endif if (im->image.data && !im->image.no_free) - free(im->image.data); + { + free(im->image.data); +#ifdef SURFDBG + surfs = eina_list_remove(surfs, ie); +#endif + } im->image.data = NULL; ie->allocated.w = 0; ie->allocated.h = 0; @@ -260,6 +291,9 @@ evas_common_rgba_image_unload(Image_Entry *ie) #ifdef BUILD_ASYNC_PRELOAD ie->flags.preload_done = 0; #endif +#ifdef SURFDBG + surf_debug(); +#endif } void @@ -318,10 +352,20 @@ _evas_common_rgba_image_surface_alloc(Image_Entry *ie, unsigned int w, unsigned else siz = w * h * sizeof(DATA32); - if (im->image.data) free(im->image.data); + if (im->image.data) + { + free(im->image.data); +#ifdef SURFDBG + surfs = eina_list_remove(surfs, ie); +#endif + } im->image.data = malloc(siz); if (!im->image.data) return -1; - + ie->allocated.w = w; + ie->allocated.h = h; +#ifdef SURFDBG + surfs = eina_list_append(surfs, ie); +#endif #ifdef HAVE_VALGRIND # ifdef VALGRIND_MAKE_READABLE VALGRIND_MAKE_READABLE(im->image.data, siz); @@ -332,7 +376,9 @@ _evas_common_rgba_image_surface_alloc(Image_Entry *ie, unsigned int w, unsigned # endif #endif _evas_common_rgba_image_post_surface(ie); - +#ifdef SURFDBG + surf_debug(); +#endif return 0; } @@ -366,7 +412,12 @@ _evas_common_rgba_image_surface_delete(Image_Entry *ie) im->cs.data = NULL; if (im->image.data && !im->image.no_free) - free(im->image.data); + { + free(im->image.data); +#ifdef SURFDBG + surfs = eina_list_remove(surfs, ie); +#endif + } #ifdef EVAS_CSERVE else if (ie->data1) evas_cserve_image_free(ie); @@ -380,6 +431,9 @@ _evas_common_rgba_image_surface_delete(Image_Entry *ie) #endif ie->flags.loaded = 0; evas_common_rgba_image_scalecache_dirty(&im->cache_entry); +#ifdef SURFDBG + surf_debug(); +#endif } static void @@ -597,7 +651,15 @@ evas_common_image_colorspace_normalize(RGBA_Image *im) #ifdef EVAS_CSERVE if (((Image_Entry *)im)->data1) evas_cserve_image_free(&im->cache_entry); #endif - if (!im->image.no_free) free(im->image.data); + if (!im->image.no_free) + { + free(im->image.data); +#ifdef SURFDBG + surfs = eina_list_remove(surfs, im); +#endif + ((Image_Entry *)im)->allocated.w = 0; + ((Image_Entry *)im)->allocated.h = 0; + } im->image.data = im->cs.data; im->cs.no_free = im->image.no_free; } @@ -634,6 +696,9 @@ evas_common_image_colorspace_normalize(RGBA_Image *im) break; } im->cs.dirty = 0; +#ifdef SURFDBG + surf_debug(); +#endif } EAPI void diff --git a/libraries/evas/src/lib/engines/common/evas_op_add/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_add/Makefile.in index 78e893d..61d3479 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_add/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_add/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.am b/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.am index 84add38..77435c4 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.am +++ b/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.am @@ -40,11 +40,7 @@ libevas_engine_common_op_blend_master_sse3_la_CFLAGS = \ @FREETYPE_CFLAGS@ @VALGRIND_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EET_CFLAGS@ @pthread_cflags@ \ -@WIN32_CFLAGS@ @EINA_CFLAGS@ \ +@EINA_CFLAGS@ \ @FRIBIDI_CFLAGS@ @HARFBUZZ_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EVAS_SSE3_CFLAGS@ - -libevas_engine_common_op_blend_master_sse3_la_DEPENENCIES = \ -$(top_builddir)/config.h - diff --git a/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.in index e00dac8..016b49c 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_blend/Makefile.in @@ -153,6 +153,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -203,6 +205,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -221,8 +225,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -296,8 +298,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -420,14 +420,11 @@ libevas_engine_common_op_blend_master_sse3_la_CFLAGS = \ @FREETYPE_CFLAGS@ @VALGRIND_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EET_CFLAGS@ @pthread_cflags@ \ -@WIN32_CFLAGS@ @EINA_CFLAGS@ \ +@EINA_CFLAGS@ \ @FRIBIDI_CFLAGS@ @HARFBUZZ_CFLAGS@ \ @PIXMAN_CFLAGS@ \ @EVAS_SSE3_CFLAGS@ -libevas_engine_common_op_blend_master_sse3_la_DEPENENCIES = \ -$(top_builddir)/config.h - all: all-am .SUFFIXES: diff --git a/libraries/evas/src/lib/engines/common/evas_op_copy/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_copy/Makefile.in index 40536c0..687f34d 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_copy/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_copy/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/evas_op_mask/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_mask/Makefile.in index d5764b1..00b536a 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_mask/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_mask/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/evas_op_mul/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_mul/Makefile.in index d5452fe..849983e 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_mul/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_mul/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/evas_op_sub/Makefile.in b/libraries/evas/src/lib/engines/common/evas_op_sub/Makefile.in index 4b93b1b..885465a 100644 --- a/libraries/evas/src/lib/engines/common/evas_op_sub/Makefile.in +++ b/libraries/evas/src/lib/engines/common/evas_op_sub/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common/evas_polygon_main.c b/libraries/evas/src/lib/engines/common/evas_polygon_main.c index ea0bf13..6840d60 100644 --- a/libraries/evas/src/lib/engines/common/evas_polygon_main.c +++ b/libraries/evas/src/lib/engines/common/evas_polygon_main.c @@ -133,7 +133,7 @@ evas_common_polygon_draw(RGBA_Image *dst, RGBA_Draw_Context *dc, RGBA_Polygon_Po int num_active_edges; int n; int i, j, k; - int y0, y1, yi; + int yy0, yy1, yi; int ext_x, ext_y, ext_w, ext_h; int *sorted_index; @@ -211,14 +211,14 @@ evas_common_polygon_draw(RGBA_Image *dst, RGBA_Draw_Context *dc, RGBA_Polygon_Po k++; } - y0 = MAX(ext_y, ceil(point[sorted_index[0]].y - 0.5)); - y1 = MIN(ext_y + ext_h - 1, floor(point[sorted_index[n - 1]].y - 0.5)); + yy0 = MAX(ext_y, ceil(point[sorted_index[0]].y - 0.5)); + yy1 = MIN(ext_y + ext_h - 1, floor(point[sorted_index[n - 1]].y - 0.5)); k = 0; num_active_edges = 0; spans = NULL; - for (yi = y0; yi <= y1; yi++) + for (yi = yy0; yi <= yy1; yi++) { for (; (k < n) && (point[sorted_index[k]].y <= ((double)yi + 0.5)); k++) { diff --git a/libraries/evas/src/lib/engines/common/evas_scale_sample.c b/libraries/evas/src/lib/engines/common/evas_scale_sample.c index a8951b8..c721c5e 100644 --- a/libraries/evas/src/lib/engines/common/evas_scale_sample.c +++ b/libraries/evas/src/lib/engines/common/evas_scale_sample.c @@ -90,7 +90,6 @@ scale_rgba_in_to_out_clip_sample_internal(RGBA_Image *src, RGBA_Image *dst, DATA32 *buf, *dptr; DATA32 **row_ptr; DATA32 *ptr, *dst_ptr, *src_data, *dst_data; - int dst_jump; int dst_clip_x, dst_clip_y, dst_clip_w, dst_clip_h; int m_clip_x = 0, m_clip_y = 0, m_clip_w = 0, m_clip_h = 0, mdx = 0, mdy = 0; int src_w, src_h, dst_w, dst_h; @@ -248,7 +247,7 @@ scale_rgba_in_to_out_clip_sample_internal(RGBA_Image *src, RGBA_Image *dst, row_ptr = alloca(dst_clip_h * sizeof(DATA32 *)); /* figure out dst jump */ - dst_jump = dst_w - dst_clip_w; + //dst_jump = dst_w - dst_clip_w; /* figure out dest start ptr */ dst_ptr = dst_data + dst_clip_x + (dst_clip_y * dst_w); diff --git a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx.c b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx.c index 50b2e5c..a443c85 100644 --- a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx.c +++ b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx.c @@ -3,7 +3,7 @@ DATA32 *pix, *dptr, *pbuf, **yp; int r, g, b, a, rr, gg, bb, aa; int *xp, xap, yap, pos; - int dyy, dxx; + //int dyy, dxx; int w = dst_clip_w; #ifdef EVAS_SLI int ysli = dst_clip_y; @@ -11,8 +11,8 @@ dptr = dst_ptr; pos = (src_region_y * src_w) + src_region_x; - dyy = dst_clip_y - dst_region_y; - dxx = dst_clip_x - dst_region_x; + //dyy = dst_clip_y - dst_region_y; + //dxx = dst_clip_x - dst_region_x; xp = xpoints;// + dxx; yp = ypoints;// + dyy; diff --git a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx_downy.c b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx_downy.c index ab0c74e..73da3a0 100644 --- a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx_downy.c +++ b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downx_downy.c @@ -3,7 +3,7 @@ DATA32 *dptr, *sptr, *pix, *pbuf; int a, r, g, b, rx, gx, bx, ax; int xap, yap, pos; - int dyy, dxx; + //int dyy, dxx; #ifdef EVAS_SLI int ysli = dst_clip_y; #endif @@ -14,8 +14,8 @@ dptr = dst_ptr; pos = (src_region_y * src_w) + src_region_x; - dyy = dst_clip_y - dst_region_y; - dxx = dst_clip_x - dst_region_x; + //dyy = dst_clip_y - dst_region_y; + //dxx = dst_clip_x - dst_region_x; xp = xpoints;// + dxx; yp = ypoints;// + dyy; diff --git a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downy.c b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downy.c index 4c5448e..3b7585d 100644 --- a/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downy.c +++ b/libraries/evas/src/lib/engines/common/evas_scale_smooth_scaler_downy.c @@ -3,7 +3,7 @@ DATA32 *dptr, *pix, *pbuf, **yp; int r, g, b, a, rr, gg, bb, aa; int *xp, xap, yap, pos; - int dyy, dxx; + //int dyy, dxx; int w = dst_clip_w; #ifdef EVAS_SLI int ysli = dst_clip_y; @@ -11,8 +11,8 @@ dptr = dst_ptr; pos = (src_region_y * src_w) + src_region_x; - dyy = dst_clip_y - dst_region_y; - dxx = dst_clip_x - dst_region_x; + //dyy = dst_clip_y - dst_region_y; + //dxx = dst_clip_x - dst_region_x; xp = xpoints;// + dxx; yp = ypoints;// + dyy; diff --git a/libraries/evas/src/lib/engines/common/evas_tiler.c b/libraries/evas/src/lib/engines/common/evas_tiler.c index ff359a4..bc5e99c 100644 --- a/libraries/evas/src/lib/engines/common/evas_tiler.c +++ b/libraries/evas/src/lib/engines/common/evas_tiler.c @@ -1167,40 +1167,84 @@ evas_common_tilebuf_get_render_rects(Tilebuf *tb) #elif defined(EVAS_RECT_SPLIT) list_node_t *n; Tilebuf_Rect *rects = NULL; + int bx1 = 0, bx2 = 0, by1 = 0, by2 = 0, num = 0; - if (tb->need_merge) { - list_t to_merge; - to_merge = tb->rects; - tb->rects = list_zeroed; - rect_list_merge_rects(&tb->rects, &to_merge, FUZZ * FUZZ); - tb->need_merge = 0; - } - - for (n = tb->rects.head; n; n = n->next) { - rect_t cur; + if (tb->need_merge) + { + list_t to_merge; + to_merge = tb->rects; + tb->rects = list_zeroed; + rect_list_merge_rects(&tb->rects, &to_merge, FUZZ * FUZZ); + tb->need_merge = 0; + } + + n = tb->rects.head; + if (n) + { + bx1 = ((rect_node_t *)n)->rect.left; + bx2 = bx1 + ((rect_node_t *)n)->rect.width; + by1 = ((rect_node_t *)n)->rect.top; + by2 = by1 + ((rect_node_t *)n)->rect.height; + n = n->next; + for (; n; n = n->next) + { + + int x1, x2, y1, y2; + + x1 = ((rect_node_t *)n)->rect.left; + if (x1 < bx1) bx1 = x1; + x2 = x1 + ((rect_node_t *)n)->rect.width; + if (x2 > bx2) bx2 = x2; + + y1 = ((rect_node_t *)n)->rect.top; + if (y1 < by1) by1 = y1; + y2 = y1 + ((rect_node_t *)n)->rect.height; + if (y2 > by2) by2 = y2; + num++; + } + } +#define MAXREG 24 + /* magic number - but if we have > MAXREG regions to update, take bounding box */ + if (num > MAXREG) + { + Tilebuf_Rect *r; + + r = malloc(sizeof(Tilebuf_Rect)); + r->x = bx1; + r->y = by1; + r->w = bx2 - bx1; + r->h = by2 - by1; + + rects = (Tilebuf_Rect *)eina_inlist_append(EINA_INLIST_GET(rects), EINA_INLIST_GET(r)); + return rects; + } - cur = ((rect_node_t *)n)->rect; + for (n = tb->rects.head; n; n = n->next) + { + rect_t cur; + + cur = ((rect_node_t *)n)->rect; /* disable fuzz - created bugs. cur.left <<= 1; cur.top <<= 1; cur.width <<= 1; cur.height <<= 1; */ - RECTS_CLIP_TO_RECT(cur.left, cur.top, cur.width, cur.height, - 0, 0, tb->outbuf_w, tb->outbuf_h); - if ((cur.width > 0) && (cur.height > 0)) - { - Tilebuf_Rect *r; - - r = malloc(sizeof(Tilebuf_Rect)); - r->x = cur.left; - r->y = cur.top; - r->w = cur.width; - r->h = cur.height; - - rects = (Tilebuf_Rect *)eina_inlist_append(EINA_INLIST_GET(rects), EINA_INLIST_GET(r)); - } - } + RECTS_CLIP_TO_RECT(cur.left, cur.top, cur.width, cur.height, + 0, 0, tb->outbuf_w, tb->outbuf_h); + if ((cur.width > 0) && (cur.height > 0)) + { + Tilebuf_Rect *r; + + r = malloc(sizeof(Tilebuf_Rect)); + r->x = cur.left; + r->y = cur.top; + r->w = cur.width; + r->h = cur.height; + + rects = (Tilebuf_Rect *)eina_inlist_append(EINA_INLIST_GET(rects), EINA_INLIST_GET(r)); + } + } return rects; #else diff --git a/libraries/evas/src/lib/engines/common_16/Makefile.in b/libraries/evas/src/lib/engines/common_16/Makefile.in index 313cbda..196395d 100644 --- a/libraries/evas/src/lib/engines/common_16/Makefile.in +++ b/libraries/evas/src/lib/engines/common_16/Makefile.in @@ -151,6 +151,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -201,6 +203,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -219,8 +223,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -294,8 +296,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/engines/common_8/Makefile.in b/libraries/evas/src/lib/engines/common_8/Makefile.in index 7fa4fbb..11b2454 100644 --- a/libraries/evas/src/lib/engines/common_8/Makefile.in +++ b/libraries/evas/src/lib/engines/common_8/Makefile.in @@ -150,6 +150,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -200,6 +202,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -218,8 +222,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -293,8 +295,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/file/Makefile.am b/libraries/evas/src/lib/file/Makefile.am index 7875fbe..84b12d9 100644 --- a/libraries/evas/src/lib/file/Makefile.am +++ b/libraries/evas/src/lib/file/Makefile.am @@ -11,10 +11,7 @@ AM_CPPFLAGS = \ @FREETYPE_CFLAGS@ \ @EINA_CFLAGS@ \ @EVIL_CFLAGS@ \ -@WIN32_CPPFLAGS@ \ @PIXMAN_CFLAGS@ - -AM_CFLAGS = @WIN32_CFLAGS@ noinst_LTLIBRARIES = libevas_file.la libevas_file_la_SOURCES = \ diff --git a/libraries/evas/src/lib/file/Makefile.in b/libraries/evas/src/lib/file/Makefile.in index 2ac89b1..52d3608 100644 --- a/libraries/evas/src/lib/file/Makefile.in +++ b/libraries/evas/src/lib/file/Makefile.in @@ -146,6 +146,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -196,6 +198,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -214,8 +218,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -289,8 +291,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ @@ -384,10 +384,8 @@ AM_CPPFLAGS = \ @FREETYPE_CFLAGS@ \ @EINA_CFLAGS@ \ @EVIL_CFLAGS@ \ -@WIN32_CPPFLAGS@ \ @PIXMAN_CFLAGS@ -AM_CFLAGS = @WIN32_CFLAGS@ noinst_LTLIBRARIES = libevas_file.la libevas_file_la_SOURCES = \ evas_path.c \ diff --git a/libraries/evas/src/lib/file/evas_module.c b/libraries/evas/src/lib/file/evas_module.c index 21d5cd0..dc0d26b 100644 --- a/libraries/evas/src/lib/file/evas_module.c +++ b/libraries/evas/src/lib/file/evas_module.c @@ -98,7 +98,6 @@ EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_8_x11); EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_ddraw); EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_gdi); EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_generic); -EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_sdl); EVAS_EINA_STATIC_MODULE_DEFINE(engine, software_x11); EVAS_EINA_STATIC_MODULE_DEFINE(image_loader, bmp); EVAS_EINA_STATIC_MODULE_DEFINE(image_loader, edb); @@ -176,9 +175,6 @@ static const struct { #ifdef EVAS_STATIC_BUILD_SOFTWARE_GENERIC EVAS_EINA_STATIC_MODULE_USE(engine, software_generic), #endif -#ifdef EVAS_STATIC_BUILD_SOFTWARE_SDL - EVAS_EINA_STATIC_MODULE_USE(engine, software_sdl), -#endif #ifdef EVAS_STATIC_BUILD_SOFTWARE_X11 EVAS_EINA_STATIC_MODULE_USE(engine, software_x11), #endif diff --git a/libraries/evas/src/lib/file/evas_path.c b/libraries/evas/src/lib/file/evas_path.c index c663c16..2ff646d 100644 --- a/libraries/evas/src/lib/file/evas_path.c +++ b/libraries/evas/src/lib/file/evas_path.c @@ -38,9 +38,7 @@ evas_file_path_is_full_path(const char *path) #if defined _WIN32_WCE if (path[0] == '\\') return 1; #elif defined _WIN32 - if ((path[0] == '\0') || (path[1] == '\0')) - return 0; - if (path[1] == ':') return 1; + if (evil_path_is_absolute(path)) return 1; #else if (path[0] == '/') return 1; #endif diff --git a/libraries/evas/src/lib/include/Makefile.in b/libraries/evas/src/lib/include/Makefile.in index 21f0099..8060178 100644 --- a/libraries/evas/src/lib/include/Makefile.in +++ b/libraries/evas/src/lib/include/Makefile.in @@ -116,6 +116,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ EVIL_CFLAGS = @EVIL_CFLAGS@ EVIL_LIBS = @EVIL_LIBS@ EXEEXT = @EXEEXT@ +EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ +EXOTIC_LIBS = @EXOTIC_LIBS@ FGREP = @FGREP@ FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ @@ -166,6 +168,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ PIXMAN_LIBS = @PIXMAN_LIBS@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PNG_CFLAGS = @PNG_CFLAGS@ PNG_LIBS = @PNG_LIBS@ RANLIB = @RANLIB@ @@ -184,8 +188,6 @@ VERSION = @VERSION@ VMAJ = @VMAJ@ WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -WIN32_CFLAGS = @WIN32_CFLAGS@ -WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ XCB_CFLAGS = @XCB_CFLAGS@ XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ XCB_GL_LIBS = @XCB_GL_LIBS@ @@ -259,8 +261,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ -evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ diff --git a/libraries/evas/src/lib/include/evas_blend_ops.h b/libraries/evas/src/lib/include/evas_blend_ops.h index 1ada384..6bd1f16 100644 --- a/libraries/evas/src/lib/include/evas_blend_ops.h +++ b/libraries/evas/src/lib/include/evas_blend_ops.h @@ -200,7 +200,7 @@ static __m128i RGB_MASK_SSE3; static __m128i ALPHA_SSE3; -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i mul_256_sse3(__m128i a, __m128i c) { /* prepare alpha for word multiplication */ @@ -228,7 +228,7 @@ mul_256_sse3(__m128i a, __m128i c) { return _mm_add_epi32(c0, c1); } -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i sub4_alpha_sse3(__m128i c) { __m128i c0 = c; @@ -237,7 +237,7 @@ sub4_alpha_sse3(__m128i c) { return _mm_sub_epi32(ALPHA_SSE3, c0); } -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i interp4_256_sse3(__m128i a, __m128i c0, __m128i c1) { const __m128i zero = _mm_setzero_si128(); @@ -289,7 +289,7 @@ interp4_256_sse3(__m128i a, __m128i c0, __m128i c1) return (__m128i) _mm_shuffle_ps( (__m128)cl_sub, (__m128)ch_sub, 0x44); } -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i mul_sym_sse3(__m128i a, __m128i c) { /* Prepare alpha for word mult */ @@ -318,7 +318,7 @@ mul_sym_sse3(__m128i a, __m128i c) { return _mm_add_epi32(c0, c1); } -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i mul4_sym_sse3(__m128i x, __m128i y) { const __m128i zero = _mm_setzero_si128(); @@ -341,7 +341,7 @@ mul4_sym_sse3(__m128i x, __m128i y) { return _mm_packus_epi16(r_l, r_h); } -EFL_ALWAYS_INLINE __m128i +static EFL_ALWAYS_INLINE __m128i mul3_sym_sse3(__m128i x, __m128i y) { __m128i res = mul4_sym_sse3(x, y); diff --git a/libraries/evas/src/lib/include/evas_common.h b/libraries/evas/src/lib/include/evas_common.h index a9063e6..e853064 100644 --- a/libraries/evas/src/lib/include/evas_common.h +++ b/libraries/evas/src/lib/include/evas_common.h @@ -5,6 +5,45 @@ #include "config.h" /* so that EAPI in Evas.h is correctly defined */ //#endif +#ifdef STDC_HEADERS +# include +# include +#else +# ifdef HAVE_STDLIB_H +# include +# endif +#endif +#ifdef HAVE_ALLOCA_H +# include +#elif !defined alloca +# ifdef __GNUC__ +# define alloca __builtin_alloca +# elif defined _AIX +# define alloca __alloca +# elif defined _MSC_VER +# include +# define alloca _alloca +# elif !defined HAVE_ALLOCA +# ifdef __cplusplus +extern "C" +# endif +void *alloca (size_t); +# endif +#endif + +#include +#include +#include +#include +#include +#include +#include + +#ifndef _MSC_VER +# include +#include +#endif + #ifdef HAVE_EVIL # include #endif @@ -13,10 +52,6 @@ # include #endif -#include -#include "Evas.h" -//#include "Evas_GL.h" - #ifdef HAVE_PIXMAN #include #endif @@ -25,6 +60,14 @@ #include #include +#ifdef HAVE_EXOTIC +# include +#endif + +#include +#include "Evas.h" +//#include "Evas_GL.h" + #ifndef HAVE_LROUND /* right now i dont care about rendering bugs on platforms without lround (e.g. windows/vc++... yay!) @@ -171,35 +214,6 @@ extern EAPI int _evas_log_dom_global; #endif -#ifdef HAVE_ALLOCA_H -# include -#elif defined __GNUC__ -# define alloca __builtin_alloca -#elif defined _AIX -# define alloca __alloca -#elif defined _MSC_VER -# include -# define alloca _alloca -#else -# include -# ifdef __cplusplus -extern "C" -# endif -void *alloca (size_t); -#endif - -#include -#include -#include -#include -#include -#include -#include - -#ifndef _MSC_VER -# include -#endif - #include #include FT_FREETYPE_H #include FT_GLYPH_H @@ -1005,12 +1019,12 @@ struct list struct rect { - short left; - short top; - short right; - short bottom; - short width; - short height; + int left; + int top; + int right; + int bottom; + int width; + int height; int area; }; diff --git a/libraries/evas/src/lib/include/evas_private.h b/libraries/evas/src/lib/include/evas_private.h index 84c1d36..bf0cfc5 100644 --- a/libraries/evas/src/lib/include/evas_private.h +++ b/libraries/evas/src/lib/include/evas_private.h @@ -615,6 +615,8 @@ struct _Evas_Object Eina_Bool changed_move : 1; Eina_Bool changed_move_only : 1; Eina_Bool changed_nomove : 1; + Eina_Bool changed_map : 1; + Eina_Bool changed_pchange : 1; Eina_Bool del_ref : 1; Eina_Bool is_frame : 1; @@ -850,6 +852,7 @@ struct _Evas_Func void *(*gl_proc_address_get) (void *data, const char *name); int (*gl_native_surface_get) (void *data, void *surface, void *native_surface); void *(*gl_api_get) (void *data); + void (*gl_img_obj_set) (void *data, void *image, int has_alpha); int (*image_load_error_get) (void *data, void *image); int (*font_run_end_get) (void *data, Evas_Font_Set *font, Evas_Font_Instance **script_fi, Evas_Font_Instance **cur_fi, Evas_Script_Type script, const Eina_Unicode *text, int run_len); -- cgit v1.1