summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--legacy/evas/src/bin/evas_cserve_main.c4
-rw-r--r--legacy/evas/src/lib/canvas/evas_events.c4
-rw-r--r--legacy/evas/src/lib/canvas/evas_font_dir.c2
-rw-r--r--legacy/evas/src/lib/canvas/evas_main.c4
-rw-r--r--legacy/evas/src/lib/canvas/evas_object_box.c18
-rw-r--r--legacy/evas/src/lib/canvas/evas_object_image.c2
-rw-r--r--legacy/evas/src/lib/canvas/evas_object_smart.c8
-rw-r--r--legacy/evas/src/lib/canvas/evas_object_table.c34
-rw-r--r--legacy/evas/src/lib/canvas/evas_render.c2
-rw-r--r--legacy/evas/src/lib/canvas/evas_smart.c2
-rw-r--r--legacy/evas/src/lib/canvas/evas_stack.c4
-rw-r--r--legacy/evas/src/lib/cserve/evas_cs_client.c2
-rw-r--r--legacy/evas/src/lib/cserve/evas_cs_server.c2
-rw-r--r--legacy/evas/src/lib/engines/common/evas_convert_main.c2
-rw-r--r--legacy/evas/src/lib/engines/common/evas_convert_rgb_16.c2
-rw-r--r--legacy/evas/src/lib/engines/common/evas_cpu.c2
-rw-r--r--legacy/evas/src/lib/engines/common/evas_font_query.c2
-rw-r--r--legacy/evas/src/lib/engines/common/evas_image_main.c4
-rw-r--r--legacy/evas/src/lib/engines/common/evas_image_scalecache.c26
-rw-r--r--legacy/evas/src/lib/engines/common/evas_pipe.c8
-rw-r--r--legacy/evas/src/lib/engines/common/evas_tiler.c8
-rw-r--r--legacy/evas/src/lib/engines/common_16/evas_soft16_image_scaled_sampled.c6
-rw-r--r--legacy/evas/src/lib/engines/common_16/evas_soft16_image_unscaled.c6
-rw-r--r--legacy/evas/src/lib/engines/common_16/evas_soft16_main.c2
-rw-r--r--legacy/evas/src/lib/engines/common_16/evas_soft16_rectangle.c2
-rw-r--r--legacy/evas/src/lib/include/evas_common.h47
-rw-r--r--legacy/evas/src/lib/main.c10
-rw-r--r--legacy/evas/src/modules/engines/buffer/evas_engine.c23
-rw-r--r--legacy/evas/src/modules/engines/buffer/evas_engine.h28
-rw-r--r--legacy/evas/src/modules/engines/cairo_x11/evas_engine.c20
-rw-r--r--legacy/evas/src/modules/engines/cairo_x11/evas_engine.h30
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_device.cpp34
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_image_cache.cpp20
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_main.cpp44
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_font.cpp4
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_image.cpp4
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_line.cpp2
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_rect.cpp2
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_shader_pack.cpp12
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_direct3d_vertex_buffer_cache.cpp4
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_engine.c14
-rw-r--r--legacy/evas/src/modules/engines/direct3d/evas_engine.h32
-rw-r--r--legacy/evas/src/modules/engines/directfb/evas_engine.c76
-rw-r--r--legacy/evas/src/modules/engines/directfb/evas_engine.h27
-rw-r--r--legacy/evas/src/modules/engines/fb/evas_engine.c11
-rw-r--r--legacy/evas/src/modules/engines/fb/evas_engine.h26
-rw-r--r--legacy/evas/src/modules/engines/fb/evas_fb_main.c10
-rw-r--r--legacy/evas/src/modules/engines/fb/evas_outbuf.c2
-rw-r--r--legacy/evas/src/modules/engines/gl_glew/evas_engine.c14
-rw-r--r--legacy/evas/src/modules/engines/gl_glew/evas_engine.h24
-rw-r--r--legacy/evas/src/modules/engines/gl_glew/evas_glew_main.c2
-rw-r--r--legacy/evas/src/modules/engines/gl_x11/evas_engine.c15
-rw-r--r--legacy/evas/src/modules/engines/gl_x11/evas_engine.h26
-rw-r--r--legacy/evas/src/modules/engines/quartz/evas_engine.c35
-rw-r--r--legacy/evas/src/modules/engines/quartz/evas_engine.h27
-rw-r--r--legacy/evas/src/modules/engines/software_16/evas_engine.c40
-rw-r--r--legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.c10
-rw-r--r--legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.h27
-rw-r--r--legacy/evas/src/modules/engines/software_16_sdl/evas_engine.c29
-rw-r--r--legacy/evas/src/modules/engines/software_16_sdl/evas_engine.h25
-rw-r--r--legacy/evas/src/modules/engines/software_16_wince/evas_engine.c13
-rw-r--r--legacy/evas/src/modules/engines/software_16_wince/evas_engine.h28
-rw-r--r--legacy/evas/src/modules/engines/software_16_wince/evas_wince_fb_buffer.c20
-rw-r--r--legacy/evas/src/modules/engines/software_16_wince/evas_wince_gapi_buffer.c20
-rw-r--r--legacy/evas/src/modules/engines/software_16_wince/evas_wince_gdi_buffer.c4
-rw-r--r--legacy/evas/src/modules/engines/software_16_x11/evas_engine.c12
-rw-r--r--legacy/evas/src/modules/engines/software_16_x11/evas_engine.h28
-rw-r--r--legacy/evas/src/modules/engines/software_ddraw/evas_engine.c22
-rw-r--r--legacy/evas/src/modules/engines/software_gdi/evas_engine.c11
-rw-r--r--legacy/evas/src/modules/engines/software_gdi/evas_engine.h26
-rw-r--r--legacy/evas/src/modules/engines/software_gdi/evas_gdi_main.c10
-rw-r--r--legacy/evas/src/modules/engines/software_gdi/evas_outbuf.c2
-rw-r--r--legacy/evas/src/modules/engines/software_generic/evas_engine.c10
-rw-r--r--legacy/evas/src/modules/engines/software_qtopia/evas_engine.c10
-rw-r--r--legacy/evas/src/modules/engines/software_qtopia/evas_engine.h26
-rw-r--r--legacy/evas/src/modules/engines/software_sdl/evas_engine.c48
-rw-r--r--legacy/evas/src/modules/engines/software_sdl/evas_engine.h26
-rw-r--r--legacy/evas/src/modules/engines/software_x11/evas_engine.c11
-rw-r--r--legacy/evas/src/modules/engines/software_x11/evas_engine.h25
-rw-r--r--legacy/evas/src/modules/engines/software_x11/evas_xcb_outbuf.c2
-rw-r--r--legacy/evas/src/modules/engines/xrender_x11/evas_engine.c12
-rw-r--r--legacy/evas/src/modules/engines/xrender_x11/evas_engine.h26
82 files changed, 939 insertions, 367 deletions
diff --git a/legacy/evas/src/bin/evas_cserve_main.c b/legacy/evas/src/bin/evas_cserve_main.c
index 5f6659bef0..15d2739452 100644
--- a/legacy/evas/src/bin/evas_cserve_main.c
+++ b/legacy/evas/src/bin/evas_cserve_main.c
@@ -16,7 +16,7 @@
16#include "Evas.h" 16#include "Evas.h"
17#include "evas_cs.h" 17#include "evas_cs.h"
18 18
19#define D(...) EINA_LOG_DBG(__VA_ARGS__) 19#define D(...) EINA_LOG_DOM_DBG(_evas_cserve_bin_log_dom, __VA_ARGS__)
20#ifdef ERR 20#ifdef ERR
21#undef ERR 21#undef ERR
22#endif 22#endif
@@ -33,7 +33,7 @@
33#ifdef CSERVE_BIN_DEFAULT_COLOR 33#ifdef CSERVE_BIN_DEFAULT_COLOR
34#undef CSERVE_BIN_DEFAULT_COLOR 34#undef CSERVE_BIN_DEFAULT_COLOR
35#endif 35#endif
36#define CSERVE_BIN_DEFAULT_COLOR "\033[36m" 36#define CSERVE_BIN_DEFAULT_COLOR EINA_COLOR_BLUE
37// fixme:'s 37// fixme:'s
38// 38//
39// preload - make it work (both) 39// preload - make it work (both)
diff --git a/legacy/evas/src/lib/canvas/evas_events.c b/legacy/evas/src/lib/canvas/evas_events.c
index 64d2a1d10b..b7e985c1bd 100644
--- a/legacy/evas/src/lib/canvas/evas_events.c
+++ b/legacy/evas/src/lib/canvas/evas_events.c
@@ -398,13 +398,13 @@ evas_event_feed_mouse_up(Evas *e, int b, Evas_Button_Flags flags, unsigned int t
398 398
399 if (e->pointer.mouse_grabbed < 0) 399 if (e->pointer.mouse_grabbed < 0)
400 { 400 {
401 ERROR("BUG? e->pointer.mouse_grabbed (=%d) < 0!", 401 ERR("BUG? e->pointer.mouse_grabbed (=%d) < 0!",
402 e->pointer.mouse_grabbed); 402 e->pointer.mouse_grabbed);
403 } 403 }
404 404
405 if ((e->pointer.button == 0) && (e->pointer.mouse_grabbed != 0)) 405 if ((e->pointer.button == 0) && (e->pointer.mouse_grabbed != 0))
406 { 406 {
407 INFO("restore to 0 grabs (from %i)", e->pointer.mouse_grabbed); 407 INF("restore to 0 grabs (from %i)", e->pointer.mouse_grabbed);
408 e->pointer.mouse_grabbed = 0; 408 e->pointer.mouse_grabbed = 0;
409 } 409 }
410 _evas_unwalk(e); 410 _evas_unwalk(e);
diff --git a/legacy/evas/src/lib/canvas/evas_font_dir.c b/legacy/evas/src/lib/canvas/evas_font_dir.c
index 2d2fe47bf6..43d6d59ca7 100644
--- a/legacy/evas/src/lib/canvas/evas_font_dir.c
+++ b/legacy/evas/src/lib/canvas/evas_font_dir.c
@@ -394,7 +394,7 @@ evas_font_load(Evas *evas, const char *name, const char *source, int size)
394 set = FcFontSort(NULL, p_nm, FcTrue, NULL, &res); 394 set = FcFontSort(NULL, p_nm, FcTrue, NULL, &res);
395 if (!set) 395 if (!set)
396 { 396 {
397 ERROR("No fontconfig font matches '%s'. It was the last resource, no font found!", name); 397 ERR("No fontconfig font matches '%s'. It was the last resource, no font found!", name);
398 goto fc_end; 398 goto fc_end;
399 } 399 }
400 400
diff --git a/legacy/evas/src/lib/canvas/evas_main.c b/legacy/evas/src/lib/canvas/evas_main.c
index 07906d7b65..0b90ce5214 100644
--- a/legacy/evas/src/lib/canvas/evas_main.c
+++ b/legacy/evas/src/lib/canvas/evas_main.c
@@ -27,7 +27,7 @@ evas_init(void)
27 _evas_log_dom_global = eina_log_domain_register("evas_main",EVAS_DEFAULT_LOG_COLOR); 27 _evas_log_dom_global = eina_log_domain_register("evas_main",EVAS_DEFAULT_LOG_COLOR);
28 if (_evas_log_dom_global < 0) 28 if (_evas_log_dom_global < 0)
29 { 29 {
30 fprintf(stderr,"Error: Evas could not create a default log domain\n"); 30 EINA_LOG_ERR("Evas could not create a default log domain\n");
31 goto shutdown_eina; 31 goto shutdown_eina;
32 } 32 }
33 33
@@ -489,7 +489,7 @@ evas_output_viewport_set(Evas *e, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas
489 if (h <= 0) return; 489 if (h <= 0) return;
490 if ((x != 0) || (y != 0)) 490 if ((x != 0) || (y != 0))
491 { 491 {
492 ERROR("EVAS: compat error. viewport x,y != 0,0 not supported"); 492 ERR("Compat error. viewport x,y != 0,0 not supported");
493 x = 0; 493 x = 0;
494 y = 0; 494 y = 0;
495 } 495 }
diff --git a/legacy/evas/src/lib/canvas/evas_object_box.c b/legacy/evas/src/lib/canvas/evas_object_box.c
index 8bf66a9e63..53a5971f2c 100644
--- a/legacy/evas/src/lib/canvas/evas_object_box.c
+++ b/legacy/evas/src/lib/canvas/evas_object_box.c
@@ -32,7 +32,7 @@ struct _Evas_Object_Box_Accessor
32 EVAS_OBJECT_BOX_DATA_GET(o, ptr); \ 32 EVAS_OBJECT_BOX_DATA_GET(o, ptr); \
33 if (!ptr) \ 33 if (!ptr) \
34 { \ 34 { \
35 CRITICAL("no widget data for object %p (%s)", \ 35 CRIT("no widget data for object %p (%s)", \
36 o, evas_object_type_get(o)); \ 36 o, evas_object_type_get(o)); \
37 fflush(stderr); \ 37 fflush(stderr); \
38 abort(); \ 38 abort(); \
@@ -43,7 +43,7 @@ struct _Evas_Object_Box_Accessor
43 EVAS_OBJECT_BOX_DATA_GET(o, ptr); \ 43 EVAS_OBJECT_BOX_DATA_GET(o, ptr); \
44 if (!ptr) \ 44 if (!ptr) \
45 { \ 45 { \
46 CRITICAL("no widget data for object %p (%s)", \ 46 CRIT("no widget data for object %p (%s)", \
47 o, evas_object_type_get(o)); \ 47 o, evas_object_type_get(o)); \
48 fflush(stderr); \ 48 fflush(stderr); \
49 abort(); \ 49 abort(); \
@@ -374,15 +374,15 @@ _evas_object_box_remove_at_default(Evas_Object *o, Evas_Object_Box_Data *priv, u
374 374
375 if ((!api) || (!api->option_free)) 375 if ((!api) || (!api->option_free))
376 { 376 {
377 fputs("WARNING: api->option_free not set (may cause memory leaks," 377 WRN("api->option_free not set (may cause memory leaks,"
378 " segfaults)\n", stderr); 378 " segfaults)\n");
379 return NULL; 379 return NULL;
380 } 380 }
381 381
382 node = eina_list_nth_list(priv->children, pos); 382 node = eina_list_nth_list(priv->children, pos);
383 if (!node) 383 if (!node)
384 { 384 {
385 ERROR("ERROR: no item to be removed at position %d\n", pos); 385 ERR("No item to be removed at position %d\n", pos);
386 return NULL; 386 return NULL;
387 } 387 }
388 388
@@ -408,7 +408,7 @@ _evas_object_box_smart_add(Evas_Object *o)
408 priv = (Evas_Object_Box_Data *)calloc(1, sizeof(*priv)); 408 priv = (Evas_Object_Box_Data *)calloc(1, sizeof(*priv));
409 if (!priv) 409 if (!priv)
410 { 410 {
411 fputs("ERROR: could not allocate object private data.\n", stderr); 411 ERR("Could not allocate object private data.\n");
412 return; 412 return;
413 } 413 }
414 414
@@ -441,8 +441,8 @@ _evas_object_box_smart_del(Evas_Object *o)
441 api = priv->api; 441 api = priv->api;
442 if ((!api) || (!api->option_free)) 442 if ((!api) || (!api->option_free))
443 { 443 {
444 fputs("WARNING: api->option_free not set (may cause memory leaks," 444 WRN("api->option_free not set (may cause memory leaks,"
445 " segfaults)\n", stderr); 445 " segfaults)\n");
446 return; 446 return;
447 } 447 }
448 448
@@ -478,7 +478,7 @@ _evas_object_box_smart_calculate(Evas_Object *o)
478 if (priv->layout.cb) 478 if (priv->layout.cb)
479 priv->layout.cb(o, priv, priv->layout.data); 479 priv->layout.cb(o, priv, priv->layout.data);
480 else 480 else
481 ERROR("No layout function set for %p box.", o); 481 ERR("No layout function set for %p box.", o);
482} 482}
483 483
484static Evas_Smart * 484static Evas_Smart *
diff --git a/legacy/evas/src/lib/canvas/evas_object_image.c b/legacy/evas/src/lib/canvas/evas_object_image.c
index b55f2b632d..e94fb6cfe5 100644
--- a/legacy/evas/src/lib/canvas/evas_object_image.c
+++ b/legacy/evas/src/lib/canvas/evas_object_image.c
@@ -2533,7 +2533,7 @@ evas_object_image_render_pre(Evas_Object *obj)
2533 2533
2534 if ((o->cur.fill.w < 1) || (o->cur.fill.h < 1)) 2534 if ((o->cur.fill.w < 1) || (o->cur.fill.h < 1))
2535 { 2535 {
2536 ERROR("evas image: %p has invalid fill size: %dx%d. Ignored", 2536 ERR("%p has invalid fill size: %dx%d. Ignored",
2537 obj, o->cur.fill.w, o->cur.fill.h); 2537 obj, o->cur.fill.w, o->cur.fill.h);
2538 return; 2538 return;
2539 } 2539 }
diff --git a/legacy/evas/src/lib/canvas/evas_object_smart.c b/legacy/evas/src/lib/canvas/evas_object_smart.c
index 07fdd469be..cb9b622976 100644
--- a/legacy/evas/src/lib/canvas/evas_object_smart.c
+++ b/legacy/evas/src/lib/canvas/evas_object_smart.c
@@ -174,26 +174,26 @@ evas_object_smart_member_add(Evas_Object *obj, Evas_Object *smart_obj)
174 174
175 if (obj->delete_me) 175 if (obj->delete_me)
176 { 176 {
177 ERROR("Adding deleted object %p to smart obj %p", obj, smart_obj); 177 CRIT("Adding deleted object %p to smart obj %p", obj, smart_obj);
178 abort(); 178 abort();
179 return; 179 return;
180 } 180 }
181 if (smart_obj->delete_me) 181 if (smart_obj->delete_me)
182 { 182 {
183 ERROR("Adding object %p to deleted smart obj %p", obj, smart_obj); 183 CRIT("Adding object %p to deleted smart obj %p", obj, smart_obj);
184 abort(); 184 abort();
185 return; 185 return;
186 } 186 }
187 if (!smart_obj->layer) 187 if (!smart_obj->layer)
188 { 188 {
189 ERROR("No evas surface associated with smart object (%p)", smart_obj); 189 CRIT("No evas surface associated with smart object (%p)", smart_obj);
190 abort(); 190 abort();
191 return; 191 return;
192 } 192 }
193 if (obj->layer && smart_obj->layer 193 if (obj->layer && smart_obj->layer
194 && obj->layer->evas != smart_obj->layer->evas) 194 && obj->layer->evas != smart_obj->layer->evas)
195 { 195 {
196 ERROR("EVAS ERROR: Adding object %p from Evas (%p) from another Evas (%p)", obj, obj->layer->evas, smart_obj->layer->evas); 196 CRIT("Adding object %p from Evas (%p) from another Evas (%p)", obj, obj->layer->evas, smart_obj->layer->evas);
197 abort(); 197 abort();
198 return; 198 return;
199 } 199 }
diff --git a/legacy/evas/src/lib/canvas/evas_object_table.c b/legacy/evas/src/lib/canvas/evas_object_table.c
index 483b6ba0ae..44a8ee755d 100644
--- a/legacy/evas/src/lib/canvas/evas_object_table.c
+++ b/legacy/evas/src/lib/canvas/evas_object_table.c
@@ -93,8 +93,8 @@ struct _Evas_Object_Table_Accessor
93 EVAS_OBJECT_TABLE_DATA_GET(o, ptr); \ 93 EVAS_OBJECT_TABLE_DATA_GET(o, ptr); \
94 if (!ptr) \ 94 if (!ptr) \
95 { \ 95 { \
96 CRITICAL("CRITICAL: no widget data for object %p (%s)", \ 96 CRIT("no widget data for object %p (%s)", \
97 o, evas_object_type_get(o)); \ 97 o, evas_object_type_get(o)); \
98 abort(); \ 98 abort(); \
99 return; \ 99 return; \
100} 100}
@@ -103,7 +103,7 @@ struct _Evas_Object_Table_Accessor
103 EVAS_OBJECT_TABLE_DATA_GET(o, ptr); \ 103 EVAS_OBJECT_TABLE_DATA_GET(o, ptr); \
104 if (!ptr) \ 104 if (!ptr) \
105 { \ 105 { \
106 CRITICAL("No widget data for object %p (%s)", \ 106 CRIT("No widget data for object %p (%s)", \
107 o, evas_object_type_get(o)); \ 107 o, evas_object_type_get(o)); \
108 abort(); \ 108 abort(); \
109 return val; \ 109 return val; \
@@ -170,7 +170,7 @@ _evas_object_table_cache_alloc(int cols, int rows)
170 cache = malloc(size); 170 cache = malloc(size);
171 if (!cache) 171 if (!cache)
172 { 172 {
173 ERROR("Could not allocate table cache %dx%d (%d bytes): %s", 173 ERR("Could not allocate table cache %dx%d (%d bytes): %s",
174 cols, rows, size, strerror(errno)); 174 cols, rows, size, strerror(errno));
175 return NULL; 175 return NULL;
176 } 176 }
@@ -322,7 +322,7 @@ _evas_object_table_calculate_cell(const Evas_Object_Table_Option *opt, Evas_Coor
322/* } */ 322/* } */
323/* else if (min < 1) */ 323/* else if (min < 1) */
324/* { */ 324/* { */
325/* WARN("Child %p [%s, %s] has no minimum width " */ 325/* WRN("Child %p [%s, %s] has no minimum width " */
326/* "and no %s expand (weight is not > 0.0). " */ 326/* "and no %s expand (weight is not > 0.0). " */
327/* "Assuming weight > 0.0\n", */ 327/* "Assuming weight > 0.0\n", */
328/* child, evas_object_type_get(child), evas_object_name_get(child), */ 328/* child, evas_object_type_get(child), evas_object_name_get(child), */
@@ -429,13 +429,13 @@ _evas_object_table_calculate_hints_homogeneous(Evas_Object *o, Evas_Object_Table
429 { 429 {
430 if (o_minw < 1) 430 if (o_minw < 1)
431 { 431 {
432 ERROR("homogeneous table based on item size but no " 432 ERR("homogeneous table based on item size but no "
433 "horizontal mininum size specified! Using expand."); 433 "horizontal mininum size specified! Using expand.");
434 expand_h = 1; 434 expand_h = 1;
435 } 435 }
436 if (o_minh < 1) 436 if (o_minh < 1)
437 { 437 {
438 ERROR("homogeneous table based on item size but no " 438 ERR("homogeneous table based on item size but no "
439 "vertical mininum size specified! Using expand."); 439 "vertical mininum size specified! Using expand.");
440 expand_v = 1; 440 expand_v = 1;
441 } 441 }
@@ -746,7 +746,7 @@ _evas_object_table_calculate_layout_regular(Evas_Object *o, Evas_Object_Table_Da
746 cols = malloc(size); 746 cols = malloc(size);
747 if (!cols) 747 if (!cols)
748 { 748 {
749 ERROR("Could not allocate temp columns (%d bytes): %s", 749 ERR("Could not allocate temp columns (%d bytes): %s",
750 size, strerror(errno)); 750 size, strerror(errno));
751 return; 751 return;
752 } 752 }
@@ -769,7 +769,7 @@ _evas_object_table_calculate_layout_regular(Evas_Object *o, Evas_Object_Table_Da
769 rows = malloc(size); 769 rows = malloc(size);
770 if (!rows) 770 if (!rows)
771 { 771 {
772 ERROR("could not allocate temp rows (%d bytes): %s", 772 ERR("could not allocate temp rows (%d bytes): %s",
773 size, strerror(errno)); 773 size, strerror(errno));
774 goto end; 774 goto end;
775 } 775 }
@@ -826,7 +826,7 @@ _evas_object_table_smart_add(Evas_Object *o)
826 priv = calloc(1, sizeof(*priv)); 826 priv = calloc(1, sizeof(*priv));
827 if (!priv) 827 if (!priv)
828 { 828 {
829 ERROR("could not allocate object private data."); 829 ERR("could not allocate object private data.");
830 return; 830 return;
831 } 831 }
832 evas_object_smart_data_set(o, priv); 832 evas_object_smart_data_set(o, priv);
@@ -884,7 +884,7 @@ _evas_object_table_smart_calculate(Evas_Object *o)
884 884
885 if ((priv->size.cols < 1) || (priv->size.rows < 1)) 885 if ((priv->size.cols < 1) || (priv->size.rows < 1))
886 { 886 {
887 DEBUG("Nothing to do: cols=%d, rows=%d", 887 DBG("Nothing to do: cols=%d, rows=%d",
888 priv->size.cols, priv->size.rows); 888 priv->size.cols, priv->size.rows);
889 return; 889 return;
890 } 890 }
@@ -1118,26 +1118,26 @@ evas_object_table_pack(Evas_Object *o, Evas_Object *child, unsigned short col, u
1118 1118
1119 if (rowspan < 1) 1119 if (rowspan < 1)
1120 { 1120 {
1121 ERROR("rowspan < 1"); 1121 ERR("rowspan < 1");
1122 return EINA_FALSE; 1122 return EINA_FALSE;
1123 } 1123 }
1124 if (colspan < 1) 1124 if (colspan < 1)
1125 { 1125 {
1126 ERROR("colspan < 1"); 1126 ERR("colspan < 1");
1127 return EINA_FALSE; 1127 return EINA_FALSE;
1128 } 1128 }
1129 1129
1130 opt = _evas_object_table_option_get(child); 1130 opt = _evas_object_table_option_get(child);
1131 if (opt) 1131 if (opt)
1132 { 1132 {
1133 ERROR("cannot add object that is already part of a table!"); 1133 ERR("cannot add object that is already part of a table!");
1134 return EINA_FALSE; 1134 return EINA_FALSE;
1135 } 1135 }
1136 1136
1137 opt = malloc(sizeof(*opt)); 1137 opt = malloc(sizeof(*opt));
1138 if (!opt) 1138 if (!opt)
1139 { 1139 {
1140 ERROR("could not allocate table option data."); 1140 ERR("could not allocate table option data.");
1141 return EINA_FALSE; 1141 return EINA_FALSE;
1142 } 1142 }
1143 1143
@@ -1241,14 +1241,14 @@ evas_object_table_unpack(Evas_Object *o, Evas_Object *child)
1241 1241
1242 if (o != evas_object_smart_parent_get(child)) 1242 if (o != evas_object_smart_parent_get(child))
1243 { 1243 {
1244 ERROR("cannot unpack child from incorrect table!"); 1244 ERR("cannot unpack child from incorrect table!");
1245 return EINA_FALSE; 1245 return EINA_FALSE;
1246 } 1246 }
1247 1247
1248 opt = _evas_object_table_option_del(child); 1248 opt = _evas_object_table_option_del(child);
1249 if (!opt) 1249 if (!opt)
1250 { 1250 {
1251 ERROR("cannot unpack child with no packing option!"); 1251 ERR("cannot unpack child with no packing option!");
1252 return EINA_FALSE; 1252 return EINA_FALSE;
1253 } 1253 }
1254 1254
diff --git a/legacy/evas/src/lib/canvas/evas_render.c b/legacy/evas/src/lib/canvas/evas_render.c
index 39eb429916..99e32775fc 100644
--- a/legacy/evas/src/lib/canvas/evas_render.c
+++ b/legacy/evas/src/lib/canvas/evas_render.c
@@ -404,7 +404,7 @@ evas_render_updates_internal(Evas *e, unsigned char make_updates, unsigned char
404 } 404 }
405 if ((e->output.w != e->viewport.w) || (e->output.h != e->viewport.h)) 405 if ((e->output.w != e->viewport.w) || (e->output.h != e->viewport.h))
406 { 406 {
407 ERROR("viewport size != output size!"); 407 ERR("viewport size != output size!");
408 } 408 }
409 /* phase 5. add obscures */ 409 /* phase 5. add obscures */
410 EINA_LIST_FOREACH(e->obscures, ll, r) 410 EINA_LIST_FOREACH(e->obscures, ll, r)
diff --git a/legacy/evas/src/lib/canvas/evas_smart.c b/legacy/evas/src/lib/canvas/evas_smart.c
index 09769e1736..83309dcb8b 100644
--- a/legacy/evas/src/lib/canvas/evas_smart.c
+++ b/legacy/evas/src/lib/canvas/evas_smart.c
@@ -65,7 +65,7 @@ evas_smart_new(const char *name,
65 Evas_Smart *s; 65 Evas_Smart *s;
66 Evas_Smart_Class *sc; 66 Evas_Smart_Class *sc;
67 67
68 WARN("----- WARNING. evas_smart_new() will be deprecated and removed soon" 68 WRN("----- WARNING. evas_smart_new() will be deprecated and removed soon"
69 "----- Please use evas_smart_class_new() instead"); 69 "----- Please use evas_smart_class_new() instead");
70 70
71 if (!name) return NULL; 71 if (!name) return NULL;
diff --git a/legacy/evas/src/lib/canvas/evas_stack.c b/legacy/evas/src/lib/canvas/evas_stack.c
index 84e600a883..f0b04c45f6 100644
--- a/legacy/evas/src/lib/canvas/evas_stack.c
+++ b/legacy/evas/src/lib/canvas/evas_stack.c
@@ -187,7 +187,7 @@ evas_object_stack_above(Evas_Object *obj, Evas_Object *above)
187 { 187 {
188 if (obj->smart.parent != above->smart.parent) 188 if (obj->smart.parent != above->smart.parent)
189 { 189 {
190// ERROR("BITCH! evas_object_stack_above(), %p not inside same smart as %p!", obj, above); 190// ERR("BITCH! evas_object_stack_above(), %p not inside same smart as %p!", obj, above);
191 return; 191 return;
192 } 192 }
193 evas_object_smart_member_stack_above(obj, above); 193 evas_object_smart_member_stack_above(obj, above);
@@ -275,7 +275,7 @@ evas_object_stack_below(Evas_Object *obj, Evas_Object *below)
275 { 275 {
276 if (obj->smart.parent != below->smart.parent) 276 if (obj->smart.parent != below->smart.parent)
277 { 277 {
278// ERROR("BITCH! evas_object_stack_below(), %p not inside same smart as %p!", obj, below); 278// ERR("BITCH! evas_object_stack_below(), %p not inside same smart as %p!", obj, below);
279 return; 279 return;
280 } 280 }
281 evas_object_smart_member_stack_below(obj, below); 281 evas_object_smart_member_stack_below(obj, below);
diff --git a/legacy/evas/src/lib/cserve/evas_cs_client.c b/legacy/evas/src/lib/cserve/evas_cs_client.c
index ea3da306b2..18f2c4ab5e 100644
--- a/legacy/evas/src/lib/cserve/evas_cs_client.c
+++ b/legacy/evas/src/lib/cserve/evas_cs_client.c
@@ -145,7 +145,7 @@ server_read(Server *s, int channel, int *opcode, int *size)
145 if ((*size < 0) || (*size > (1024 * 1024))) return NULL; 145 if ((*size < 0) || (*size > (1024 * 1024))) return NULL;
146 if (ints[2] != (s->ch[channel].req_from + 1)) 146 if (ints[2] != (s->ch[channel].req_from + 1))
147 { 147 {
148 ERROR("EEK! sequence number mismatch from serer with pid: %i\n" 148 ERR("EEK! sequence number mismatch from serer with pid: %i\n"
149 "---- num %i is not 1 more than %i" 149 "---- num %i is not 1 more than %i"
150 , 150 ,
151 s->pid, ints[2], s->ch[channel].req_from); 151 s->pid, ints[2], s->ch[channel].req_from);
diff --git a/legacy/evas/src/lib/cserve/evas_cs_server.c b/legacy/evas/src/lib/cserve/evas_cs_server.c
index d73f04278d..c3fb6dfa43 100644
--- a/legacy/evas/src/lib/cserve/evas_cs_server.c
+++ b/legacy/evas/src/lib/cserve/evas_cs_server.c
@@ -225,7 +225,7 @@ server_parse(Server *s, Client *c)
225 data = c->inbuf + (sizeof(int) * 3); 225 data = c->inbuf + (sizeof(int) * 3);
226 if (ints[2] != (c->req_from + 1)) 226 if (ints[2] != (c->req_from + 1))
227 { 227 {
228 ERROR("EEK! sequence number mismatch from client with pid: %i\n" 228 ERR("EEK! sequence number mismatch from client with pid: %i\n"
229 "---- num %i is not 1 more than %i" 229 "---- num %i is not 1 more than %i"
230 , 230 ,
231 c->pid, ints[2], c->req_from); 231 c->pid, ints[2], c->req_from);
diff --git a/legacy/evas/src/lib/engines/common/evas_convert_main.c b/legacy/evas/src/lib/engines/common/evas_convert_main.c
index a460109db9..9d369005f0 100644
--- a/legacy/evas/src/lib/engines/common/evas_convert_main.c
+++ b/legacy/evas/src/lib/engines/common/evas_convert_main.c
@@ -591,7 +591,7 @@ evas_common_convert_func_get(DATA8 *dest, int w, int h, int depth, DATA32 rmask,
591 } 591 }
592#endif 592#endif
593 } 593 }
594 INFO("depth = %i mode = %i", depth, pal_mode); 594 INF("depth = %i mode = %i", depth, pal_mode);
595 if (depth == 8) 595 if (depth == 8)
596 { 596 {
597#ifdef BUILD_CONVERT_8_RGB_332 597#ifdef BUILD_CONVERT_8_RGB_332
diff --git a/legacy/evas/src/lib/engines/common/evas_convert_rgb_16.c b/legacy/evas/src/lib/engines/common/evas_convert_rgb_16.c
index f46f770549..143f1507b0 100644
--- a/legacy/evas/src/lib/engines/common/evas_convert_rgb_16.c
+++ b/legacy/evas/src/lib/engines/common/evas_convert_rgb_16.c
@@ -715,7 +715,7 @@ evas_common_convert_rgba_to_16bpp_bgr_565_dith_rot_180 (DATA32 *src, DATA8 *dst,
715 715
716 dst_ptr = (DATA16 *)dst; 716 dst_ptr = (DATA16 *)dst;
717 717
718 ERROR("evas_common_convert_rgba_to_16bpp_bgr_565_dith_rot_180"); 718 ERR("evas_common_convert_rgba_to_16bpp_bgr_565_dith_rot_180");
719 719
720 CONVERT_LOOP_START_ROT_180(); 720 CONVERT_LOOP_START_ROT_180();
721 721
diff --git a/legacy/evas/src/lib/engines/common/evas_cpu.c b/legacy/evas/src/lib/engines/common/evas_cpu.c
index f4cc528e30..b0797f3050 100644
--- a/legacy/evas/src/lib/engines/common/evas_cpu.c
+++ b/legacy/evas/src/lib/engines/common/evas_cpu.c
@@ -221,7 +221,7 @@ evas_common_cpu_can_do(int *mmx, int *sse, int *sse2)
221 if (cpu_feature_mask & CPU_FEATURE_MMX2) do_sse = 1; 221 if (cpu_feature_mask & CPU_FEATURE_MMX2) do_sse = 1;
222 if (cpu_feature_mask & CPU_FEATURE_SSE) do_sse = 1; 222 if (cpu_feature_mask & CPU_FEATURE_SSE) do_sse = 1;
223 } 223 }
224// INFO("%i %i %i", do_mmx, do_sse, do_sse2); 224// INF("%i %i %i", do_mmx, do_sse, do_sse2);
225 *mmx = do_mmx; 225 *mmx = do_mmx;
226 *sse = do_sse; 226 *sse = do_sse;
227 *sse2 = do_sse2; 227 *sse2 = do_sse2;
diff --git a/legacy/evas/src/lib/engines/common/evas_font_query.c b/legacy/evas/src/lib/engines/common/evas_font_query.c
index d962d6b10b..43cec87c4a 100644
--- a/legacy/evas/src/lib/engines/common/evas_font_query.c
+++ b/legacy/evas/src/lib/engines/common/evas_font_query.c
@@ -149,7 +149,7 @@ evas_common_font_query_inset(RGBA_Font *fn, const char *text)
149 fg = evas_common_font_int_cache_glyph_get(fi, index); 149 fg = evas_common_font_int_cache_glyph_get(fi, index);
150 if (!fg) return 0; 150 if (!fg) return 0;
151/* 151/*
152 INFO("fg->glyph_out->left = %i\n" 152 INF("fg->glyph_out->left = %i\n"
153 "fi->src->ft.face->glyph->bitmap_left = %i\n" 153 "fi->src->ft.face->glyph->bitmap_left = %i\n"
154 "fi->src->ft.face->glyph->metrics.horiBearingX = %i\n" 154 "fi->src->ft.face->glyph->metrics.horiBearingX = %i\n"
155 "fi->src->ft.face->glyph->metrics.horiBearingY = %i\n" 155 "fi->src->ft.face->glyph->metrics.horiBearingY = %i\n"
diff --git a/legacy/evas/src/lib/engines/common/evas_image_main.c b/legacy/evas/src/lib/engines/common/evas_image_main.c
index 4e1fe3ac14..5827bef4da 100644
--- a/legacy/evas/src/lib/engines/common/evas_image_main.c
+++ b/legacy/evas/src/lib/engines/common/evas_image_main.c
@@ -53,7 +53,7 @@ static int _evas_common_rgba_image_dirty(Image_Entry* dst, const I
53static void 53static void
54_evas_common_rgba_image_debug(const char* context, Image_Entry *eim) 54_evas_common_rgba_image_debug(const char* context, Image_Entry *eim)
55{ 55{
56 DEBUG("%p = [%s] {%s,%s} %i [%i|%i]", eim, context, eim->file, eim->key, eim->references, eim->w, eim->h); 56 DBG("%p = [%s] {%s,%s} %i [%i|%i]", eim, context, eim->file, eim->key, eim->references, eim->w, eim->h);
57} 57}
58 58
59static const Evas_Cache_Image_Func _evas_common_image_func = 59static const Evas_Cache_Image_Func _evas_common_image_func =
@@ -83,7 +83,7 @@ evas_common_image_init(void)
83 if (!eci) 83 if (!eci)
84 eci = evas_cache_image_init(&_evas_common_image_func); 84 eci = evas_cache_image_init(&_evas_common_image_func);
85 reference++; 85 reference++;
86//// ERROR("REF++=%i", reference); 86//// ERR("REF++=%i", reference);
87 87
88#ifdef BUILD_LOADER_EET 88#ifdef BUILD_LOADER_EET
89 eet_init(); 89 eet_init();
diff --git a/legacy/evas/src/lib/engines/common/evas_image_scalecache.c b/legacy/evas/src/lib/engines/common/evas_image_scalecache.c
index d66b2501b6..ec8a5255cb 100644
--- a/legacy/evas/src/lib/engines/common/evas_image_scalecache.c
+++ b/legacy/evas/src/lib/engines/common/evas_image_scalecache.c
@@ -118,7 +118,7 @@ evas_common_rgba_image_scalecache_dirty(Image_Entry *ie)
118 im->cache.list = eina_list_remove(im->cache.list, sci); 118 im->cache.list = eina_list_remove(im->cache.list, sci);
119 if (sci->im) 119 if (sci->im)
120 { 120 {
121// INFO(" 0- %i", sci->dst_w * sci->dst_h * 4); 121// INF(" 0- %i", sci->dst_w * sci->dst_h * 4);
122 LKL(cache_lock); 122 LKL(cache_lock);
123 evas_common_rgba_image_free(&sci->im->cache_entry); 123 evas_common_rgba_image_free(&sci->im->cache_entry);
124 if (!sci->forced_unload) 124 if (!sci->forced_unload)
@@ -185,7 +185,7 @@ _sci_fix_newest(RGBA_Image *im)
185 if (sci->usage_count > im->cache.newest_usage_count) 185 if (sci->usage_count > im->cache.newest_usage_count)
186 im->cache.newest_usage_count = sci->usage_count; 186 im->cache.newest_usage_count = sci->usage_count;
187 } 187 }
188// INFO("_sci_fix_newest! -> %i", im->cache.newest_usage); 188// INF("_sci_fix_newest! -> %i", im->cache.newest_usage);
189} 189}
190 190
191static Scaleitem * 191static Scaleitem *
@@ -233,7 +233,7 @@ _sci_find(RGBA_Image *im,
233 cache_size -= sci->dst_w * sci->dst_h * 4; 233 cache_size -= sci->dst_w * sci->dst_h * 4;
234 else 234 else
235 cache_size -= sci->size_adjust; 235 cache_size -= sci->size_adjust;
236// INFO(" 1- %i", sci->dst_w * sci->dst_h * 4); 236// INF(" 1- %i", sci->dst_w * sci->dst_h * 4);
237 cache_list = eina_inlist_remove(cache_list, (Eina_Inlist *)sci); 237 cache_list = eina_inlist_remove(cache_list, (Eina_Inlist *)sci);
238 } 238 }
239 if (max_scale_items < 1) return NULL; 239 if (max_scale_items < 1) return NULL;
@@ -291,11 +291,11 @@ _cache_prune(Scaleitem *notsci, Eina_Bool copies_only)
291 cache_size -= sci->dst_w * sci->dst_h * 4; 291 cache_size -= sci->dst_w * sci->dst_h * 4;
292 else 292 else
293 cache_size -= sci->size_adjust; 293 cache_size -= sci->size_adjust;
294// INFO(" 2- %i", sci->dst_w * sci->dst_h * 4); 294// INF(" 2- %i", sci->dst_w * sci->dst_h * 4);
295 cache_list = eina_inlist_remove(cache_list, (Eina_Inlist *)sci); 295 cache_list = eina_inlist_remove(cache_list, (Eina_Inlist *)sci);
296 memset(sci, 0, sizeof(Eina_Inlist)); 296 memset(sci, 0, sizeof(Eina_Inlist));
297 } 297 }
298// INFO("FLUSH %i > %i", cache_size, max_cache_size); 298// INF("FLUSH %i > %i", cache_size, max_cache_size);
299 } 299 }
300} 300}
301#endif 301#endif
@@ -385,7 +385,7 @@ evas_common_rgba_image_scalecache_prepare(Image_Entry *ie, RGBA_Image *dst,
385 LKU(im->cache.lock); 385 LKU(im->cache.lock);
386 return; 386 return;
387 } 387 }
388// INFO("%10i | %4i %4i %4ix%4i -> %4i %4i %4ix%4i | %i", 388// INF("%10i | %4i %4i %4ix%4i -> %4i %4i %4ix%4i | %i",
389// (int)use_counter, 389// (int)use_counter,
390// src_region_x, src_region_y, src_region_w, src_region_h, 390// src_region_x, src_region_y, src_region_w, src_region_h,
391// dst_region_x, dst_region_y, dst_region_w, dst_region_h, 391// dst_region_x, dst_region_y, dst_region_w, dst_region_h,
@@ -413,12 +413,12 @@ evas_common_rgba_image_scalecache_prepare(Image_Entry *ie, RGBA_Image *dst,
413 LKU(cache_lock); 413 LKU(cache_lock);
414 if (sci->usage > im->cache.newest_usage) 414 if (sci->usage > im->cache.newest_usage)
415 im->cache.newest_usage = sci->usage; 415 im->cache.newest_usage = sci->usage;
416// INFO("newset? %p %i > %i", im, 416// INF("newset? %p %i > %i", im,
417// (int)sci->usage, 417// (int)sci->usage,
418// (int)im->cache.newest_usage); 418// (int)im->cache.newest_usage);
419 if (sci->usage_count > im->cache.newest_usage_count) 419 if (sci->usage_count > im->cache.newest_usage_count)
420 im->cache.newest_usage_count = sci->usage_count; 420 im->cache.newest_usage_count = sci->usage_count;
421// INFO(" -------------- used %8i#, %8i@", (int)sci->usage, (int)sci->usage_count); 421// INF(" -------------- used %8i#, %8i@", (int)sci->usage, (int)sci->usage_count);
422 LKU(im->cache.lock); 422 LKU(im->cache.lock);
423#endif 423#endif
424} 424}
@@ -449,7 +449,7 @@ evas_common_rgba_image_scalecache_do(Image_Entry *ie, RGBA_Image *dst,
449 i++; 449 i++;
450 if (i > 2000) 450 if (i > 2000)
451 { 451 {
452 INFO("p: %6i, h: %6i, m: %6i, n: %6i", 452 INF("p: %6i, h: %6i, m: %6i, n: %6i",
453 pops, hits, misses, noscales); 453 pops, hits, misses, noscales);
454 i = 0; 454 i = 0;
455 } 455 }
@@ -552,7 +552,7 @@ evas_common_rgba_image_scalecache_do(Image_Entry *ie, RGBA_Image *dst,
552 } 552 }
553 if (sci->populate_me) 553 if (sci->populate_me)
554 { 554 {
555// INFO("##! populate!"); 555// INF("##! populate!");
556 sci->im = evas_common_image_new 556 sci->im = evas_common_image_new
557 (dst_region_w, dst_region_h, im->cache_entry.flags.alpha); 557 (dst_region_w, dst_region_h, im->cache_entry.flags.alpha);
558 if (sci->im) 558 if (sci->im)
@@ -625,7 +625,7 @@ evas_common_rgba_image_scalecache_do(Image_Entry *ie, RGBA_Image *dst,
625 { 625 {
626 cache_size += sci->dst_w * sci->dst_h * 4; 626 cache_size += sci->dst_w * sci->dst_h * 4;
627 } 627 }
628// INFO(" + %i @ flop: %i (%ix%i)", 628// INF(" + %i @ flop: %i (%ix%i)",
629// sci->dst_w * sci->dst_h * 4, sci->flop, 629// sci->dst_w * sci->dst_h * 4, sci->flop,
630// sci->dst_w, sci->dst_h); 630// sci->dst_w, sci->dst_h);
631 cache_list = eina_inlist_append(cache_list, (Eina_Inlist *)sci); 631 cache_list = eina_inlist_append(cache_list, (Eina_Inlist *)sci);
@@ -645,7 +645,7 @@ evas_common_rgba_image_scalecache_do(Image_Entry *ie, RGBA_Image *dst,
645 { 645 {
646 if (sci->flop > 0) sci->flop -= FLOP_DEL; 646 if (sci->flop > 0) sci->flop -= FLOP_DEL;
647 } 647 }
648// INFO("use cached!"); 648// INF("use cached!");
649 evas_common_scale_rgba_in_to_out_clip_sample 649 evas_common_scale_rgba_in_to_out_clip_sample
650 (sci->im, dst, dc, 650 (sci->im, dst, dc,
651 0, 0, 651 0, 0,
@@ -653,7 +653,7 @@ evas_common_rgba_image_scalecache_do(Image_Entry *ie, RGBA_Image *dst,
653 dst_region_x, dst_region_y, 653 dst_region_x, dst_region_y,
654 dst_region_w, dst_region_h); 654 dst_region_w, dst_region_h);
655// hits++; 655// hits++;
656// INFO("check %p %i < %i", 656// INF("check %p %i < %i",
657// im, 657// im,
658// (int)im->cache.orig_usage, 658// (int)im->cache.orig_usage,
659// (int)im->cache.newest_usage); 659// (int)im->cache.newest_usage);
diff --git a/legacy/evas/src/lib/engines/common/evas_pipe.c b/legacy/evas/src/lib/engines/common/evas_pipe.c
index 9ef20e4a14..a9fee85e12 100644
--- a/legacy/evas/src/lib/engines/common/evas_pipe.c
+++ b/legacy/evas/src/lib/engines/common/evas_pipe.c
@@ -75,7 +75,7 @@ evas_common_pipe_thread(void *data)
75{ 75{
76 Thinfo *thinfo; 76 Thinfo *thinfo;
77 77
78// INFO("TH [..........."); 78// INF("TH [...........");
79 thinfo = data; 79 thinfo = data;
80 for (;;) 80 for (;;)
81 { 81 {
@@ -83,13 +83,13 @@ evas_common_pipe_thread(void *data)
83 RGBA_Pipe *p; 83 RGBA_Pipe *p;
84 84
85 /* wait for start signal */ 85 /* wait for start signal */
86// INFO(" TH %i START...", thinfo->thread_num); 86// INF(" TH %i START...", thinfo->thread_num);
87 pthread_barrier_wait(&(thinfo->barrier[0])); 87 pthread_barrier_wait(&(thinfo->barrier[0]));
88 info = thinfo->info; 88 info = thinfo->info;
89// if (info) 89// if (info)
90// { 90// {
91// thinfo->info = NULL; 91// thinfo->info = NULL;
92// INFO(" TH %i GO", thinfo->thread_num); 92// INF(" TH %i GO", thinfo->thread_num);
93 EINA_INLIST_FOREACH(EINA_INLIST_GET(info->im->pipe), p) 93 EINA_INLIST_FOREACH(EINA_INLIST_GET(info->im->pipe), p)
94 { 94 {
95 int i; 95 int i;
@@ -102,7 +102,7 @@ evas_common_pipe_thread(void *data)
102 } 102 }
103 free(info); 103 free(info);
104// } 104// }
105// INFO(" TH %i DONE", thinfo->thread_num); 105// INF(" TH %i DONE", thinfo->thread_num);
106 /* send finished signal */ 106 /* send finished signal */
107 pthread_barrier_wait(&(thinfo->barrier[1])); 107 pthread_barrier_wait(&(thinfo->barrier[1]));
108 } 108 }
diff --git a/legacy/evas/src/lib/engines/common/evas_tiler.c b/legacy/evas/src/lib/engines/common/evas_tiler.c
index c28641cc45..c29359f1fe 100644
--- a/legacy/evas/src/lib/engines/common/evas_tiler.c
+++ b/legacy/evas/src/lib/engines/common/evas_tiler.c
@@ -94,7 +94,7 @@ rect_init(rect_t *r, int x, int y, int w, int h)
94void 94void
95rect_print(const rect_t r) 95rect_print(const rect_t r)
96{ 96{
97 INFO("<rect(%d, %d, %d, %d)>", r.left, r.top, r.width, r.height); 97 INF("<rect(%d, %d, %d, %d)>", r.left, r.top, r.width, r.height);
98} 98}
99 99
100void 100void
@@ -716,7 +716,7 @@ rect_list_add_split_fuzzy(list_t *rects, list_node_t *node, int accepted_error)
716 */ 716 */
717 /* prev_cur_node = cur_node; */ 717 /* prev_cur_node = cur_node; */
718 /* cur_node = cur_node->next; */ 718 /* cur_node = cur_node->next; */
719 WARN("Should not get here!"); 719 WRN("Should not get here!");
720 abort(); 720 abort();
721 } 721 }
722 722
@@ -919,7 +919,7 @@ _add_redraw(list_t *rects, int max_w, int max_h, int x, int y, int w, int h)
919 rn = (rect_node_t *)rect_list_node_pool_get(); 919 rn = (rect_node_t *)rect_list_node_pool_get();
920 rn->_lst = list_node_zeroed; 920 rn->_lst = list_node_zeroed;
921 rect_init(&rn->rect, x, y, w, h); 921 rect_init(&rn->rect, x, y, w, h);
922 //INFO(stderr, "ACCOUNTING: add_redraw: %4d,%4d %3dx%3d", x, y, w, h); 922 //INF("ACCOUNTING: add_redraw: %4d,%4d %3dx%3d", x, y, w, h);
923 //testing on my core2 duo desktop - fuzz of 32 or 48 is best. 923 //testing on my core2 duo desktop - fuzz of 32 or 48 is best.
924#define FUZZ 32 924#define FUZZ 32
925 rect_list_add_split_fuzzy_and_merge(rects, (list_node_t *)rn, 925 rect_list_add_split_fuzzy_and_merge(rects, (list_node_t *)rn,
@@ -1007,7 +1007,7 @@ evas_common_tilebuf_del_redraw(Tilebuf *tb, int x, int y, int w, int h)
1007 if ((w <= 0) || (h <= 0)) return 0; 1007 if ((w <= 0) || (h <= 0)) return 0;
1008 1008
1009 rect_init(&r, x, y, w, h); 1009 rect_init(&r, x, y, w, h);
1010 //ERROR("ACCOUNTING: del_redraw: %4d,%4d %3dx%3d", x, y, w, h); 1010 //ERR("ACCOUNTING: del_redraw: %4d,%4d %3dx%3d", x, y, w, h);
1011 1011
1012 rect_list_del_split_strict(&tb->rects, r); 1012 rect_list_del_split_strict(&tb->rects, r);
1013 tb->need_merge = 1; 1013 tb->need_merge = 1;
diff --git a/legacy/evas/src/lib/engines/common_16/evas_soft16_image_scaled_sampled.c b/legacy/evas/src/lib/engines/common_16/evas_soft16_image_scaled_sampled.c
index 675be741da..b5b07d6a12 100644
--- a/legacy/evas/src/lib/engines/common_16/evas_soft16_image_scaled_sampled.c
+++ b/legacy/evas/src/lib/engines/common_16/evas_soft16_image_scaled_sampled.c
@@ -101,7 +101,7 @@ _soft16_image_draw_scaled_no_mul(Soft16_Image *src, Soft16_Image *dst,
101 _soft16_image_draw_scaled_solid_solid 101 _soft16_image_draw_scaled_solid_solid
102 (src, dst, dc, dst_offset, w, h, offset_x, offset_y); 102 (src, dst, dc, dst_offset, w, h, offset_x, offset_y);
103 else 103 else
104 ERROR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, " 104 ERR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, "
105 "dst->cache_entry.flags.alpha=%d, WITHOUT COLOR MUL", 105 "dst->cache_entry.flags.alpha=%d, WITHOUT COLOR MUL",
106 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha); 106 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha);
107} 107}
@@ -213,7 +213,7 @@ _soft16_image_draw_scaled_mul_alpha(Soft16_Image *src, Soft16_Image *dst,
213 _soft16_image_draw_scaled_solid_solid_mul_alpha 213 _soft16_image_draw_scaled_solid_solid_mul_alpha
214 (src, dst, dc, dst_offset, w, h, offset_x, offset_y, a); 214 (src, dst, dc, dst_offset, w, h, offset_x, offset_y, a);
215 else 215 else
216 ERROR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, " 216 ERR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, "
217 "dst->cache_entry.flags.alpha=%d, WITH ALPHA MUL %d", 217 "dst->cache_entry.flags.alpha=%d, WITH ALPHA MUL %d",
218 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, A_VAL(&dc->mul.col)); 218 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, A_VAL(&dc->mul.col));
219} 219}
@@ -395,7 +395,7 @@ _soft16_image_draw_scaled_mul_color(Soft16_Image *src, Soft16_Image *dst,
395 _soft16_image_draw_scaled_solid_solid_mul_color 395 _soft16_image_draw_scaled_solid_solid_mul_color
396 (src, dst, dc, dst_offset, w, h, offset_x, offset_y, r, g, b, a); 396 (src, dst, dc, dst_offset, w, h, offset_x, offset_y, r, g, b, a);
397 else 397 else
398 ERROR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, " 398 ERR("Unsupported draw of scaled images src->cache_entry.flags.alpha=%d, "
399 "dst->cache_entry.flags.alpha=%d, WITH COLOR MUL 0x%08x", 399 "dst->cache_entry.flags.alpha=%d, WITH COLOR MUL 0x%08x",
400 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, dc->mul.col); 400 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, dc->mul.col);
401} 401}
diff --git a/legacy/evas/src/lib/engines/common_16/evas_soft16_image_unscaled.c b/legacy/evas/src/lib/engines/common_16/evas_soft16_image_unscaled.c
index fc782ad94a..b7a428dfa2 100644
--- a/legacy/evas/src/lib/engines/common_16/evas_soft16_image_unscaled.c
+++ b/legacy/evas/src/lib/engines/common_16/evas_soft16_image_unscaled.c
@@ -60,7 +60,7 @@ _soft16_image_draw_unscaled_no_mul(Soft16_Image *src, Soft16_Image *dst,
60 src_offset, dst_offset, 60 src_offset, dst_offset,
61 width, height); 61 width, height);
62 else 62 else
63 ERROR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, " 63 ERR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, "
64 "dst->cache_entry.flags.alpha=%d, WITHOUT COLOR MUL", 64 "dst->cache_entry.flags.alpha=%d, WITHOUT COLOR MUL",
65 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha); 65 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha);
66} 66}
@@ -127,7 +127,7 @@ _soft16_image_draw_unscaled_mul_alpha(Soft16_Image *src, Soft16_Image *dst,
127 _soft16_image_draw_unscaled_solid_solid_mul_alpha 127 _soft16_image_draw_unscaled_solid_solid_mul_alpha
128 (src, dst, dc, src_offset, dst_offset, width, height, a); 128 (src, dst, dc, src_offset, dst_offset, width, height, a);
129 else 129 else
130 ERROR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, " 130 ERR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, "
131 "dst->cache_entry.flags.alpha=%d, WITH ALPHA MUL %d", 131 "dst->cache_entry.flags.alpha=%d, WITH ALPHA MUL %d",
132 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, A_VAL(&dc->mul.col)); 132 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, A_VAL(&dc->mul.col));
133} 133}
@@ -217,7 +217,7 @@ _soft16_image_draw_unscaled_mul_color(Soft16_Image *src, Soft16_Image *dst,
217 _soft16_image_draw_unscaled_solid_solid_mul_color 217 _soft16_image_draw_unscaled_solid_solid_mul_color
218 (src, dst, dc, src_offset, dst_offset, width, height, r, g, b, a); 218 (src, dst, dc, src_offset, dst_offset, width, height, r, g, b, a);
219 else 219 else
220 ERROR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, " 220 ERR("Unsupported draw of unscaled images src->cache_entry.flags.alpha=%d, "
221 "dst->cache_entry.flags.alpha=%d, WITH COLOR MUL 0x%08x", 221 "dst->cache_entry.flags.alpha=%d, WITH COLOR MUL 0x%08x",
222 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, dc->mul.col); 222 src->cache_entry.flags.alpha, dst->cache_entry.flags.alpha, dc->mul.col);
223} 223}
diff --git a/legacy/evas/src/lib/engines/common_16/evas_soft16_main.c b/legacy/evas/src/lib/engines/common_16/evas_soft16_main.c
index 64b9cb83cc..415d137421 100644
--- a/legacy/evas/src/lib/engines/common_16/evas_soft16_main.c
+++ b/legacy/evas/src/lib/engines/common_16/evas_soft16_main.c
@@ -28,7 +28,7 @@ static int _evas_common_load_soft16_image_data_from_file(Image_Ent
28/* static void */ 28/* static void */
29/* _evas_common_soft16_image_debug(const char* context, Image_Entry *eim) */ 29/* _evas_common_soft16_image_debug(const char* context, Image_Entry *eim) */
30/* { */ 30/* { */
31/* DEBUG("[16] %p = [%s] {%s,%s} %i [%i|%i]", eim, context, eim->file, eim->key, eim->references, eim->w, eim->h); */ 31/* DBG("[16] %p = [%s] {%s,%s} %i [%i|%i]", eim, context, eim->file, eim->key, eim->references, eim->w, eim->h); */
32/* } */ 32/* } */
33 33
34static const Evas_Cache_Image_Func _evas_common_soft16_image_func = 34static const Evas_Cache_Image_Func _evas_common_soft16_image_func =
diff --git a/legacy/evas/src/lib/engines/common_16/evas_soft16_rectangle.c b/legacy/evas/src/lib/engines/common_16/evas_soft16_rectangle.c
index dd5571df71..37b1d56c3a 100644
--- a/legacy/evas/src/lib/engines/common_16/evas_soft16_rectangle.c
+++ b/legacy/evas/src/lib/engines/common_16/evas_soft16_rectangle.c
@@ -71,7 +71,7 @@ _soft16_rectangle_draw_int(Soft16_Image *dst, RGBA_Draw_Context *dc,
71 (dst, dst_offset, dr.w, dr.h, rgb565, alpha); 71 (dst, dst_offset, dr.w, dr.h, rgb565, alpha);
72 } 72 }
73 else 73 else
74 ERROR("Unsupported feature: drawing rectangle to non-opaque destination."); 74 ERR("Unsupported feature: drawing rectangle to non-opaque destination.");
75} 75}
76 76
77void 77void
diff --git a/legacy/evas/src/lib/include/evas_common.h b/legacy/evas/src/lib/include/evas_common.h
index 924ee3adbe..377320ddb4 100644
--- a/legacy/evas/src/lib/include/evas_common.h
+++ b/legacy/evas/src/lib/include/evas_common.h
@@ -14,61 +14,40 @@
14 14
15/* macros needed to log message through eina_log */ 15/* macros needed to log message through eina_log */
16extern EAPI int _evas_log_dom_global; 16extern EAPI int _evas_log_dom_global;
17#ifdef _EVAS_DEFAULT_MODULE_LOG_DOM 17#ifdef _EVAS_DEFAULT_LOG_DOM
18# undef _EVAS_DEFAULT_MODULE_LOG_DOM 18# undef _EVAS_DEFAULT_LOG_DOM
19#endif 19#endif
20#define _EVAS_DEFAULT_MODULE_LOG_DOM _evas_log_dom_global 20#define _EVAS_DEFAULT_LOG_DOM _evas_log_dom_global
21 21
22#ifdef EVAS_DEFAULT_LOG_COLOR 22#ifdef EVAS_DEFAULT_LOG_COLOR
23# undef EVAS_DEFAULT_LOG_COLOR 23# undef EVAS_DEFAULT_LOG_COLOR
24#endif 24#endif
25#define EVAS_DEFAULT_LOG_COLOR "\033[36m" 25#define EVAS_DEFAULT_LOG_COLOR EINA_COLOR_BLUE
26#ifdef ERROR
27# undef ERROR
28#endif
29#define ERROR(...) EINA_LOG_DOM_ERR(_evas_log_dom_global, __VA_ARGS__)
30#ifdef DEBUG
31# undef DEBUG
32#endif
33#define DEBUG(...) EINA_LOG_DOM_DBG(_evas_log_dom_global, __VA_ARGS__)
34#ifdef INFO
35# undef INFO
36#endif
37#define INFO(...) EINA_LOG_DOM_INFO(_evas_log_dom_global, __VA_ARGS__)
38#ifdef WARN
39# undef WARN
40#endif
41#define WARN(...) EINA_LOG_DOM_WARN(_evas_log_dom_global, __VA_ARGS__)
42#ifdef CRITICAL
43# undef CRITICAL
44#endif
45#define CRITICAL(...) EINA_LOG_DOM_CRIT(_evas_log_dom_global, __VA_ARGS__)
46/**
47 * macros that are used all around the code for message processing
48 * four macros are defined ERR, WRN, DGB, INF.
49 * EFREET_MODULE_LOG_DOM should be defined individually for each module
50 */
51 26
52#ifdef ERR 27#ifdef ERR
53# undef ERR 28# undef ERR
54#endif 29#endif
55#define ERR(...) EINA_LOG_DOM_ERR(_EVAS_DEFAULT_MODULE_LOG_DOM, __VA_ARGS__) 30#define ERR(...) EINA_LOG_DOM_ERR(_EVAS_DEFAULT_LOG_DOM, __VA_ARGS__)
31
56#ifdef DBG 32#ifdef DBG
57# undef DBG 33# undef DBG
58#endif 34#endif
59#define DBG(...) EINA_LOG_DOM_DBG(_EVAS_DEFAULT_MODULE_LOG_DOM, __VA_ARGS__) 35#define DBG(...) EINA_LOG_DOM_DBG(_EVAS_DEFAULT_LOG_DOM, __VA_ARGS__)
36
60#ifdef INF 37#ifdef INF
61# undef INF 38# undef INF
62#endif 39#endif
63#define INF(...) EINA_LOG_DOM_INFO(_EVAS_DEFAULT__MODULE_LOG_DOM, __VA_ARGS__) 40#define INF(...) EINA_LOG_DOM_INFO(_EVAS_DEFAULT_LOG_DOM, __VA_ARGS__)
41
64#ifdef WRN 42#ifdef WRN
65# undef WRN 43# undef WRN
66#endif 44#endif
67#define WRN(...) EINA_LOG_DOM_WARN(_EVAS_DEFAULT_MODULE_LOG_DOM, __VA_ARGS__) 45#define WRN(...) EINA_LOG_DOM_WARN(_EVAS_DEFAULT_LOG_DOM, __VA_ARGS__)
46
68#ifdef CRIT 47#ifdef CRIT
69# undef CRIT 48# undef CRIT
70#endif 49#endif
71#define CRIT(...) EINA_LOG_DOM_CRIT(_EVAS_DEFAULT_MODULE_LOG_DOM, __VA_ARGS__) 50#define CRIT(...) EINA_LOG_DOM_CRIT(_EVAS_DEFAULT_LOG_DOM, __VA_ARGS__)
72 51
73/*****************************************************************************/ 52/*****************************************************************************/
74 53
diff --git a/legacy/evas/src/lib/main.c b/legacy/evas/src/lib/main.c
index f95da6f136..a50e8cdd30 100644
--- a/legacy/evas/src/lib/main.c
+++ b/legacy/evas/src/lib/main.c
@@ -101,7 +101,7 @@ evas_debug_error(void)
101 _evas_debug_init = 1; 101 _evas_debug_init = 1;
102 } 102 }
103 if (_evas_debug_show) 103 if (_evas_debug_show)
104 DEBUG("*** EVAS ERROR: Evas Magic Check Failed!!!"); 104 DBG("*** EVAS ERROR: Evas Magic Check Failed!!!");
105} 105}
106 106
107void 107void
@@ -114,7 +114,7 @@ evas_debug_input_null(void)
114 _evas_debug_init = 1; 114 _evas_debug_init = 1;
115 } 115 }
116 if (_evas_debug_show) 116 if (_evas_debug_show)
117 DEBUG("Input object pointer is NULL!"); 117 DBG("Input object pointer is NULL!");
118 if (_evas_debug_abort) abort(); 118 if (_evas_debug_abort) abort();
119} 119}
120 120
@@ -128,7 +128,7 @@ evas_debug_magic_null(void)
128 _evas_debug_init = 1; 128 _evas_debug_init = 1;
129 } 129 }
130 if (_evas_debug_show) 130 if (_evas_debug_show)
131 DEBUG("Input object is zero'ed out (maybe a freed object or zero-filled RAM)!"); 131 DBG("Input object is zero'ed out (maybe a freed object or zero-filled RAM)!");
132 if (_evas_debug_abort) abort(); 132 if (_evas_debug_abort) abort();
133} 133}
134 134
@@ -142,7 +142,7 @@ evas_debug_magic_wrong(DATA32 expected, DATA32 supplied)
142 _evas_debug_init = 1; 142 _evas_debug_init = 1;
143 } 143 }
144 if (_evas_debug_show) 144 if (_evas_debug_show)
145 DEBUG(" Input object is wrong type\n" 145 DBG(" Input object is wrong type\n"
146 " Expected: %08x - %s\n" 146 " Expected: %08x - %s\n"
147 " Supplied: %08x - %s", 147 " Supplied: %08x - %s",
148 expected, evas_debug_magic_string_get(expected), 148 expected, evas_debug_magic_string_get(expected),
@@ -160,7 +160,7 @@ evas_debug_generic(const char *str)
160 _evas_debug_init = 1; 160 _evas_debug_init = 1;
161 } 161 }
162 if (_evas_debug_show) 162 if (_evas_debug_show)
163 DEBUG("*** EVAS ERROR:\n" 163 DBG("*** EVAS ERROR:\n"
164 "%s", (char *)str); 164 "%s", (char *)str);
165 if (_evas_debug_abort) abort(); 165 if (_evas_debug_abort) abort();
166} 166}
diff --git a/legacy/evas/src/modules/engines/buffer/evas_engine.c b/legacy/evas/src/modules/engines/buffer/evas_engine.c
index d9a5b0820b..04820b359e 100644
--- a/legacy/evas/src/modules/engines/buffer/evas_engine.c
+++ b/legacy/evas/src/modules/engines/buffer/evas_engine.c
@@ -3,9 +3,19 @@
3#include "evas_engine.h" 3#include "evas_engine.h"
4#include "Evas_Engine_Buffer.h" 4#include "Evas_Engine_Buffer.h"
5 5
6/* domain for eina_log */
7/* the log macros are defined in evas_common.h */
8/* theirs names are EVAS_ERR, EVAS_DBG, EVAS_CRIT, EVAS_WRN and EVAS_INF */
9/* although we can use the EVAS_ERROR, etc... macros it will not work
10 when the -fvisibility=hidden option is passed to gcc */
11
12int _evas_engine_buffer_log_dom = -1;
13
6/* function tables - filled in later (func and parent func) */ 14/* function tables - filled in later (func and parent func) */
15
7static Evas_Func func, pfunc; 16static Evas_Func func, pfunc;
8 17
18
9/* engine struct data */ 19/* engine struct data */
10typedef struct _Render_Engine Render_Engine; 20typedef struct _Render_Engine Render_Engine;
11 21
@@ -72,7 +82,7 @@ _output_setup(int w,
72 evas_common_tilebuf_init(); 82 evas_common_tilebuf_init();
73 83
74 evas_buffer_outbuf_buf_init(); 84 evas_buffer_outbuf_buf_init();
75 85
76 { 86 {
77 Outbuf_Depth dep; 87 Outbuf_Depth dep;
78 DATA32 color_key = 0; 88 DATA32 color_key = 0;
@@ -113,7 +123,6 @@ static void *
113eng_info(Evas *e) 123eng_info(Evas *e)
114{ 124{
115 Evas_Engine_Info_Buffer *info; 125 Evas_Engine_Info_Buffer *info;
116
117 info = calloc(1, sizeof(Evas_Engine_Info_Buffer)); 126 info = calloc(1, sizeof(Evas_Engine_Info_Buffer));
118 if (!info) return NULL; 127 if (!info) return NULL;
119 info->magic.magic = rand(); 128 info->magic.magic = rand();
@@ -125,7 +134,6 @@ static void
125eng_info_free(Evas *e __UNUSED__, void *info) 134eng_info_free(Evas *e __UNUSED__, void *info)
126{ 135{
127 Evas_Engine_Info_Buffer *in; 136 Evas_Engine_Info_Buffer *in;
128
129 in = (Evas_Engine_Info_Buffer *)info; 137 in = (Evas_Engine_Info_Buffer *)info;
130 free(in); 138 free(in);
131} 139}
@@ -340,6 +348,14 @@ module_open(Evas_Module *em)
340 if (!em) return 0; 348 if (!em) return 0;
341 /* get whatever engine module we inherit from */ 349 /* get whatever engine module we inherit from */
342 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0; 350 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0;
351
352 _evas_engine_buffer_log_dom = eina_log_domain_register("EvasBufferEngine", EINA_COLOR_BLUE);
353 if(_evas_engine_buffer_log_dom < 0)
354 {
355 EINA_LOG_ERR("Impossible to create a log domain for Eina.buffer.\n");
356 return 0;
357 }
358
343 /* store it for later use */ 359 /* store it for later use */
344 func = pfunc; 360 func = pfunc;
345 /* now to override methods */ 361 /* now to override methods */
@@ -366,6 +382,7 @@ module_open(Evas_Module *em)
366static void 382static void
367module_close(Evas_Module *em) 383module_close(Evas_Module *em)
368{ 384{
385 eina_log_domain_unregister(_evas_engine_buffer_log_dom);
369} 386}
370 387
371static Evas_Module_Api evas_modapi = 388static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/buffer/evas_engine.h b/legacy/evas/src/modules/engines/buffer/evas_engine.h
index ac28620f95..32577cf9d7 100644
--- a/legacy/evas/src/modules/engines/buffer/evas_engine.h
+++ b/legacy/evas/src/modules/engines/buffer/evas_engine.h
@@ -1,5 +1,33 @@
1#ifndef EVAS_ENGINE_H 1#ifndef EVAS_ENGINE_H
2#define EVAS_ENGINE_H 2#define EVAS_ENGINE_H
3#include "evas_common.h"
4/* this thing is for eina_log */
5extern int _evas_engine_buffer_log_dom ;
6
7#ifdef ERR
8# undef ERR
9#endif
10#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_buffer_log_dom, __VA_ARGS__)
11
12#ifdef DBG
13# undef DBG
14#endif
15#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_buffer_log_dom, __VA_ARGS__)
16
17#ifdef INF
18# undef INF
19#endif
20#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_buffer_log_dom, __VA_ARGS__)
21
22#ifdef WRN
23# undef WRN
24#endif
25#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_buffer_log_dom, __VA_ARGS__)
26
27#ifdef CRIT
28# undef CRIT
29#endif
30#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_buffer_log_dom, __VA_ARGS__)
3 31
4typedef struct _Outbuf Outbuf; 32typedef struct _Outbuf Outbuf;
5 33
diff --git a/legacy/evas/src/modules/engines/cairo_x11/evas_engine.c b/legacy/evas/src/modules/engines/cairo_x11/evas_engine.c
index e9dbac0839..a6a9923479 100644
--- a/legacy/evas/src/modules/engines/cairo_x11/evas_engine.c
+++ b/legacy/evas/src/modules/engines/cairo_x11/evas_engine.c
@@ -8,6 +8,9 @@
8#include "Evas_Engine_Cairo_X11.h" 8#include "Evas_Engine_Cairo_X11.h"
9#include "evas_cairo_common.h" 9#include "evas_cairo_common.h"
10 10
11/* domain for eina_log */
12int _evas_engine_cairo_X11_log_dom = -1;
13
11static void *eng_info(Evas *e); 14static void *eng_info(Evas *e);
12static void eng_info_free(Evas *e, void *info); 15static void eng_info_free(Evas *e, void *info);
13static int eng_setup(Evas *e, void *info); 16static int eng_setup(Evas *e, void *info);
@@ -257,11 +260,10 @@ static void *
257eng_info(Evas *e) 260eng_info(Evas *e)
258{ 261{
259 Evas_Engine_Info_Cairo_X11 *info; 262 Evas_Engine_Info_Cairo_X11 *info;
260 263 INF("CAIRO: create info...");
261 info = calloc(1, sizeof(Evas_Engine_Info_Cairo_X11)); 264 info = calloc(1, sizeof(Evas_Engine_Info_Cairo_X11));
262 if (!info) return NULL; 265 if (!info) return NULL;
263 info->magic.magic = rand(); 266 info->magic.magic = rand();
264 INFO("CAIRO: create info...");
265 return info; 267 return info;
266 e = NULL; 268 e = NULL;
267} 269}
@@ -270,7 +272,6 @@ static void
270eng_info_free(Evas *e, void *info) 272eng_info_free(Evas *e, void *info)
271{ 273{
272 Evas_Engine_Info_Cairo_X11 *in; 274 Evas_Engine_Info_Cairo_X11 *in;
273
274 in = (Evas_Engine_Info_Cairo_X11 *)info; 275 in = (Evas_Engine_Info_Cairo_X11 *)info;
275 free(in); 276 free(in);
276} 277}
@@ -282,7 +283,7 @@ eng_setup(Evas *e, void *in)
282 Evas_Engine_Info_Cairo_X11 *info; 283 Evas_Engine_Info_Cairo_X11 *info;
283 284
284 info = (Evas_Engine_Info_Cairo_X11 *)in; 285 info = (Evas_Engine_Info_Cairo_X11 *)in;
285 INFO("CAIRO: setup info..."); 286 INF("CAIRO: setup info...");
286 if (!e->engine.data.output) 287 if (!e->engine.data.output)
287 e->engine.data.output = 288 e->engine.data.output =
288 eng_output_setup(e->output.w, 289 eng_output_setup(e->output.w,
@@ -318,7 +319,7 @@ eng_output_setup(int w, int h, Display *disp, Drawable draw, Visual *vis, Colorm
318 free(re); 319 free(re);
319 return NULL; 320 return NULL;
320 } 321 }
321 INFO("CAIRO: cairo window setup done."); 322 INF("CAIRO: cairo window setup done.");
322 evas_common_cpu_init(); 323 evas_common_cpu_init();
323 324
324 evas_common_blend_init(); 325 evas_common_blend_init();
@@ -1500,6 +1501,12 @@ static int
1500module_open(Evas_Module *em) 1501module_open(Evas_Module *em)
1501{ 1502{
1502 if (!em) return 0; 1503 if (!em) return 0;
1504 _evas_engine_cairo_X11_log_dom = eina_log_domain_register("EvasCairoX11Engine", EINA_COLOR_BLUE);
1505 if(_evas_engine_cairo_X11_log_dom < 0)
1506 {
1507 EINA_LOG_ERR("Impossible to create a log doamin for the cairo (X11) engine.\n");
1508 return 0;
1509 }
1503 em->functions = (void *)(&eng_func); 1510 em->functions = (void *)(&eng_func);
1504 return 1; 1511 return 1;
1505} 1512}
@@ -1507,6 +1514,7 @@ module_open(Evas_Module *em)
1507static void 1514static void
1508module_close(Evas_Module *em) 1515module_close(Evas_Module *em)
1509{ 1516{
1517 eina_log_domain_unregister(_evas_engine_cairo_X11_log_dom);
1510} 1518}
1511 1519
1512static Evas_Module_Api evas_modapi = 1520static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/cairo_x11/evas_engine.h b/legacy/evas/src/modules/engines/cairo_x11/evas_engine.h
index 7d52241d27..a454af8ec7 100644
--- a/legacy/evas/src/modules/engines/cairo_x11/evas_engine.h
+++ b/legacy/evas/src/modules/engines/cairo_x11/evas_engine.h
@@ -1,8 +1,36 @@
1#ifndef EVAS_ENGINE_H 1#ifndef EVAS_ENGINE_H
2#define EVAS_ENGINE_H 2#define EVAS_ENGINE_H
3 3#include "evas_common.h"
4#include "evas_cairo_common.h" 4#include "evas_cairo_common.h"
5 5
6extern int _evas_engine_cairo_X11_log_dom ;
7
8#ifdef ERR
9# undef ERR
10#endif
11#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_cairo_X11_log_dom, __VA_ARGS__)
12
13#ifdef DBG
14# undef DBG
15#endif
16#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_cairo_X11_log_dom, __VA_ARGS__)
17
18#ifdef INF
19# undef INF
20#endif
21#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_cairo_X11_log_dom, __VA_ARGS__)
22
23#ifdef WRN
24# undef WRN
25#endif
26#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_cairo_X11_log_dom, __VA_ARGS__)
27
28#ifdef CRIT
29# undef CRIT
30#endif
31#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_cairo_X11_log_dom, __VA_ARGS__)
32
33
6typedef struct _Evas_Cairo_X11_Window Evas_Cairo_X11_Window; 34typedef struct _Evas_Cairo_X11_Window Evas_Cairo_X11_Window;
7 35
8struct _Evas_Cairo_X11_Window 36struct _Evas_Cairo_X11_Window
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_device.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_device.cpp
index 5be8ddbb89..ce0d985565 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_device.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_device.cpp
@@ -29,21 +29,21 @@ bool D3DDevice::Init(HWND window, int depth, bool fullscreen)
29 29
30 if (FAILED(hr = _object->GetAdapterDisplayMode(D3DADAPTER_DEFAULT, &dm))) 30 if (FAILED(hr = _object->GetAdapterDisplayMode(D3DADAPTER_DEFAULT, &dm)))
31 { 31 {
32 Log("GetAdapterDisplayMode failed: %x", hr); 32 ERR("GetAdapterDisplayMode failed: %x", hr);
33 Destroy(); 33 Destroy();
34 return false; 34 return false;
35 } 35 }
36 36
37 if (FAILED(hr = _object->GetDeviceCaps(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, &caps))) 37 if (FAILED(hr = _object->GetDeviceCaps(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, &caps)))
38 { 38 {
39 Log("GetDeviceCaps failed: %x", hr); 39 ERR("GetDeviceCaps failed: %x", hr);
40 Destroy(); 40 Destroy();
41 return false; 41 return false;
42 } 42 }
43 43
44 if (!GetClientRect(window, &rect)) 44 if (!GetClientRect(window, &rect))
45 { 45 {
46 Log("GetClientRect failed: %x", GetLastError()); 46 ERR("GetClientRect failed: %x", GetLastError());
47 Destroy(); 47 Destroy();
48 return false; 48 return false;
49 } 49 }
@@ -84,7 +84,7 @@ bool D3DDevice::Init(HWND window, int depth, bool fullscreen)
84 if (FAILED(hr = _object->CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, 84 if (FAILED(hr = _object->CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL,
85 window, flag, &pp, &_device))) 85 window, flag, &pp, &_device)))
86 { 86 {
87 Log("CreateDevice failed: %x", hr); 87 WRN("CreateDevice failed: %x", hr);
88 Destroy(); 88 Destroy();
89 return false; 89 return false;
90 } 90 }
@@ -103,7 +103,7 @@ bool D3DDevice::Init(HWND window, int depth, bool fullscreen)
103 _depth = 16; 103 _depth = 16;
104 break; 104 break;
105 default: 105 default:
106 Log("No supported format found"); 106 WRN("No supported format found");
107 Destroy(); 107 Destroy();
108 return false; 108 return false;
109 } 109 }
@@ -119,7 +119,7 @@ bool D3DDevice::Init(HWND window, int depth, bool fullscreen)
119 119
120 if (FAILED(CreateRenderTarget())) 120 if (FAILED(CreateRenderTarget()))
121 { 121 {
122 Log("Failed to create render target"); 122 ERR("Failed to create render target");
123 Destroy(); 123 Destroy();
124 return false; 124 return false;
125 } 125 }
@@ -136,7 +136,7 @@ bool D3DDevice::Reset(int width, int height, int fullscreen)
136 _d3dpp.Windowed = (fullscreen == 1) ? FALSE : ((fullscreen == 0) ? TRUE : _d3dpp.Windowed); 136 _d3dpp.Windowed = (fullscreen == 1) ? FALSE : ((fullscreen == 0) ? TRUE : _d3dpp.Windowed);
137 if (FAILED(ResetDevice())) 137 if (FAILED(ResetDevice()))
138 { 138 {
139 Log("Couldnt restore device"); 139 WRN("Couldnt restore device");
140 _d3dpp = pp; 140 _d3dpp = pp;
141 return SUCCEEDED(ResetDevice()); 141 return SUCCEEDED(ResetDevice());
142 } 142 }
@@ -166,7 +166,7 @@ void D3DDevice::Destroy()
166 _object->Release(); 166 _object->Release();
167 ResetParams(); 167 ResetParams();
168 168
169 Log("uninitialized"); 169 INF("uninitialized");
170} 170}
171 171
172void D3DDevice::ResetParams() 172void D3DDevice::ResetParams()
@@ -201,7 +201,7 @@ HRESULT D3DDevice::RestoreDevice()
201 if (SUCCEEDED(hr = _device->TestCooperativeLevel())) 201 if (SUCCEEDED(hr = _device->TestCooperativeLevel()))
202 { 202 {
203 _device_lost = FALSE; 203 _device_lost = FALSE;
204 Log("render test ok"); 204 DBG("render test ok");
205 return S_OK; 205 return S_OK;
206 } 206 }
207 207
@@ -220,7 +220,7 @@ HRESULT D3DDevice::RestoreDevice()
220 220
221HRESULT D3DDevice::ResetDevice() 221HRESULT D3DDevice::ResetDevice()
222{ 222{
223 Log("reset"); 223 DBG("reset");
224 HRESULT hr = S_OK; 224 HRESULT hr = S_OK;
225 225
226 _scene_rendering = FALSE; 226 _scene_rendering = FALSE;
@@ -243,7 +243,7 @@ HRESULT D3DDevice::ResetDevice()
243 // Reset the device 243 // Reset the device
244 if (FAILED(hr = _device->Reset(&_d3dpp))) 244 if (FAILED(hr = _device->Reset(&_d3dpp)))
245 { 245 {
246 Log("D3DDevice: Reset of the device failed! Error (%X)", (DWORD)hr); 246 ERR("D3DDevice: Reset of the device failed! Error (%X)", (DWORD)hr);
247 return hr; 247 return hr;
248 } 248 }
249 249
@@ -261,13 +261,13 @@ HRESULT D3DDevice::ResetDevice()
261 261
262 if (FAILED(hr)) 262 if (FAILED(hr))
263 { 263 {
264 Log("Restoration of device objects failed"); 264 WRN("Restoration of device objects failed");
265 // Invalidate objects 265 // Invalidate objects
266 266
267 return E_FAIL; 267 return E_FAIL;
268 } 268 }
269 269
270 Log("Device objects were successfuly restored"); 270 DBG("Device objects were successfuly restored");
271 _textures.Set(NULL); 271 _textures.Set(NULL);
272 272
273 //_device_objects_restored = true; 273 //_device_objects_restored = true;
@@ -290,7 +290,7 @@ bool D3DDevice::Begin()
290 HRESULT hr; 290 HRESULT hr;
291 if (FAILED(hr = _device->BeginScene())) 291 if (FAILED(hr = _device->BeginScene()))
292 { 292 {
293 Log("Cannot begin scene: %X", (DWORD)hr); 293 WRN("Cannot begin scene: %X", (DWORD)hr);
294 return false; 294 return false;
295 } 295 }
296 296
@@ -332,7 +332,7 @@ TArray<DWORD> &D3DDevice::GetRenderData()
332 return _render_data; 332 return _render_data;
333 if (FAILED(hr = _device->GetRenderTargetData(surf, _render_target_data))) 333 if (FAILED(hr = _device->GetRenderTargetData(surf, _render_target_data)))
334 { 334 {
335 Log("Failed to get render target data (%X)", (DWORD)hr); 335 WRN("Failed to get render target data (%X)", (DWORD)hr);
336 surf->Release(); 336 surf->Release();
337 return _render_data; 337 return _render_data;
338 } 338 }
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_image_cache.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_image_cache.cpp
index a92ee5bbb7..aa44eb9cb4 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_image_cache.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_image_cache.cpp
@@ -208,7 +208,7 @@ bool D3DImageCache::ResizeImage(D3DDevice *d3d, int nw, int nh, int id)
208 if (FAILED(hr = d3d->GetDevice()->CreateTexture(nw, nh, 0, 0, D3DFMT_A8R8G8B8, 208 if (FAILED(hr = d3d->GetDevice()->CreateTexture(nw, nh, 0, 0, D3DFMT_A8R8G8B8,
209 D3DPOOL_MANAGED, &tex, NULL))) 209 D3DPOOL_MANAGED, &tex, NULL)))
210 { 210 {
211 Log("Failed to create texture: %X", hr); 211 WRN("Failed to create texture: %X", hr);
212 return false; 212 return false;
213 } 213 }
214 assert(tex != NULL); 214 assert(tex != NULL);
@@ -249,7 +249,7 @@ bool D3DImageCache::CreateEntry(D3DDevice *d3d, CacheEntry &entry, int w, int h,
249 if (FAILED(hr = d3d->GetDevice()->CreateTexture(width, height, 0, 0, D3DFMT_A8R8G8B8, 249 if (FAILED(hr = d3d->GetDevice()->CreateTexture(width, height, 0, 0, D3DFMT_A8R8G8B8,
250 D3DPOOL_MANAGED, &entry.texture, NULL))) 250 D3DPOOL_MANAGED, &entry.texture, NULL)))
251 { 251 {
252 Log("Failed to create texture: %X", hr); 252 WRN("Failed to create texture: %X", hr);
253 return false; 253 return false;
254 } 254 }
255 255
@@ -271,7 +271,7 @@ bool D3DImageCache::InsertData(CacheEntry &entry, DWORD *data, int w, int h)
271 D3DLOCKED_RECT lr; 271 D3DLOCKED_RECT lr;
272 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0))) 272 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0)))
273 { 273 {
274 Log("Failed to lock texture"); 274 WRN("Failed to lock texture");
275 return false; 275 return false;
276 } 276 }
277 277
@@ -288,7 +288,7 @@ bool D3DImageCache::InsertData(CacheEntry &entry, DWORD *data, int w, int h)
288 288
289 if (FAILED(entry.texture->UnlockRect(0))) 289 if (FAILED(entry.texture->UnlockRect(0)))
290 { 290 {
291 Log("Failed to unlock texture"); 291 WRN("Failed to unlock texture");
292 return false; 292 return false;
293 } 293 }
294 return true; 294 return true;
@@ -304,7 +304,7 @@ bool D3DImageCache::RetrieveData(CacheEntry &entry, DWORD *data, int w, int h)
304 D3DLOCKED_RECT lr; 304 D3DLOCKED_RECT lr;
305 if (FAILED(entry.texture->LockRect(0, &lr, &rc, D3DLOCK_READONLY))) 305 if (FAILED(entry.texture->LockRect(0, &lr, &rc, D3DLOCK_READONLY)))
306 { 306 {
307 Log("Failed to lock texture"); 307 WRN("Failed to lock texture");
308 return false; 308 return false;
309 } 309 }
310 310
@@ -313,7 +313,7 @@ bool D3DImageCache::RetrieveData(CacheEntry &entry, DWORD *data, int w, int h)
313 313
314 if (FAILED(entry.texture->UnlockRect(0))) 314 if (FAILED(entry.texture->UnlockRect(0)))
315 { 315 {
316 Log("Failed to unlock texture"); 316 WRN("Failed to unlock texture");
317 return false; 317 return false;
318 } 318 }
319 return true; 319 return true;
@@ -349,7 +349,7 @@ bool D3DImageCache::UpdateImageDataWithDirtyInfo(CacheEntryInfo &info, DWORD *da
349 D3DLOCKED_RECT lr; 349 D3DLOCKED_RECT lr;
350 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0))) 350 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0)))
351 { 351 {
352 Log("Failed to lock texture"); 352 WRN("Failed to lock texture");
353 return false; 353 return false;
354 } 354 }
355 355
@@ -386,7 +386,7 @@ bool D3DImageCache::UpdateImageDataWithDirtyInfo(CacheEntryInfo &info, DWORD *da
386 386
387 if (FAILED(entry.texture->UnlockRect(0))) 387 if (FAILED(entry.texture->UnlockRect(0)))
388 { 388 {
389 Log("Failed to unlock texture"); 389 WRN("Failed to unlock texture");
390 return false; 390 return false;
391 } 391 }
392 return true; 392 return true;
@@ -405,7 +405,7 @@ bool D3DImageCache::UpdateImageDataDiscard(CacheEntryInfo &info, DWORD *data)
405 D3DLOCKED_RECT lr; 405 D3DLOCKED_RECT lr;
406 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0))) 406 if (FAILED(entry.texture->LockRect(0, &lr, &rc, 0)))
407 { 407 {
408 Log("Failed to lock texture"); 408 WRN("Failed to lock texture");
409 return false; 409 return false;
410 } 410 }
411 411
@@ -417,7 +417,7 @@ bool D3DImageCache::UpdateImageDataDiscard(CacheEntryInfo &info, DWORD *data)
417 417
418 if (FAILED(entry.texture->UnlockRect(0))) 418 if (FAILED(entry.texture->UnlockRect(0)))
419 { 419 {
420 Log("Failed to unlock texture"); 420 WRN("Failed to unlock texture");
421 return false; 421 return false;
422 } 422 }
423 return true; 423 return true;
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_main.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_main.cpp
index 4af8448250..566cc9ab1f 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_main.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_main.cpp
@@ -83,7 +83,7 @@ bool CreateDIBObjects(DevicePtr *dev_ptr)
83 assert(dev_ptr != NULL); 83 assert(dev_ptr != NULL);
84 if ((dev_ptr->dib.hdc = CreateCompatibleDC(NULL)) == NULL) 84 if ((dev_ptr->dib.hdc = CreateCompatibleDC(NULL)) == NULL)
85 { 85 {
86 Log("Failed to create compatible DC"); 86 WRN("Failed to create compatible DC");
87 return false; 87 return false;
88 } 88 }
89 ZeroMemory(&dev_ptr->dib.info, sizeof(dev_ptr->dib.info)); 89 ZeroMemory(&dev_ptr->dib.info, sizeof(dev_ptr->dib.info));
@@ -96,7 +96,7 @@ bool CreateDIBObjects(DevicePtr *dev_ptr)
96 if ((dev_ptr->dib.image = CreateDIBSection(dev_ptr->dib.hdc, &dev_ptr->dib.info, 96 if ((dev_ptr->dib.image = CreateDIBSection(dev_ptr->dib.hdc, &dev_ptr->dib.info,
97 DIB_RGB_COLORS, (void **)&dev_ptr->dib.data, NULL, 0)) == NULL) 97 DIB_RGB_COLORS, (void **)&dev_ptr->dib.data, NULL, 0)) == NULL)
98 { 98 {
99 Log("Failed to create dib section"); 99 WRN("Failed to create dib section");
100 DeleteDIBObjects(dev_ptr); 100 DeleteDIBObjects(dev_ptr);
101 return false; 101 return false;
102 } 102 }
@@ -122,7 +122,7 @@ Direct3DDeviceHandler evas_direct3d_init(HWND window, int depth, int fullscreen)
122 122
123 if (!D3DShaderPack::Current()->Initialize(device)) 123 if (!D3DShaderPack::Current()->Initialize(device))
124 { 124 {
125 Log("Failed to build shader pack"); 125 ERR("Failed to build shader pack");
126 device->Destroy(); 126 device->Destroy();
127 return NULL; 127 return NULL;
128 } 128 }
@@ -141,7 +141,7 @@ Direct3DDeviceHandler evas_direct3d_init(HWND window, int depth, int fullscreen)
141 if (!D3DImageCache::Current()->CreateImage(device, device->GetWidth(), device->GetHeight(), 141 if (!D3DImageCache::Current()->CreateImage(device, device->GetWidth(), device->GetHeight(),
142 true, info)) 142 true, info))
143 { 143 {
144 Log("Failed to create fonts image buffer"); 144 WRN("Failed to create fonts image buffer");
145 return NULL; 145 return NULL;
146 } 146 }
147 dev_ptr->fonts_buffer_image_id = info.id; 147 dev_ptr->fonts_buffer_image_id = info.id;
@@ -171,7 +171,7 @@ evas_direct3d_free(Direct3DDeviceHandler d3d)
171 dev_ptr->device = NULL; 171 dev_ptr->device = NULL;
172 delete dev_ptr; 172 delete dev_ptr;
173 173
174 Log("uninitialized"); 174 DBG("uninitialized");
175} 175}
176 176
177void 177void
@@ -181,19 +181,19 @@ evas_direct3d_resize(Direct3DDeviceHandler d3d, int width, int height)
181 D3DDevice *device = dev_ptr->device; 181 D3DDevice *device = dev_ptr->device;
182 if (!device->Reset(width, height, -1)) 182 if (!device->Reset(width, height, -1))
183 { 183 {
184 Log("Failed to resize"); 184 ERR("Failed to resize");
185 return; 185 return;
186 } 186 }
187 if (!D3DImageCache::Current()->ResizeImage(device, width, height, 187 if (!D3DImageCache::Current()->ResizeImage(device, width, height,
188 dev_ptr->fonts_buffer_image_id)) 188 dev_ptr->fonts_buffer_image_id))
189 { 189 {
190 Log("Failed to resize fonts image buffer"); 190 WRN("Failed to resize fonts image buffer");
191 } 191 }
192 if (dev_ptr->layered) 192 if (dev_ptr->layered)
193 { 193 {
194 DeleteDIBObjects(dev_ptr); 194 DeleteDIBObjects(dev_ptr);
195 if (!CreateDIBObjects(dev_ptr)) 195 if (!CreateDIBObjects(dev_ptr))
196 Log("Failed to create dib objects"); 196 WRN("Failed to create dib objects");
197 } 197 }
198} 198}
199 199
@@ -210,13 +210,13 @@ evas_direct3d_set_fullscreen(Direct3DDeviceHandler d3d, int width, int height, i
210 210
211 if (!device->Reset(width, height, fullscreen)) 211 if (!device->Reset(width, height, fullscreen))
212 { 212 {
213 Log("Failed to resize"); 213 WRN("Failed to resize");
214 return; 214 return;
215 } 215 }
216 if (!D3DImageCache::Current()->ResizeImage(device, width, height, 216 if (!D3DImageCache::Current()->ResizeImage(device, width, height,
217 dev_ptr->fonts_buffer_image_id)) 217 dev_ptr->fonts_buffer_image_id))
218 { 218 {
219 Log("Failed to resize fonts image buffer"); 219 WRN("Failed to resize fonts image buffer");
220 } 220 }
221 221
222 if (fullscreen == 0) 222 if (fullscreen == 0)
@@ -258,7 +258,7 @@ evas_direct3d_context_set_multiplier(Direct3DDeviceHandler d3d, int r, int g, in
258void 258void
259evas_direct3d_render_all(Direct3DDeviceHandler d3d) 259evas_direct3d_render_all(Direct3DDeviceHandler d3d)
260{ 260{
261 Log("render"); 261 DBG("render");
262 assert(d3d != NULL); 262 assert(d3d != NULL);
263 DevicePtr *dev_ptr = SelectDevice(d3d); 263 DevicePtr *dev_ptr = SelectDevice(d3d);
264 D3DDevice *device = dev_ptr->device; 264 D3DDevice *device = dev_ptr->device;
@@ -349,12 +349,12 @@ void evas_direct3d_line_draw(Direct3DDeviceHandler d3d, int x1, int y1, int x2,
349 { 349 {
350 line = new D3DObjectLine(); 350 line = new D3DObjectLine();
351 scene->AddObject(line); 351 scene->AddObject(line);
352 Log("New line object (total objects: %d)", scene->GetObjectCount()); 352 DBG("New line object (total objects: %d)", scene->GetObjectCount());
353 } 353 }
354 else 354 else
355 { 355 {
356 line->SetFree(false); 356 line->SetFree(false);
357 Log("Line reused (object: %p)", line.Addr()); 357 DBG("Line reused (object: %p)", line.Addr());
358 } 358 }
359 359
360 line->Setup( 360 line->Setup(
@@ -377,12 +377,12 @@ void evas_direct3d_rectangle_draw(Direct3DDeviceHandler d3d, int x, int y, int w
377 { 377 {
378 rect = new D3DObjectRect(); 378 rect = new D3DObjectRect();
379 scene->AddObject(rect); 379 scene->AddObject(rect);
380 Log("New rect object (total objects: %d)", scene->GetObjectCount()); 380 DBG("New rect object (total objects: %d)", scene->GetObjectCount());
381 } 381 }
382 else 382 else
383 { 383 {
384 rect->SetFree(false); 384 rect->SetFree(false);
385 Log("Rect reused (object: %p)", rect.Addr()); 385 DBG("Rect reused (object: %p)", rect.Addr());
386 } 386 }
387 387
388 rect->Setup( 388 rect->Setup(
@@ -403,7 +403,7 @@ Direct3DImageHandler evas_direct3d_image_load(Direct3DDeviceHandler d3d,
403 RGBA_Image *evas_image = evas_common_load_image_from_file(file, key, lo); 403 RGBA_Image *evas_image = evas_common_load_image_from_file(file, key, lo);
404 if (evas_image == NULL) 404 if (evas_image == NULL)
405 { 405 {
406 Log("Failed to load image from %s", file); 406 WRN("Failed to load image from %s", file);
407 return NULL; 407 return NULL;
408 } 408 }
409 int image_width = evas_image->cache_entry.w; 409 int image_width = evas_image->cache_entry.w;
@@ -420,7 +420,7 @@ Direct3DImageHandler evas_direct3d_image_load(Direct3DDeviceHandler d3d,
420 image->SetFree(true); 420 image->SetFree(true);
421 scene->AddObject(image); 421 scene->AddObject(image);
422 422
423 Log("New image object (total objects: %d)", scene->GetObjectCount()); 423 DBG("New image object (total objects: %d)", scene->GetObjectCount());
424 424
425 ImagePtr *ptr = new ImagePtr; 425 ImagePtr *ptr = new ImagePtr;
426 ptr->ref = image; 426 ptr->ref = image;
@@ -447,7 +447,7 @@ Direct3DImageHandler evas_direct3d_image_new_from_data(Direct3DDeviceHandler d3d
447 if (!D3DImageCache::Current()->InsertImage(device, image_data, 447 if (!D3DImageCache::Current()->InsertImage(device, image_data,
448 image_width, image_height, info)) 448 image_width, image_height, info))
449 { 449 {
450 Log("Couldnt add image to the cache"); 450 WRN("Couldnt add image to the cache");
451 return NULL; 451 return NULL;
452 } 452 }
453 char buf[64]; 453 char buf[64];
@@ -458,7 +458,7 @@ Direct3DImageHandler evas_direct3d_image_new_from_data(Direct3DDeviceHandler d3d
458 image->SetFree(true); 458 image->SetFree(true);
459 scene->AddObject(image); 459 scene->AddObject(image);
460 460
461 Log("New image object (total objects: %d)", scene->GetObjectCount()); 461 DBG("New image object (total objects: %d)", scene->GetObjectCount());
462 462
463 ImagePtr *ptr = new ImagePtr; 463 ImagePtr *ptr = new ImagePtr;
464 ptr->ref = image; 464 ptr->ref = image;
@@ -498,7 +498,7 @@ void evas_direct3d_image_data_put(Direct3DDeviceHandler d3d, Direct3DImageHandle
498 return; 498 return;
499 499
500 if (!image_ref->UpdateImageData(image_data)) 500 if (!image_ref->UpdateImageData(image_data))
501 Log("Failed to update image data"); 501 ERR("Failed to update image data");
502} 502}
503 503
504void evas_direct3d_image_data_get(Direct3DDeviceHandler d3d, Direct3DImageHandler image, 504void evas_direct3d_image_data_get(Direct3DDeviceHandler d3d, Direct3DImageHandler image,
@@ -540,7 +540,7 @@ void evas_direct3d_image_draw(Direct3DDeviceHandler d3d, Direct3DImageHandler im
540 { 540 {
541 images[i]->CopyTo(image_ref); 541 images[i]->CopyTo(image_ref);
542 found = true; 542 found = true;
543 Log("Image object info reused, source: \"%s\"", image_ref->GetSource()); 543 WRN("Image object info reused, source: \"%s\"", image_ref->GetSource());
544 break; 544 break;
545 } 545 }
546 } 546 }
@@ -556,7 +556,7 @@ void evas_direct3d_image_draw(Direct3DDeviceHandler d3d, Direct3DImageHandler im
556 if (!D3DImageCache::Current()->InsertImage(device, (DWORD *)evas_image->image.data, 556 if (!D3DImageCache::Current()->InsertImage(device, (DWORD *)evas_image->image.data,
557 evas_image->cache_entry.w, evas_image->cache_entry.h, info)) 557 evas_image->cache_entry.w, evas_image->cache_entry.h, info))
558 { 558 {
559 Log("Couldnt add image to the cache"); 559 WRN("Couldnt add image to the cache");
560 return; 560 return;
561 } 561 }
562 image_ref->Init(info.u, info.v, info.du, info.dv, info.id, 562 image_ref->Init(info.u, info.v, info.du, info.dv, info.id,
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_font.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_font.cpp
index 7730f7c8e4..f072e87523 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_font.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_font.cpp
@@ -113,7 +113,7 @@ D3DObjectFont::Glyph *D3DObjectFont::GetGlyph(void *source)
113{ 113{
114 if (_image_id < 0) 114 if (_image_id < 0)
115 { 115 {
116 Log("Font is not initialized"); 116 WRN("Font is not initialized");
117 return NULL; 117 return NULL;
118 } 118 }
119 for (int i = 0; i < _glyphs.Length(); i++) 119 for (int i = 0; i < _glyphs.Length(); i++)
@@ -129,7 +129,7 @@ D3DObjectFont::Glyph *D3DObjectFont::AddGlyph(D3DDevice *d3d, void *source,
129{ 129{
130 if (_image_id < 0) 130 if (_image_id < 0)
131 { 131 {
132 Log("Font is not initialized"); 132 WRN("Font is not initialized");
133 return NULL; 133 return NULL;
134 } 134 }
135 for (int i = 0; i < _glyphs.Length(); i++) 135 for (int i = 0; i < _glyphs.Length(); i++)
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_image.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_image.cpp
index 3bf2f38261..3bfbe1e565 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_image.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_image.cpp
@@ -139,7 +139,7 @@ void D3DObjectImage::EndCache(D3DDevice *d3d)
139 cur += groups[i].num * 6; 139 cur += groups[i].num * 6;
140 } 140 }
141 141
142 Log("Image cache drawn: %d items, %d groups", _cache.Length(), groups.Length()); 142 DBG("Image cache drawn: %d items, %d groups", _cache.Length(), groups.Length());
143 _cache_enabled = false; 143 _cache_enabled = false;
144} 144}
145 145
@@ -147,7 +147,7 @@ void D3DObjectImage::Draw(D3DDevice *d3d)
147{ 147{
148 _dirty = false; 148 _dirty = false;
149 149
150 Log("Image draw: (%.3f, %.3f, %.3f, %.3f)", _x, _y, _w, _h); 150 DBG("Image draw: (%.3f, %.3f, %.3f, %.3f)", _x, _y, _w, _h);
151 151
152 if (_cache_enabled) 152 if (_cache_enabled)
153 { 153 {
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_line.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_line.cpp
index 5c0f774ef4..9442243ab5 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_line.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_line.cpp
@@ -28,7 +28,7 @@ void D3DObjectLine::EndCache(D3DDevice *d3d)
28 d3d->GetDevice()->DrawPrimitiveUP(D3DPT_LINELIST, _cache.Length() / 2, 28 d3d->GetDevice()->DrawPrimitiveUP(D3DPT_LINELIST, _cache.Length() / 2,
29 _cache.Data(), sizeof(Vertex)); 29 _cache.Data(), sizeof(Vertex));
30 30
31 Log("Line cache drawn: %d items", _cache.Length() / 2); 31 DBG("Line cache drawn: %d items", _cache.Length() / 2);
32 _cache_enabled = false; 32 _cache_enabled = false;
33} 33}
34 34
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_rect.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_rect.cpp
index f37e28ebcc..ebdd22be95 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_rect.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_object_rect.cpp
@@ -27,7 +27,7 @@ void D3DObjectRect::EndCache(D3DDevice *d3d)
27 d3d->GetDevice()->DrawPrimitiveUP(D3DPT_TRIANGLELIST, _cache.Length() / 3, 27 d3d->GetDevice()->DrawPrimitiveUP(D3DPT_TRIANGLELIST, _cache.Length() / 3,
28 _cache.Data(), sizeof(Vertex)); 28 _cache.Data(), sizeof(Vertex));
29 29
30 Log("Rect cache drawn: %d items", _cache.Length() / 6); 30 DBG("Rect cache drawn: %d items", _cache.Length() / 6);
31 _cache_enabled = false; 31 _cache_enabled = false;
32} 32}
33 33
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_shader_pack.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_shader_pack.cpp
index 6d7a789b93..d9c868f9b6 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_shader_pack.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_shader_pack.cpp
@@ -34,11 +34,11 @@ bool D3DShaderPack::Initialize(D3DDevice *d3d)
34{ 34{
35 bool res = true; 35 bool res = true;
36 if (!(res = InitVertexDeclarations(d3d) && res)) 36 if (!(res = InitVertexDeclarations(d3d) && res))
37 Log("Failed to create vdecl set"); 37 WRN("Failed to create vdecl set");
38 if (!(res = InitVertexShaders(d3d) && res)) 38 if (!(res = InitVertexShaders(d3d) && res))
39 Log("Failed to create vs set"); 39 WRN("Failed to create vs set");
40 if (!(res = InitPixelShaders(d3d) && res)) 40 if (!(res = InitPixelShaders(d3d) && res))
41 Log("Failed to create ps set"); 41 WRN("Failed to create ps set");
42 return res; 42 return res;
43} 43}
44 44
@@ -280,11 +280,11 @@ void *D3DShaderPack::CompileShader(D3DDevice *d3d, bool make_vs,
280 280
281 if (FAILED(res)) 281 if (FAILED(res))
282 { 282 {
283 Log("Shader %s compilation failed, code = %X", name, res); 283 ERR("Shader %s compilation failed, code = %X", name, res);
284 if (error_msgs == NULL) 284 if (error_msgs == NULL)
285 return NULL; 285 return NULL;
286 const char *mess = (const char *)error_msgs->GetBufferPointer(); 286 const char *mess = (const char *)error_msgs->GetBufferPointer();
287 Log("Error output:\n%s", mess); 287 ERR("Error output:\n%s", mess);
288 error_msgs->Release(); 288 error_msgs->Release();
289 return NULL; 289 return NULL;
290 } 290 }
@@ -310,7 +310,7 @@ void *D3DShaderPack::CompileShader(D3DDevice *d3d, bool make_vs,
310 310
311 if (FAILED(res)) 311 if (FAILED(res))
312 { 312 {
313 Log("Shader %s creation failed, code = %X", name, res); 313 WRN("Shader %s creation failed, code = %X", name, res);
314 return NULL; 314 return NULL;
315 } 315 }
316 return res_ptr; 316 return res_ptr;
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_vertex_buffer_cache.cpp b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_vertex_buffer_cache.cpp
index 5b5da7b977..8d3dd451ac 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_direct3d_vertex_buffer_cache.cpp
+++ b/legacy/evas/src/modules/engines/direct3d/evas_direct3d_vertex_buffer_cache.cpp
@@ -64,7 +64,7 @@ bool D3DVertexBufferCache::InitBuffer(D3DDevice *d3d, BYTE *data, int size, Cach
64 CacheEntry new_entry; 64 CacheEntry new_entry;
65 if (!CreateEntry(d3d, new_entry, size)) 65 if (!CreateEntry(d3d, new_entry, size))
66 { 66 {
67 Log("Failed to create new vbcache entry"); 67 WRN("Failed to create new vbcache entry");
68 return false; 68 return false;
69 } 69 }
70 _cache.Add(new_entry); 70 _cache.Add(new_entry);
@@ -80,7 +80,7 @@ bool D3DVertexBufferCache::InitBuffer(D3DDevice *d3d, BYTE *data, int size, Cach
80 assert(ce != NULL); 80 assert(ce != NULL);
81 if (!InsertData(*ce, data, size)) 81 if (!InsertData(*ce, data, size))
82 { 82 {
83 Log("Failed to insert vbcache data"); 83 WRN("Failed to insert vbcache data");
84 return false; 84 return false;
85 } 85 }
86 return true; 86 return true;
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_engine.c b/legacy/evas/src/modules/engines/direct3d/evas_engine.c
index 736d3b7e96..35d06837e7 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_engine.c
+++ b/legacy/evas/src/modules/engines/direct3d/evas_engine.c
@@ -15,6 +15,7 @@ struct _Render_Engine
15 int in_redraw : 1; 15 int in_redraw : 1;
16}; 16};
17 17
18int _evas_engine_direct3d_log_dom = -1;
18 19
19/* function tables - filled in later (func and parent func) */ 20/* function tables - filled in later (func and parent func) */
20static Evas_Func func, pfunc; 21static Evas_Func func, pfunc;
@@ -55,7 +56,7 @@ _output_setup(int width, int height, int rotation, HWND window, int depth, int f
55 evas_common_font_init(); 56 evas_common_font_init();
56 evas_common_draw_init(); 57 evas_common_draw_init();
57 evas_common_tilebuf_init(); 58 evas_common_tilebuf_init();
58 59
59 if ((re->d3d = evas_direct3d_init(window, depth, fullscreen)) == 0) 60 if ((re->d3d = evas_direct3d_init(window, depth, fullscreen)) == 0)
60 { 61 {
61 free(re); 62 free(re);
@@ -93,8 +94,7 @@ eng_setup(Evas *e, void *info)
93{ 94{
94 Render_Engine *re; 95 Render_Engine *re;
95 Evas_Engine_Info_Direct3D *in; 96 Evas_Engine_Info_Direct3D *in;
96 re = (Render_Engine *)e->engine.data.output; 97 re = (Render_Engine *)e->engine.data.output;
97
98 in = (Evas_Engine_Info_Direct3D *)info; 98 in = (Evas_Engine_Info_Direct3D *)info;
99 if (e->engine.data.output == NULL) 99 if (e->engine.data.output == NULL)
100 { 100 {
@@ -533,6 +533,13 @@ module_open(Evas_Module *em)
533 if (!em) return 0; 533 if (!em) return 0;
534 /* get whatever engine module we inherit from */ 534 /* get whatever engine module we inherit from */
535 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0; 535 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0;
536 /* Initialize the log domain */
537 _evas_engine_direct3d_log_dom = eina_log_domain_register("EvasDirect3D", EVAS_DEFAULT_LOG_COLOR);
538 if(_evas_engine_direct3d_log_dom < 0)
539 {
540 EINA_LOG_ERR("Impossible to create a log domain for the Direct3D engine.\n");
541 return 0;
542 }
536 /* store it for later use */ 543 /* store it for later use */
537 func = pfunc; 544 func = pfunc;
538 /* now to override methods */ 545 /* now to override methods */
@@ -603,6 +610,7 @@ module_open(Evas_Module *em)
603static void 610static void
604module_close(Evas_Module *em) 611module_close(Evas_Module *em)
605{ 612{
613 eina_log_domain_unregister(_evas_engine_direct3d_log_dom);
606} 614}
607 615
608static Evas_Module_Api evas_modapi = 616static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/direct3d/evas_engine.h b/legacy/evas/src/modules/engines/direct3d/evas_engine.h
index 6257227066..da1ebff1d7 100644
--- a/legacy/evas/src/modules/engines/direct3d/evas_engine.h
+++ b/legacy/evas/src/modules/engines/direct3d/evas_engine.h
@@ -14,15 +14,42 @@ extern "C" {
14#define EVAS_INLINE_ARRAY_H // We dont need that and it is buggy 14#define EVAS_INLINE_ARRAY_H // We dont need that and it is buggy
15 15
16#include "evas_common.h" 16#include "evas_common.h"
17#include "evas_private.h"
18 17
19#ifdef __cplusplus 18#ifdef __cplusplus
20} 19}
21#endif 20#endif
22 21
22
23//#define ENABLE_LOG_PRINTF 23//#define ENABLE_LOG_PRINTF
24
25extern int _evas_engine_direct3d_log_dom ;
26#ifdef ERR
27# undef ERR
28#endif
29#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_direct3d_log_dom, __VA_ARGS__)
30
31#ifdef DBG
32# undef DBG
33#endif
34#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_direct3d_log_dom, __VA_ARGS__)
35
36#ifdef INF
37# undef INF
38#endif
39#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_direct3d_log_dom, __VA_ARGS__)
40
41#ifdef WRN
42# undef WRN
43#endif
44#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_direct3d_log_dom, __VA_ARGS__)
45
46#ifdef CRIT
47# undef CRIT
48#endif
49#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_direct3d_log_dom, __VA_ARGS__)
50
24#ifdef ENABLE_LOG_PRINTF 51#ifdef ENABLE_LOG_PRINTF
25#define Log(str, ...) INFO("D3D "str, __VA_ARGS__) 52#define Log(str, ...) INF("D3D "str, __VA_ARGS__)
26#else 53#else
27#define Log(str, ...) 54#define Log(str, ...)
28#endif 55#endif
@@ -31,6 +58,7 @@ typedef void * Direct3DDeviceHandler;
31typedef void * Direct3DImageHandler; 58typedef void * Direct3DImageHandler;
32typedef void * Direct3DFontGlyphHandler; 59typedef void * Direct3DFontGlyphHandler;
33 60
61
34#ifdef __cplusplus 62#ifdef __cplusplus
35extern "C" { 63extern "C" {
36#endif 64#endif
diff --git a/legacy/evas/src/modules/engines/directfb/evas_engine.c b/legacy/evas/src/modules/engines/directfb/evas_engine.c
index aa91d4881f..ed7bf8cf12 100644
--- a/legacy/evas/src/modules/engines/directfb/evas_engine.c
+++ b/legacy/evas/src/modules/engines/directfb/evas_engine.c
@@ -17,6 +17,7 @@
17//#define DFB_DEBUG_IMAGE 1 17//#define DFB_DEBUG_IMAGE 1
18//#define DFB_DEBUG_FLAGS 1 18//#define DFB_DEBUG_FLAGS 1
19//#define DFB_DEBUG_ACCELERATION 1 19//#define DFB_DEBUG_ACCELERATION 1
20int _evas_engine_directfb_log_dom = -1;
20 21
21static Evas_Func func = {}; 22static Evas_Func func = {};
22static Evas_Func parent_func = {}; 23static Evas_Func parent_func = {};
@@ -69,7 +70,7 @@ _dfb_surface_clear(IDirectFBSurface *surface, int x, int y, int w, int h)
69 return; 70 return;
70 71
71 error: 72 error:
72 ERROR("DirectFB: could not clear surface: %s", 73 ERR("DirectFB: could not clear surface: %s",
73 DirectFBErrorString(r)); 74 DirectFBErrorString(r));
74} 75}
75 76
@@ -93,7 +94,7 @@ _image_autoset_alpha(DirectFB_Engine_Image_Entry *image)
93 r = surface->GetPixelFormat(surface, &fmt); 94 r = surface->GetPixelFormat(surface, &fmt);
94 if (r != DFB_OK) 95 if (r != DFB_OK)
95 { 96 {
96 ERROR("DirectFB: could not get pixel format: %s", 97 ERR("Could not get pixel format: %s",
97 DirectFBErrorString(r)); 98 DirectFBErrorString(r));
98 return; 99 return;
99 } 100 }
@@ -114,7 +115,7 @@ _dfb_surface_update(IDirectFBSurface *surface, int x, int y, int w, int h)
114 cr.y2 = y + h - 1; 115 cr.y2 = y + h - 1;
115 r = surface->Flip(surface, &cr, DSFLIP_NONE); 116 r = surface->Flip(surface, &cr, DSFLIP_NONE);
116 if (r != DFB_OK) 117 if (r != DFB_OK)
117 WARN("DirectFB: could not update surface: %s", 118 WRN("Could not update surface: %s",
118 DirectFBErrorString(r)); 119 DirectFBErrorString(r));
119} 120}
120 121
@@ -138,8 +139,8 @@ _dfb_surface_from_data(IDirectFB *dfb, int w, int h, void *data)
138 r = dfb->CreateSurface(dfb, &desc, &s); 139 r = dfb->CreateSurface(dfb, &desc, &s);
139 if (r != DFB_OK) 140 if (r != DFB_OK)
140 { 141 {
141 ERROR("DirectFB: cannot create DirectFB surface: %s", 142 ERR("Cannot create DirectFB surface: %s",
142 DirectFBErrorString(r)); 143 DirectFBErrorString(r));
143 return NULL; 144 return NULL;
144 } 145 }
145 146
@@ -165,14 +166,14 @@ _dfb_blit_accel_caps_print(IDirectFBSurface *dst, IDirectFBSurface *src)
165 r = dst->GetAccelerationMask(dst, src, &mask); 166 r = dst->GetAccelerationMask(dst, src, &mask);
166 if (r != DFB_OK) 167 if (r != DFB_OK)
167 { 168 {
168 ERROR("DirectFB: Could not retrieve acceleration mask: %s", 169 ERR("Could not retrieve acceleration mask: %s",
169 DirectFBErrorString(r)); 170 DirectFBErrorString(r));
170 return; 171 return;
171 } 172 }
172 173
173 DEBUG("Acceleration: "); 174 DBG("Acceleration: ");
174 175
175#define O(m) if (mask & m) DEBUG(#m " ") 176#define O(m) if (mask & m) DBG(#m " ")
176 O(DFXL_FILLRECTANGLE); 177 O(DFXL_FILLRECTANGLE);
177 O(DFXL_DRAWRECTANGLE); 178 O(DFXL_DRAWRECTANGLE);
178 O(DFXL_DRAWLINE); 179 O(DFXL_DRAWLINE);
@@ -183,7 +184,7 @@ _dfb_blit_accel_caps_print(IDirectFBSurface *dst, IDirectFBSurface *src)
183 O(DFXL_DRAWSTRING); 184 O(DFXL_DRAWSTRING);
184#undef O 185#undef O
185 186
186 if (mask == DFXL_NONE) DEBUG("<NONE>"); 187 if (mask == DFXL_NONE) DBG("<NONE>");
187#endif /* DFB_DEBUG_ACCELERATION */ 188#endif /* DFB_DEBUG_ACCELERATION */
188} 189}
189 190
@@ -299,14 +300,14 @@ _dfb_surface_set_color_from_context(IDirectFBSurface *surface, RGBA_Draw_Context
299 goto error; 300 goto error;
300 301
301#ifdef DFB_DEBUG_FLAGS 302#ifdef DFB_DEBUG_FLAGS
302 DEBUG("DirectFB DRAW: color=%d %d %d %d, flags=%s", 303 DBG("Color=%d %d %d %d, flags=%s",
303 r, g, b, a, _dfb_draw_flags_str(flags)); 304 r, g, b, a, _dfb_draw_flags_str(flags));
304#endif /* DFB_DEBUG_FLAGS */ 305#endif /* DFB_DEBUG_FLAGS */
305 306
306 return 1; 307 return 1;
307 308
308 error: 309 error:
309 ERROR("DirectFB: could not set color from context: %s", 310 ERR("Could not set color from context: %s",
310 DirectFBErrorString(res)); 311 DirectFBErrorString(res));
311 return 0; 312 return 0;
312} 313}
@@ -353,7 +354,7 @@ _dfb_surface_set_blit_params(DirectFB_Engine_Image_Entry *d, DirectFB_Engine_Ima
353 goto error; 354 goto error;
354 355
355#ifdef DFB_DEBUG_FLAGS 356#ifdef DFB_DEBUG_FLAGS
356 DEBUG("DirectFB BLIT: sfunc=%s, dfunc=%s, color=%d %d %d %d\n\tblit=%s\n\tdraw=%s", 357 DBG("sfunc=%s, dfunc=%s, color=%d %d %d %d\n\tblit=%s\n\tdraw=%s",
357 _dfb_blend_func_str(src_func), _dfb_blend_func_str(dst_func), 358 _dfb_blend_func_str(src_func), _dfb_blend_func_str(dst_func),
358 r, g, b, a, 359 r, g, b, a,
359 _dfb_blit_flags_str(blit_flags), _dfb_draw_flags_str(draw_flags)); 360 _dfb_blit_flags_str(blit_flags), _dfb_draw_flags_str(draw_flags));
@@ -362,7 +363,7 @@ _dfb_surface_set_blit_params(DirectFB_Engine_Image_Entry *d, DirectFB_Engine_Ima
362 return 1; 363 return 1;
363 364
364 error: 365 error:
365 ERROR("DirectFB: Could not set blit params: %s", 366 ERR("Could not set blit params: %s",
366 DirectFBErrorString(res)); 367 DirectFBErrorString(res));
367 return 0; 368 return 0;
368} 369}
@@ -385,7 +386,7 @@ _dfb_lock_and_sync_image(IDirectFBSurface *surface, RGBA_Image *image, DFBSurfac
385 if (pitch != (sw * 4)) 386 if (pitch != (sw * 4))
386 { 387 {
387 /* XXX TODO: support other pixel formats. */ 388 /* XXX TODO: support other pixel formats. */
388 ERROR("DirectFB: IDirectFBSurface pitch(%d) is not supported: " 389 ERR("IDirectFBSurface pitch(%d) is not supported: "
389 "should be %d.", 390 "should be %d.",
390 pitch, sw * 4); 391 pitch, sw * 4);
391 surface->Unlock(surface); 392 surface->Unlock(surface);
@@ -611,7 +612,7 @@ evas_cache_image_dfb_mem_size_get(Engine_Image_Entry *eie)
611 r = deie->surface->GetSize(deie->surface, &w, &h); 612 r = deie->surface->GetSize(deie->surface, &w, &h);
612 if (r != DFB_OK) 613 if (r != DFB_OK)
613 { 614 {
614 ERROR("DirectFB: Could not get surface size: %s", 615 ERR("Could not get surface size: %s",
615 DirectFBErrorString(r)); 616 DirectFBErrorString(r));
616 return size; 617 return size;
617 } 618 }
@@ -627,10 +628,10 @@ evas_cache_image_dfb_debug(const char *context, Engine_Image_Entry* eie)
627{ 628{
628 DirectFB_Engine_Image_Entry *eim = (DirectFB_Engine_Image_Entry *)eie; 629 DirectFB_Engine_Image_Entry *eim = (DirectFB_Engine_Image_Entry *)eie;
629 630
630 DEBUG("*** %s image (%p) ***", context, eim); 631 DBG("*** %s image (%p) ***", context, eim);
631 if (eim) 632 if (eim)
632 { 633 {
633 DEBUG("* W: %d\n" 634 DBG("* W: %d\n"
634 "* H: %d\n" 635 "* H: %d\n"
635 "* R: %d\n" 636 "* R: %d\n"
636 "* Key: %s\n" 637 "* Key: %s\n"
@@ -638,9 +639,9 @@ evas_cache_image_dfb_debug(const char *context, Engine_Image_Entry* eie)
638 eie->w, eie->h, eie->references, eie->cache_key, eim->surface); 639 eie->w, eie->h, eie->references, eie->cache_key, eim->surface);
639 640
640 if (eie->src) 641 if (eie->src)
641 DEBUG("* Pixels: %p", ((RGBA_Image*) eie->src)->image.data); 642 DBG("* Pixels: %p", ((RGBA_Image*) eie->src)->image.data);
642 } 643 }
643 DEBUG("*** ***"); 644 DBG("*** ***");
644} 645}
645#endif 646#endif
646 647
@@ -671,13 +672,10 @@ static void *
671evas_engine_dfb_info(Evas* e __UNUSED__) 672evas_engine_dfb_info(Evas* e __UNUSED__)
672{ 673{
673 Evas_Engine_Info_DirectFB *info; 674 Evas_Engine_Info_DirectFB *info;
674
675 info = calloc(1, sizeof(Evas_Engine_Info_DirectFB)); 675 info = calloc(1, sizeof(Evas_Engine_Info_DirectFB));
676 if (!info) 676 if (!info)
677 return NULL; 677 return NULL;
678
679 info->magic.magic = rand(); 678 info->magic.magic = rand();
680
681 return info; 679 return info;
682} 680}
683 681
@@ -685,7 +683,6 @@ static void
685evas_engine_dfb_info_free(Evas *e __UNUSED__, void *in) 683evas_engine_dfb_info_free(Evas *e __UNUSED__, void *in)
686{ 684{
687 Evas_Engine_Info_DirectFB *info = in; 685 Evas_Engine_Info_DirectFB *info = in;
688
689 free(info); 686 free(info);
690} 687}
691 688
@@ -697,28 +694,28 @@ _is_dfb_data_ok(IDirectFB *idfb, IDirectFBSurface *surface, int w, int h)
697 694
698 if (!idfb) 695 if (!idfb)
699 { 696 {
700 ERROR("missing IDirectFB"); 697 ERR("missing IDirectFB");
701 return EINA_FALSE; 698 return EINA_FALSE;
702 } 699 }
703 dfb = idfb; 700 dfb = idfb;
704 701
705 if (!surface) 702 if (!surface)
706 { 703 {
707 ERROR("missing IDirectFBSurface"); 704 ERR("missing IDirectFBSurface");
708 return EINA_FALSE; 705 return EINA_FALSE;
709 } 706 }
710 707
711 r = surface->GetSize(surface, &sw, &sh); 708 r = surface->GetSize(surface, &sw, &sh);
712 if (r != DFB_OK) 709 if (r != DFB_OK)
713 { 710 {
714 ERROR("DirectFB: could not get surface %p size: %s", 711 ERR("Could not get surface %p size: %s",
715 surface, DirectFBErrorString(r)); 712 surface, DirectFBErrorString(r));
716 return EINA_FALSE; 713 return EINA_FALSE;
717 } 714 }
718 715
719 if ((w > sw) || (h > sh)) 716 if ((w > sw) || (h > sh))
720 { 717 {
721 ERROR("DirectFB: requested size is larger than surface: %dx%d > %dx%d", 718 ERR("Requested size is larger than surface: %dx%d > %dx%d",
722 w, h, sw, sh); 719 w, h, sw, sh);
723 return EINA_FALSE; 720 return EINA_FALSE;
724 } 721 }
@@ -760,7 +757,7 @@ evas_engine_dfb_output_reconfigure(Render_Engine *re, int w, int h)
760 re->tb = evas_common_tilebuf_new(w, h); 757 re->tb = evas_common_tilebuf_new(w, h);
761 if (!re->tb) 758 if (!re->tb)
762 { 759 {
763 ERROR("DirectFB: could not allocate tile buffer."); 760 ERR("Could not allocate tile buffer.");
764 goto failed_tilebuf; 761 goto failed_tilebuf;
765 } 762 }
766 evas_common_tilebuf_set_tile_size(re->tb, TILESIZE, TILESIZE); 763 evas_common_tilebuf_set_tile_size(re->tb, TILESIZE, TILESIZE);
@@ -773,7 +770,7 @@ evas_engine_dfb_output_reconfigure(Render_Engine *re, int w, int h)
773 evas_cache_engine_image_engine(re->cache, re->spec->surface); 770 evas_cache_engine_image_engine(re->cache, re->spec->surface);
774 if (!re->screen_image) 771 if (!re->screen_image)
775 { 772 {
776 ERROR("DirectFB: RGBA_Image allocation from DFB failed"); 773 ERR("RGBA_Image allocation from DFB failed");
777 goto failed_image; 774 goto failed_image;
778 } 775 }
779 re->screen_image->flags.engine_surface = 1; 776 re->screen_image->flags.engine_surface = 1;
@@ -788,7 +785,7 @@ evas_engine_dfb_output_reconfigure(Render_Engine *re, int w, int h)
788 re->tb = NULL; 785 re->tb = NULL;
789 failed_tilebuf: 786 failed_tilebuf:
790 re->screen_image = NULL; 787 re->screen_image = NULL;
791 ERROR("DirectFB: Evas DirectFB reconfigure failed"); 788 ERR("Evas DirectFB reconfigure failed");
792 return 0; 789 return 0;
793} 790}
794 791
@@ -814,13 +811,13 @@ _dfb_output_setup(int w, int h, const struct Evas_Engine_DirectFB_Spec *spec)
814 evas_common_image_cache_get()); 811 evas_common_image_cache_get());
815 if (!re->cache) 812 if (!re->cache)
816 { 813 {
817 ERROR("DirectFB: Evas_Cache_Engine_Image allocation failed!"); 814 ERR("Evas_Cache_Engine_Image allocation failed!");
818 goto fatal_after_engine; 815 goto fatal_after_engine;
819 } 816 }
820 817
821 if (!evas_engine_dfb_output_reconfigure(re, w, h)) 818 if (!evas_engine_dfb_output_reconfigure(re, w, h))
822 { 819 {
823 ERROR("DirectFB: Could not reconfigure evas engine."); 820 ERR("Could not reconfigure evas engine.");
824 goto fatal_after_reconfigure; 821 goto fatal_after_reconfigure;
825 } 822 }
826 823
@@ -834,7 +831,7 @@ _dfb_output_setup(int w, int h, const struct Evas_Engine_DirectFB_Spec *spec)
834 fatal_after_engine: 831 fatal_after_engine:
835 free(re); 832 free(re);
836 fatal: 833 fatal:
837 CRITICAL("DirectFB: unable to continue, abort()!"); 834 CRIT("DirectFB: unable to continue, abort()!");
838 abort(); 835 abort();
839 return NULL; 836 return NULL;
840} 837}
@@ -882,7 +879,7 @@ static void
882evas_engine_dfb_output_resize(void *data, int w, int h) 879evas_engine_dfb_output_resize(void *data, int w, int h)
883{ 880{
884 if (!evas_engine_dfb_output_reconfigure(data, w, h)) 881 if (!evas_engine_dfb_output_reconfigure(data, w, h))
885 ERROR("DirectFB: failed to resize DirectFB evas"); 882 ERR("Failed to resize DirectFB evas");
886} 883}
887 884
888static void 885static void
@@ -1026,7 +1023,7 @@ evas_engine_dfb_output_idle_flush(void *data)
1026 Render_Engine *re = data; 1023 Render_Engine *re = data;
1027 1024
1028 if (re->update_regions_count != 0) 1025 if (re->update_regions_count != 0)
1029 ERROR("DirectFB: update_regions_count not 0 as it should be!"); 1026 ERR("update_regions_count not 0 as it should be!");
1030 1027
1031 free(re->update_regions); 1028 free(re->update_regions);
1032 re->update_regions_count = 0; 1029 re->update_regions_count = 0;
@@ -1346,7 +1343,7 @@ evas_engine_dfb_image_data_get(void *data __UNUSED__, void *image, int to_write,
1346 break; 1343 break;
1347 1344
1348 error: 1345 error:
1349 ERROR("DirectFB: could not lock surface %p: %s", 1346 ERR("Could not lock surface %p: %s",
1350 s, DirectFBErrorString(r)); 1347 s, DirectFBErrorString(r));
1351 *image_data = NULL; 1348 *image_data = NULL;
1352 break; 1349 break;
@@ -1631,6 +1628,12 @@ module_open(Evas_Module *em)
1631 if (!em) return 0; 1628 if (!em) return 0;
1632 /* get whatever engine module we inherit from */ 1629 /* get whatever engine module we inherit from */
1633 if (!_evas_module_engine_inherit(&parent_func, "software_generic")) return 0; 1630 if (!_evas_module_engine_inherit(&parent_func, "software_generic")) return 0;
1631 _evas_engine_directfb_log_dom = eina_log_domain_register("EvasEngineDirectFB",EVAS_DEFAULT_COLOR);
1632 if(_evas_engine_directfb_log_dom < 0)
1633 {
1634 EINA_LOG_ERR("Impossible to create a log domain for the DirectFb engine.\n");
1635 return 0;
1636 }
1634 /* store it for later use */ 1637 /* store it for later use */
1635 func = parent_func; 1638 func = parent_func;
1636 /* now to override methods */ 1639 /* now to override methods */
@@ -1684,6 +1687,7 @@ module_open(Evas_Module *em)
1684static void 1687static void
1685module_close(Evas_Module *em) 1688module_close(Evas_Module *em)
1686{ 1689{
1690 eina_log_domain_unregister(_evas_engine_directfb_log_dom);
1687} 1691}
1688 1692
1689static Evas_Module_Api evas_modapi = 1693static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/directfb/evas_engine.h b/legacy/evas/src/modules/engines/directfb/evas_engine.h
index dff4a1f9d2..a8d8357e1c 100644
--- a/legacy/evas/src/modules/engines/directfb/evas_engine.h
+++ b/legacy/evas/src/modules/engines/directfb/evas_engine.h
@@ -5,6 +5,33 @@
5#include "evas_private.h" 5#include "evas_private.h"
6#include "Evas_Engine_DirectFB.h" 6#include "Evas_Engine_DirectFB.h"
7 7
8extern int _evas_engine_directfb_log_dom ;
9
10#ifdef ERR
11# undef ERR
12#endif
13#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_directfb_log_dom, __VA_ARGS__)
14
15#ifdef DBG
16# undef DBG
17#endif
18#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_directfb_log_dom, __VA_ARGS__)
19
20#ifdef INF
21# undef INF
22#endif
23#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_directfb_log_dom, __VA_ARGS__)
24
25#ifdef WRN
26# undef WRN
27#endif
28#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_directfb_log_dom, __VA_ARGS__)
29
30#ifdef CRIT
31# undef CRIT
32#endif
33#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_directfb_log_dom, __VA_ARGS__)
34
8typedef struct _DirectFB_Engine_Image_Entry DirectFB_Engine_Image_Entry; 35typedef struct _DirectFB_Engine_Image_Entry DirectFB_Engine_Image_Entry;
9struct _DirectFB_Engine_Image_Entry 36struct _DirectFB_Engine_Image_Entry
10{ 37{
diff --git a/legacy/evas/src/modules/engines/fb/evas_engine.c b/legacy/evas/src/modules/engines/fb/evas_engine.c
index 17e5c011c9..43d1a4a91c 100644
--- a/legacy/evas/src/modules/engines/fb/evas_engine.c
+++ b/legacy/evas/src/modules/engines/fb/evas_engine.c
@@ -3,6 +3,8 @@
3#include "evas_engine.h" 3#include "evas_engine.h"
4#include "Evas_Engine_FB.h" 4#include "Evas_Engine_FB.h"
5 5
6int _evas_engine_fb_log_dom = -1;
7
6/* function tables - filled in later (func and parent func) */ 8/* function tables - filled in later (func and parent func) */
7static Evas_Func func, pfunc; 9static Evas_Func func, pfunc;
8 10
@@ -76,7 +78,6 @@ static void *
76eng_info(Evas *e) 78eng_info(Evas *e)
77{ 79{
78 Evas_Engine_Info_FB *info; 80 Evas_Engine_Info_FB *info;
79
80 info = calloc(1, sizeof(Evas_Engine_Info_FB)); 81 info = calloc(1, sizeof(Evas_Engine_Info_FB));
81 if (!info) return NULL; 82 if (!info) return NULL;
82 info->magic.magic = rand(); 83 info->magic.magic = rand();
@@ -88,7 +89,6 @@ static void
88eng_info_free(Evas *e __UNUSED__, void *info) 89eng_info_free(Evas *e __UNUSED__, void *info)
89{ 90{
90 Evas_Engine_Info_FB *in; 91 Evas_Engine_Info_FB *in;
91
92 in = (Evas_Engine_Info_FB *)info; 92 in = (Evas_Engine_Info_FB *)info;
93 free(in); 93 free(in);
94} 94}
@@ -263,6 +263,12 @@ module_open(Evas_Module *em)
263 if (!em) return 0; 263 if (!em) return 0;
264 /* get whatever engine module we inherit from */ 264 /* get whatever engine module we inherit from */
265 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0; 265 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0;
266 _evas_engine_fb_log_dom = eina_log_domain_register("Evas_fb_engine", EVAS_DEFAULT_LOG_COLOR);
267 if (_evas_engine_fb_log_dom < 0) {
268 EINA_LOG_ERR("Impossible to create a log domain for FB engine.\n");
269 return 0;
270 }
271
266 /* store it for later use */ 272 /* store it for later use */
267 func = pfunc; 273 func = pfunc;
268 /* now to override methods */ 274 /* now to override methods */
@@ -289,6 +295,7 @@ module_open(Evas_Module *em)
289static void 295static void
290module_close(Evas_Module *em) 296module_close(Evas_Module *em)
291{ 297{
298 eina_log_dom_unregister(_evas_engine_fb_log_dom);
292} 299}
293 300
294static Evas_Module_Api evas_modapi = 301static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/fb/evas_engine.h b/legacy/evas/src/modules/engines/fb/evas_engine.h
index d5145823cd..295e91e4b1 100644
--- a/legacy/evas/src/modules/engines/fb/evas_engine.h
+++ b/legacy/evas/src/modules/engines/fb/evas_engine.h
@@ -3,6 +3,32 @@
3 3
4#include "evas_fb.h" 4#include "evas_fb.h"
5 5
6extern int _evas_engine_fb_log_dom;
7#ifdef ERR
8# undef ERR
9#endif
10#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_fb_log_dom, __VA_ARGS__)
11
12#ifdef DBG
13# undef DBG
14#endif
15#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_fb_log_dom, __VA_ARGS__)
16
17#ifdef INF
18# undef INF
19#endif
20#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_fb_log_dom, __VA_ARGS__)
21
22#ifdef WRN
23# undef WRN
24#endif
25#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_fb_log_dom, __VA_ARGS__)
26
27#ifdef CRIT
28# undef CRIT
29#endif
30#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_fb_log_dom, __VA_ARGS__)
31
6typedef struct _Outbuf Outbuf; 32typedef struct _Outbuf Outbuf;
7 33
8typedef enum _Outbuf_Depth Outbuf_Depth; 34typedef enum _Outbuf_Depth Outbuf_Depth;
diff --git a/legacy/evas/src/modules/engines/fb/evas_fb_main.c b/legacy/evas/src/modules/engines/fb/evas_fb_main.c
index 114cc25ba6..7d2c73adab 100644
--- a/legacy/evas/src/modules/engines/fb/evas_fb_main.c
+++ b/legacy/evas/src/modules/engines/fb/evas_fb_main.c
@@ -377,10 +377,10 @@ fb_getmode(void)
377 bpp = mode->fb_var.bits_per_pixel / 8; 377 bpp = mode->fb_var.bits_per_pixel / 8;
378 break; 378 break;
379 default: 379 default:
380 ERROR("EvasFB: Cannot handle framebuffer of depth %i", 380 ERR("Cannot handle framebuffer of depth %i",
381 mode->fb_var.bits_per_pixel); 381 mode->fb_var.bits_per_pixel);
382 fb_cleanup(); 382 fb_cleanup();
383 free(mode); 383 free(mode);
384 return NULL; 384 return NULL;
385 } 385 }
386 mode->depth = depth; 386 mode->depth = depth;
@@ -418,7 +418,7 @@ fb_setvt(int vtno)
418 chown(vtname, getuid(), getgid()); 418 chown(vtname, getuid(), getgid());
419 if (access(vtname,R_OK | W_OK) == -1) 419 if (access(vtname,R_OK | W_OK) == -1)
420 { 420 {
421 CRITICAL("EvasFB: access %s: %s",vtname,strerror(errno)); 421 CRIT("Access %s: %s",vtname,strerror(errno));
422 exit(1); 422 exit(1);
423 } 423 }
424 open(vtname,O_RDWR); 424 open(vtname,O_RDWR);
@@ -463,7 +463,7 @@ fb_init(int vt, int device)
463 } 463 }
464 if (fb == -1) 464 if (fb == -1)
465 { 465 {
466 CRITICAL("open %s: %s", dev, strerror(errno)); 466 CRIT("open %s: %s", dev, strerror(errno));
467 fb_cleanup(); 467 fb_cleanup();
468 exit(1); 468 exit(1);
469 } 469 }
@@ -527,7 +527,7 @@ fb_postinit(FB_Mode *mode)
527 527
528 if (fb_fix.type != FB_TYPE_PACKED_PIXELS) 528 if (fb_fix.type != FB_TYPE_PACKED_PIXELS)
529 { 529 {
530 CRITICAL("can handle only packed pixel frame buffers"); 530 CRIT("can handle only packed pixel frame buffers");
531 fb_cleanup(); 531 fb_cleanup();
532 exit(1); 532 exit(1);
533 } 533 }
diff --git a/legacy/evas/src/modules/engines/fb/evas_outbuf.c b/legacy/evas/src/modules/engines/fb/evas_outbuf.c
index e2210e7b83..ec97910a6b 100644
--- a/legacy/evas/src/modules/engines/fb/evas_outbuf.c
+++ b/legacy/evas/src/modules/engines/fb/evas_outbuf.c
@@ -12,7 +12,7 @@ void
12evas_fb_outbuf_fb_free(Outbuf *buf) 12evas_fb_outbuf_fb_free(Outbuf *buf)
13{ 13{
14 /* FIXME: impliment */ 14 /* FIXME: impliment */
15 WARN("destroying fb info.. not implemented!!!! WARNING. LEAK!"); 15 WRN("destroying fb info.. not implemented!!!! WARNING. LEAK!");
16 if (buf->priv.back_buf) 16 if (buf->priv.back_buf)
17 evas_cache_image_drop(&buf->priv.back_buf->cache_entry); 17 evas_cache_image_drop(&buf->priv.back_buf->cache_entry);
18 free(buf); 18 free(buf);
diff --git a/legacy/evas/src/modules/engines/gl_glew/evas_engine.c b/legacy/evas/src/modules/engines/gl_glew/evas_engine.c
index 6386e365a6..3d05c9b8d4 100644
--- a/legacy/evas/src/modules/engines/gl_glew/evas_engine.c
+++ b/legacy/evas/src/modules/engines/gl_glew/evas_engine.c
@@ -1,7 +1,7 @@
1#include "evas_engine.h" 1#include "evas_engine.h"
2#include "Evas_Engine_GL_Glew.h" 2#include "Evas_Engine_GL_Glew.h"
3 3
4 4int _evas_engine_GL_GLEW_log_dom = -1;
5/* function tables - filled in later (func and parent func) */ 5/* function tables - filled in later (func and parent func) */
6static Evas_Func func, pfunc; 6static Evas_Func func, pfunc;
7 7
@@ -20,12 +20,8 @@ static void *
20eng_info(Evas *e) 20eng_info(Evas *e)
21{ 21{
22 Evas_Engine_Info_GL_Glew *info; 22 Evas_Engine_Info_GL_Glew *info;
23
24 info = calloc(1, sizeof(Evas_Engine_Info_GL_Glew)); 23 info = calloc(1, sizeof(Evas_Engine_Info_GL_Glew));
25 if (!info) return NULL;
26
27 info->magic.magic = rand(); 24 info->magic.magic = rand();
28
29 return info; 25 return info;
30 e = NULL; 26 e = NULL;
31} 27}
@@ -34,7 +30,6 @@ static void
34eng_info_free(Evas *e, void *info) 30eng_info_free(Evas *e, void *info)
35{ 31{
36 Evas_Engine_Info_GL_Glew *in; 32 Evas_Engine_Info_GL_Glew *in;
37
38 in = (Evas_Engine_Info_GL_Glew *)info; 33 in = (Evas_Engine_Info_GL_Glew *)info;
39 free(in); 34 free(in);
40} 35}
@@ -928,6 +923,12 @@ module_open(Evas_Module *em)
928 if (!em) return 0; 923 if (!em) return 0;
929 /* get whatever engine module we inherit from */ 924 /* get whatever engine module we inherit from */
930 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0; 925 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0;
926 _evas_engine_GL_GLEW_log_dom = eina_log_domain_register("EvasGLGlew",EVAS_DEFAULT_LOG_COLOR);
927 if(_evas_engine_GL_GLEW_log_dom < 0)
928 {
929 EINA_LOG_ERR("Impossible to create a log domain for GL (Glew) engine.\n");
930 return 0;
931 }
931 /* store it for later use */ 932 /* store it for later use */
932 func = pfunc; 933 func = pfunc;
933 /* now to override methods */ 934 /* now to override methods */
@@ -1006,6 +1007,7 @@ module_open(Evas_Module *em)
1006static void 1007static void
1007module_close(Evas_Module *em) 1008module_close(Evas_Module *em)
1008{ 1009{
1010 eina_log_domain_unregister(_evas_engine_GL_GLEW_log_dom);
1009} 1011}
1010 1012
1011static Evas_Module_Api evas_modapi = 1013static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/gl_glew/evas_engine.h b/legacy/evas/src/modules/engines/gl_glew/evas_engine.h
index 8df1782dfb..b35c1c5c19 100644
--- a/legacy/evas/src/modules/engines/gl_glew/evas_engine.h
+++ b/legacy/evas/src/modules/engines/gl_glew/evas_engine.h
@@ -4,7 +4,31 @@
4#include <windows.h> 4#include <windows.h>
5 5
6#include "evas_gl_common.h" 6#include "evas_gl_common.h"
7extern int _evas_engine_GL_glew_log_dom ;
8#ifdef ERR
9# undef ERR
10#endif
11#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_GL_glew_log_dom, __VA_ARGS__)
7 12
13#ifdef DBG
14# undef DBG
15#endif
16#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_GL_glew_log_dom, __VA_ARGS__)
17
18#ifdef INF
19# undef INF
20#endif
21#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_GL_glew_log_dom, __VA_ARGS__)
22
23#ifdef WRN
24# undef WRN
25#endif
26#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_GL_glew_log_dom, __VA_ARGS__)
27
28#ifdef CRIT
29# undef CRIT
30#endif
31#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_GL_glew_log_dom, __VA_ARGS__)
8 32
9typedef struct _Evas_GL_Glew_Window Evas_GL_Glew_Window; 33typedef struct _Evas_GL_Glew_Window Evas_GL_Glew_Window;
10 34
diff --git a/legacy/evas/src/modules/engines/gl_glew/evas_glew_main.c b/legacy/evas/src/modules/engines/gl_glew/evas_glew_main.c
index 68a67d7f5c..dbaf473c09 100644
--- a/legacy/evas/src/modules/engines/gl_glew/evas_glew_main.c
+++ b/legacy/evas/src/modules/engines/gl_glew/evas_glew_main.c
@@ -44,7 +44,7 @@ evas_glew_init(HWND window, HDC *dc, HGLRC *context)
44 44
45 if (GLEW_VERSION_2_0) 45 if (GLEW_VERSION_2_0)
46 { 46 {
47 INFO("2.0"); 47 INF("2.0");
48 } 48 }
49 49
50 return 1; 50 return 1;
diff --git a/legacy/evas/src/modules/engines/gl_x11/evas_engine.c b/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
index cfbabdc1f2..f508f0622a 100644
--- a/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
+++ b/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
@@ -9,7 +9,7 @@
9#else 9#else
10#endif 10#endif
11 11
12 12int _evas_engine_GL_X11_log_dom = -1;
13/* function tables - filled in later (func and parent func) */ 13/* function tables - filled in later (func and parent func) */
14static Evas_Func func, pfunc; 14static Evas_Func func, pfunc;
15 15
@@ -25,9 +25,7 @@ static void *
25eng_info(Evas *e) 25eng_info(Evas *e)
26{ 26{
27 Evas_Engine_Info_GL_X11 *info; 27 Evas_Engine_Info_GL_X11 *info;
28
29 info = calloc(1, sizeof(Evas_Engine_Info_GL_X11)); 28 info = calloc(1, sizeof(Evas_Engine_Info_GL_X11));
30 if (!info) return NULL;
31 info->magic.magic = rand(); 29 info->magic.magic = rand();
32 info->func.best_visual_get = eng_best_visual_get; 30 info->func.best_visual_get = eng_best_visual_get;
33 info->func.best_colormap_get = eng_best_colormap_get; 31 info->func.best_colormap_get = eng_best_colormap_get;
@@ -40,7 +38,7 @@ static void
40eng_info_free(Evas *e __UNUSED__, void *info) 38eng_info_free(Evas *e __UNUSED__, void *info)
41{ 39{
42 Evas_Engine_Info_GL_X11 *in; 40 Evas_Engine_Info_GL_X11 *in;
43 41 eina_log_domain_unregister(_evas_engine_GL_X11_log_dom);
44 in = (Evas_Engine_Info_GL_X11 *)info; 42 in = (Evas_Engine_Info_GL_X11 *)info;
45 free(in); 43 free(in);
46} 44}
@@ -194,7 +192,7 @@ eng_output_redraws_clear(void *data)
194 192
195 re = (Render_Engine *)data; 193 re = (Render_Engine *)data;
196 re->win->draw.redraw = 0; 194 re->win->draw.redraw = 0;
197// INFO("GL: finish update cycle!"); 195// INF("GL: finish update cycle!");
198} 196}
199 197
200/* at least the nvidia drivers are so abysmal that copying from the backbuffer 198/* at least the nvidia drivers are so abysmal that copying from the backbuffer
@@ -1078,6 +1076,12 @@ module_open(Evas_Module *em)
1078 if (!em) return 0; 1076 if (!em) return 0;
1079 /* get whatever engine module we inherit from */ 1077 /* get whatever engine module we inherit from */
1080 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0; 1078 if (!_evas_module_engine_inherit(&pfunc, "software_generic")) return 0;
1079 _evas_engine_GL_X11_log_dom = eina_log_domain_register("EvasEngineGLX11", EVAS_DEFAULT_LOG_COLOR);
1080 if(_evas_engine_GL_X11_log_dom<0)
1081 {
1082 EINA_LOG_ERR("Impossible to create a log domain for GL X11 engine.\n");
1083 return 0;
1084 }
1081 /* store it for later use */ 1085 /* store it for later use */
1082 func = pfunc; 1086 func = pfunc;
1083 /* now to override methods */ 1087 /* now to override methods */
@@ -1179,6 +1183,7 @@ module_open(Evas_Module *em)
1179static void 1183static void
1180module_close(Evas_Module *em) 1184module_close(Evas_Module *em)
1181{ 1185{
1186 eina_log_domain_unregister(_evas_engine_GL_X11_log_dom);
1182} 1187}
1183 1188
1184static Evas_Module_Api evas_modapi = 1189static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/gl_x11/evas_engine.h b/legacy/evas/src/modules/engines/gl_x11/evas_engine.h
index 71ab07a25c..579a06368d 100644
--- a/legacy/evas/src/modules/engines/gl_x11/evas_engine.h
+++ b/legacy/evas/src/modules/engines/gl_x11/evas_engine.h
@@ -45,6 +45,32 @@
45#include "Evas.h" 45#include "Evas.h"
46#include "Evas_Engine_GL_X11.h" 46#include "Evas_Engine_GL_X11.h"
47 47
48extern int _evas_engine_GL_X11_log_dom ;
49#ifdef ERR
50# undef ERR
51#endif
52#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_GL_X11_log_dom, __VA_ARGS__)
53
54#ifdef DBG
55# undef DBG
56#endif
57#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_GL_X11_log_dom, __VA_ARGS__)
58
59#ifdef INF
60# undef INF
61#endif
62#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_GL_X11_log_dom, __VA_ARGS__)
63
64#ifdef WRN
65# undef WRN
66#endif
67#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_GL_X11_log_dom, __VA_ARGS__)
68
69#ifdef CRIT
70# undef CRIT
71#endif
72#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_GL_X11_log_dom, __VA_ARGS__)
73
48typedef struct _Evas_GL_X11_Window Evas_GL_X11_Window; 74typedef struct _Evas_GL_X11_Window Evas_GL_X11_Window;
49 75
50struct _Evas_GL_X11_Window 76struct _Evas_GL_X11_Window
diff --git a/legacy/evas/src/modules/engines/quartz/evas_engine.c b/legacy/evas/src/modules/engines/quartz/evas_engine.c
index 91c646d9a6..5f522ac039 100644
--- a/legacy/evas/src/modules/engines/quartz/evas_engine.c
+++ b/legacy/evas/src/modules/engines/quartz/evas_engine.c
@@ -8,7 +8,7 @@
8#include "evas_engine.h" 8#include "evas_engine.h"
9#include "Evas_Engine_Quartz.h" 9#include "Evas_Engine_Quartz.h"
10#include "evas_quartz_private.h" 10#include "evas_quartz_private.h"
11 11int _evas_engine_quartz_log_dom = -1;
12static Evas_Func func; 12static Evas_Func func;
13 13
14typedef struct _Render_Engine Render_Engine; 14typedef struct _Render_Engine Render_Engine;
@@ -40,12 +40,10 @@ static void *
40eng_info(Evas *e) 40eng_info(Evas *e)
41{ 41{
42 Evas_Engine_Info_Quartz *info; 42 Evas_Engine_Info_Quartz *info;
43 43
44 info = calloc(1, sizeof(Evas_Engine_Info_Quartz)); 44 info = calloc(1, sizeof(Evas_Engine_Info_Quartz));
45 if (!info) return NULL; 45 if (!info) return NULL;
46
47 info->magic.magic = rand(); 46 info->magic.magic = rand();
48
49 return info; 47 return info;
50} 48}
51 49
@@ -686,15 +684,15 @@ eng_gradient_draw(void *data, void *context, void *surface, void *gradient, int
686 RGBA_Draw_Context *dc = (RGBA_Draw_Context *)context; 684 RGBA_Draw_Context *dc = (RGBA_Draw_Context *)context;
687 Evas_Quartz_Gradient *gr = (Evas_Quartz_Gradient *)gradient; 685 Evas_Quartz_Gradient *gr = (Evas_Quartz_Gradient *)gradient;
688 686
689 INFO("#Gradient#"); 687 INF("#Gradient#");
690 INFO("Fill: %i %i %i %i", gr->grad->fill.x, gr->grad->fill.y, gr->grad->fill.w, gr->grad->fill.h); 688 INF("Fill: %i %i %i %i", gr->grad->fill.x, gr->grad->fill.y, gr->grad->fill.w, gr->grad->fill.h);
691 INFO("Type: %s %s", gr->grad->type.name, gr->grad->type.params); 689 INF("Type: %s %s", gr->grad->type.name, gr->grad->type.params);
692 INFO("XYWH: %i %i %i %i", x, y, w, h); 690 INF("XYWH: %i %i %i %i", x, y, w, h);
693 INFO("Geom: %p %p", gr->grad->type.geometer, gr->grad->type.geometer->get_fill_func); 691 INF("Geom: %p %p", gr->grad->type.geometer, gr->grad->type.geometer->get_fill_func);
694 INFO("Map: len: %d angle: %f direction: %d offset: %f", gr->grad->map.len, gr->grad->map.angle, gr->grad->map.direction, gr->grad->map.offset); 692 INF("Map: len: %d angle: %f direction: %d offset: %f", gr->grad->map.len, gr->grad->map.angle, gr->grad->map.direction, gr->grad->map.offset);
695 INFO("Color: nstops: %d len: %d", gr->grad->color.nstops, gr->grad->color.len); 693 INF("Color: nstops: %d len: %d", gr->grad->color.nstops, gr->grad->color.len);
696 INFO("Alpha: nstops: %d len: %d", gr->grad->alpha.nstops, gr->grad->alpha.len); 694 INF("Alpha: nstops: %d len: %d", gr->grad->alpha.nstops, gr->grad->alpha.len);
697 INFO(""); 695 INF("");
698 696
699 if ((gr->sw != w) || (gr->sh != h)) 697 if ((gr->sw != w) || (gr->sh != h))
700 gr->changed = 1; 698 gr->changed = 1;
@@ -1416,7 +1414,16 @@ static int
1416module_open(Evas_Module *em) 1414module_open(Evas_Module *em)
1417{ 1415{
1418 if (!em) return 0; 1416 if (!em) return 0;
1417
1419 if (!_evas_module_engine_inherit(&func, "software_generic")) return 0; 1418 if (!_evas_module_engine_inherit(&func, "software_generic")) return 0;
1419
1420 _evas_engine_quartz_log_dom = eina_log_domain_register("EvasQuartz", EVAS_DEFAULT_LOG_COLOR);
1421 if(_evas_engine_quartz_log_dom < 0)
1422 {
1423 EINA_LOG_ERR("Impossible to create a log domain for the Quartz engine.\n");
1424 return 0;
1425 }
1426
1420 #define ORD(f) EVAS_API_OVERRIDE(f, &func, eng_) 1427 #define ORD(f) EVAS_API_OVERRIDE(f, &func, eng_)
1421 ORD(context_anti_alias_get); 1428 ORD(context_anti_alias_get);
1422 ORD(context_anti_alias_set); 1429 ORD(context_anti_alias_set);
@@ -1514,7 +1521,7 @@ module_open(Evas_Module *em)
1514static void 1521static void
1515module_close(Evas_Module *em) 1522module_close(Evas_Module *em)
1516{ 1523{
1517 1524 eina_log_domain_unregister(_evas_engine_quartz_log_dom);
1518} 1525}
1519 1526
1520static Evas_Module_Api evas_modapi = 1527static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/quartz/evas_engine.h b/legacy/evas/src/modules/engines/quartz/evas_engine.h
index cb43373d62..a32e2328fb 100644
--- a/legacy/evas/src/modules/engines/quartz/evas_engine.h
+++ b/legacy/evas/src/modules/engines/quartz/evas_engine.h
@@ -3,6 +3,33 @@
3 3
4#include <ApplicationServices/ApplicationServices.h> 4#include <ApplicationServices/ApplicationServices.h>
5 5
6/* log domain variable declared in evas_engine.c */
7extern int _evas_engine_quartz_log_dom ;
8#ifdef ERR
9# undef ERR
10#endif
11#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_quartz_log_dom, __VA_ARGS__)
12
13#ifdef DBG
14# undef DBG
15#endif
16#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_quartz_log_dom, __VA_ARGS__)
17
18#ifdef INF
19# undef INF
20#endif
21#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_quartz_log_dom, __VA_ARGS__)
22
23#ifdef WRN
24# undef WRN
25#endif
26#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_quartz_log_dom, __VA_ARGS__)
27
28#ifdef CRIT
29# undef CRIT
30#endif
31#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_quartz_log_dom, __VA_ARGS__)
32
6typedef struct _Evas_Quartz_Context Evas_Quartz_Context; 33typedef struct _Evas_Quartz_Context Evas_Quartz_Context;
7 34
8struct _Evas_Quartz_Context 35struct _Evas_Quartz_Context
diff --git a/legacy/evas/src/modules/engines/software_16/evas_engine.c b/legacy/evas/src/modules/engines/software_16/evas_engine.c
index 698f96055f..6f4ecabd4e 100644
--- a/legacy/evas/src/modules/engines/software_16/evas_engine.c
+++ b/legacy/evas/src/modules/engines/software_16/evas_engine.c
@@ -1,5 +1,4 @@
1#include "evas_common.h" 1#include "evas_common.h"
2#include "evas_private.h"
3#include "evas_common_soft16.h" 2#include "evas_common_soft16.h"
4 3
5/* 4/*
@@ -9,9 +8,34 @@
9 ** 8 **
10 ***** 9 *****
11 */ 10 */
11int _evas_soft16_log_dom = -1;
12#ifdef ERR
13#undef ERR
14#endif
15#define ERR(...) EINA_LOG_DOM_ERR( _evas_soft16_log_dom, __VA_ARGS__)
16
17#ifdef DBG
18#undef DBG
19#endif
20#define DBG(...) EINA_LOG_DOM_DBG(_evas_soft16_log_dom, __VA_ARGS__)
21
22#ifdef INF
23#undef INF
24#endif
25#define INF(...) EINA_LOG_DOM_INFO(_evas_soft16_log_dom, __VA_ARGS__)
26
27#ifdef WRN
28#undef WRN
29#endif
30#define WRN(...) EINA_LOG_DOM_WARN(_evas_soft16_log_dom, __VA_ARGS__)
31
32#ifdef CRIT
33#undef CRIT
34#endif
35#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_soft16_log_dom, __VA_ARGS__)
12 36
13#define NOT_IMPLEMENTED() \ 37#define NOT_IMPLEMENTED() \
14 WARN("NOT_IMPLEMENTED: %s() at %s:%d", \ 38 WRN("NOT_IMPLEMENTED: %s() at %s:%d", \
15 __FUNCTION__, __FILE__, __LINE__) 39 __FUNCTION__, __FILE__, __LINE__)
16 40
17static void * 41static void *
@@ -509,7 +533,7 @@ eng_image_new_from_data(void *data __UNUSED__, int w, int h, DATA32 *image_data,
509{ 533{
510 if ((image_data) && (cspace != EVAS_COLORSPACE_RGB565_A5P)) 534 if ((image_data) && (cspace != EVAS_COLORSPACE_RGB565_A5P))
511 { 535 {
512 WARN("Unsupported colorspace %d in %s() (%s:%d)", 536 WRN("Unsupported colorspace %d in %s() (%s:%d)",
513 cspace, __FUNCTION__, __FILE__, __LINE__); 537 cspace, __FUNCTION__, __FILE__, __LINE__);
514 return NULL; 538 return NULL;
515 } 539 }
@@ -521,7 +545,7 @@ eng_image_new_from_copied_data(void *data __UNUSED__, int w, int h, DATA32 *imag
521{ 545{
522 if ((image_data) && (cspace != EVAS_COLORSPACE_RGB565_A5P)) 546 if ((image_data) && (cspace != EVAS_COLORSPACE_RGB565_A5P))
523 { 547 {
524 WARN("Unsupported colorspace %d in %s() (%s:%d)", 548 WRN("Unsupported colorspace %d in %s() (%s:%d)",
525 cspace, __FUNCTION__, __FILE__, __LINE__); 549 cspace, __FUNCTION__, __FILE__, __LINE__);
526 return NULL; 550 return NULL;
527 } 551 }
@@ -1002,13 +1026,21 @@ static int
1002module_open(Evas_Module *em) 1026module_open(Evas_Module *em)
1003{ 1027{
1004 if (!em) return 0; 1028 if (!em) return 0;
1029 _evas_soft16_log_dom = eina_log_domain_register("Soft16Engine", EVAS_DEFAULT_LOG_COLOR);
1030 if(_evas_soft16_log_dom < 0)
1031 {
1032 EINA_LOG_ERR("Impossible to create a log domain for the soft16 Engine.\n");
1033 return 0;
1034 }
1005 em->functions = (void *)(&func); 1035 em->functions = (void *)(&func);
1036
1006 return 1; 1037 return 1;
1007} 1038}
1008 1039
1009static void 1040static void
1010module_close(Evas_Module *em) 1041module_close(Evas_Module *em)
1011{ 1042{
1043 eina_log_domain_unregister(_evas_soft16_log_dom);
1012} 1044}
1013 1045
1014static Evas_Module_Api evas_modapi = 1046static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.c b/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.c
index 1e9a1b9ae4..6e2abb0309 100644
--- a/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.c
+++ b/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.c
@@ -4,6 +4,7 @@
4#include "Evas_Engine_Software_16_DDraw.h" 4#include "Evas_Engine_Software_16_DDraw.h"
5#include "evas_common_soft16.h" 5#include "evas_common_soft16.h"
6 6
7int _evas_engine_soft16_ddraw_log_dom = -1;
7/* function tables - filled in later (func and parent func) */ 8/* function tables - filled in later (func and parent func) */
8static Evas_Func func, pfunc; 9static Evas_Func func, pfunc;
9 10
@@ -50,7 +51,6 @@ static void *
50eng_info(Evas *e) 51eng_info(Evas *e)
51{ 52{
52 Evas_Engine_Info_Software_16_DDraw *info; 53 Evas_Engine_Info_Software_16_DDraw *info;
53
54 info = calloc(1, sizeof(Evas_Engine_Info_Software_16_DDraw)); 54 info = calloc(1, sizeof(Evas_Engine_Info_Software_16_DDraw));
55 if (!info) return NULL; 55 if (!info) return NULL;
56 info->magic.magic = rand(); 56 info->magic.magic = rand();
@@ -62,7 +62,6 @@ static void
62eng_info_free(Evas *e, void *info) 62eng_info_free(Evas *e, void *info)
63{ 63{
64 Evas_Engine_Info_Software_16_DDraw *in; 64 Evas_Engine_Info_Software_16_DDraw *in;
65
66 in = (Evas_Engine_Info_Software_16_DDraw *)info; 65 in = (Evas_Engine_Info_Software_16_DDraw *)info;
67 free(in); 66 free(in);
68} 67}
@@ -575,6 +574,12 @@ module_open(Evas_Module *em)
575 if (!em) return 0; 574 if (!em) return 0;
576 /* get whatever engine module we inherit from */ 575 /* get whatever engine module we inherit from */
577 if (!_evas_module_engine_inherit(&pfunc, "software_16")) return 0; 576 if (!_evas_module_engine_inherit(&pfunc, "software_16")) return 0;
577 _evas_engine_soft16_ddraw_log_dom = eina_log_domain_register("EvasSoft16DDraw",EINA_COLOR_BLUE);
578 if(_evas_engine_soft16_ddraw_log_dom < 0)
579 {
580 EINA_LOG_ERR("Impossible to create a log domain for Soft16_DDraw engine.\n");
581 return 0;
582 }
578 /* store it for later use */ 583 /* store it for later use */
579 func = pfunc; 584 func = pfunc;
580 /* now to override methods */ 585 /* now to override methods */
@@ -601,6 +606,7 @@ module_open(Evas_Module *em)
601static void 606static void
602module_close(Evas_Module *em) 607module_close(Evas_Module *em)
603{ 608{
609 eina_log_domain_unregister(_evas_engine_soft16_ddraw_log_dom);
604} 610}
605 611
606static Evas_Module_Api evas_modapi = 612static Evas_Module_Api evas_modapi =
diff --git a/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.h b/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.h
index 8307ad8677..fe85e97ab2 100644
--- a/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.h
+++ b/legacy/evas/src/modules/engines/software_16_ddraw/evas_engine.h
@@ -1,12 +1,37 @@
1#ifndef __EVAS_ENGINE_H__ 1#ifndef __EVAS_ENGINE_H__
2#define __EVAS_ENGINE_H__ 2#define __EVAS_ENGINE_H__
3 3
4
5#include <windows.h> 4#include <windows.h>
6#include <ddraw.h> 5#include <ddraw.h>
7 6
8#include "evas_common_soft16.h" 7#include "evas_common_soft16.h"
9 8
9extern int _evas_engine_soft16_ddraw_log_dom ;
10#ifdef ERR
11# undef ERR
12#endif
13#define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_soft16_ddraw_log_dom, __VA_ARGS__)
14
15#ifdef DBG
16# undef DBG
17#endif
18#define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_soft16_ddraw_log_dom, __VA_ARGS__)
19
20#ifdef INF
21# undef INF
22#endif
23#define INF(...) EINA_LOG_DOM_INFO(_evas_engine_soft16_ddraw_log_dom, __VA_ARGS__)
24
25#ifdef WRN
26# undef WRN
27#endif
28#define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_soft16_ddraw_log_dom, __VA_ARGS__)
29
30#ifdef CRIT
31# undef CRIT
32#endif
33#define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_soft16_ddraw_log_dom, __VA_ARGS__)
34
10typedef struct _DDraw_Output_Buffer DDraw_Output_Buffer; 35typedef struct _DDraw_Output_Buffer DDraw_Output_Buffer;
11 36
12struct _DDraw_Output_Buffer 37struct _DDraw_Output_Buffer
diff --git a/legacy/evas/src/modules/engines/software_16_sdl/evas_engine.c b/legacy/evas/src/modules/engines/software_16_sdl/evas_engine.c
index 5ccb789630..76e5325e02 100644
--- a/legacy/evas/src/modules/engines/software_16_sdl/evas_engine.c
+++ b/legacy/evas/src/modules/engines/software_16_sdl/evas_engine.c
@@ -7,6 +7,7 @@
7 7
8#include "evas_common.h" 8#include "evas_common.h"
9#include "evas_engine.h" 9#include "evas_engine.h"
10int _evas_engine_soft16_sdl_log_dom = -1;
10 11
11/* function tables - filled in later (func and parent func) */ 12/* function tables - filled in later (func and parent func) */
12static Evas_Func func = {}; 13static Evas_Func func = {};
@@ -65,7 +66,6 @@ static void *
65evas_engine_sdl16_info(Evas *e __UNUSED__) 66evas_engine_sdl16_info(Evas *e __UNUSED__)
66{ 67{
67 Evas_Engine_Info_SDL_16 *info; 68 Evas_Engine_Info_SDL_16 *info;
68
69 info = calloc(1, sizeof(Evas_Engine_Info_SDL_16)); 69 info = calloc(1, sizeof(Evas_Engine_Info_SDL_16));
70 if (!info) return NULL; 70 if (!info) return NULL;
71 info->magic.magic = rand(); 71 info->magic.magic = rand();
@@ -76,7 +76,6 @@ static void
76evas_engine_sdl16_info_free(Evas *e __UNUSED__, void *info) 76evas_engine_sdl16_info_free(Evas *e __UNUSED__, void *info)
77{ 77{
78 Evas_Engine_Info_SDL_16 *in; 78 Evas_Engine_Info_SDL_16 *in;
79
80 in = (Evas_Engine_Info_SDL_16 *)info; 79 in = (Evas_Engine_Info_SDL_16 *)info;
81 free(in); 80 free(in);
82} 81}
@@ -144,7 +143,7 @@ _sdl16_output_setup(int w, int h, int rotation, int fullscreen, int noframe, int
144 re->cache = evas_cache_engine_image_init(&_sdl16_cache_engine_image_cb, evas_common_soft16_image_cache_get()); 143 re->cache = evas_cache_engine_image_init(&_sdl16_cache_engine_image_cb, evas_common_soft16_image_cache_get());
145 if (!re->cache) 144 if (!re->cache)
146 { 145 {
147 ERROR("Evas_Cache_Engine_Image allocation failed!"); 146 ERR("Evas_Cache_Engine_Image allocation failed!");
148 free(re); 147 free(re);
149 return NULL; 148 return NULL;
150 } 149 }
@@ -170,7 +169,7 @@ _sdl16_output_setup(int w, int h, int rotation, int fullscreen, int noframe, int
170 | (noframe ? SDL_NOFRAME : 0)); 169 | (noframe ? SDL_NOFRAME : 0));
171 if (!surface) 170 if (!surface)
172 { 171 {
173 ERROR("SDL_SetVideoMode [ %i x %i x 16 ] failed", w, h); 172 ERR("SDL_SetVideoMode [ %i x %i x 16 ] failed", w, h);
174 evas_cache_engine_image_shutdown(re->cache); 173 evas_cache_engine_image_shutdown(re->cache);
175 free(re); 174 free(re);
176 return NULL; 175 return NULL;
@@ -182,7 +181,7 @@ _sdl16_output_setup(int w, int h, int rotation, int fullscreen, int noframe, int
182 re->soft16_engine_image = (SDL_Engine_Image_Entry *) evas_cache_engine_image_engine(re->cache, surface); 181 re->soft16_engine_image = (SDL_Engine_Image_Entry *) evas_cache_engine_image_engine(re->cache, surface);
183 if (!re->soft16_engine_image) 182 if (!re->soft16_engine_image)
184 { 183 {
185 ERROR("Soft16_Image allocation from SDL failed"); 184 ERR("Soft16_Image allocation from SDL failed");
186 evas_cache_engine_image_shutdown(re->cache); 185 evas_cache_engine_image_shutdown(re->cache);
187 free(re); 186 free(re);
188 return NULL; 187 return NULL;
@@ -204,7 +203,7 @@ evas_engine_sdl16_setup(Evas *e, void *in)
204 203
205 if (SDL_InitSubSystem(SDL_INIT_VIDEO) < 0) 204 if (SDL_InitSubSystem(SDL_INIT_VIDEO) < 0)
206 { 205 {
207 ERROR("SDL_Init failed with %s", SDL_GetError()); 206 ERR("SDL_Init failed with %s", SDL_GetError());
208 SDL_Quit(); 207 SDL_Quit();
209 return 0; 208 return 0;
210 } 209 }
@@ -263,13 +262,13 @@ evas_engine_sdl16_output_resize(void *data, int w, int h)
263 | (re->flags.noframe ? SDL_NOFRAME : 0)); 262 | (re->flags.noframe ? SDL_NOFRAME : 0));
264 if (!surface) 263 if (!surface)
265 { 264 {
266 ERROR("Unable to change the resolution to : %ix%i", w, h); 265 ERR("Unable to change the resolution to : %ix%i", w, h);
267 exit(-1); 266 exit(-1);
268 } 267 }
269 re->soft16_engine_image = (SDL_Engine_Image_Entry *) evas_cache_engine_image_engine(re->cache, surface); 268 re->soft16_engine_image = (SDL_Engine_Image_Entry *) evas_cache_engine_image_engine(re->cache, surface);
270 if (!re->soft16_engine_image) 269 if (!re->soft16_engine_image)
271 { 270 {
272 ERROR("RGBA_Image allocation from SDL failed"); 271 ERR("RGBA_Image allocation from SDL failed");
273 exit(-1); 272 exit(-1);
274 } 273 }
275 274
@@ -612,12 +611,12 @@ evas_engine_sdl16_image_new_from_copied_data(void *data,
612 611
613 if (cspace != EVAS_COLORSPACE_RGB565_A5P) 612 if (cspace != EVAS_COLORSPACE_RGB565_A5P)
614 { 613 {
615 WARN("Unsupported colorspace %d in %s() (%s:%d)", 614 WRN("Unsupported colorspace %d in %s() (%s:%d)",
616 cspace, __FUNCTION__, __FILE__, __LINE__); 615 cspace, __FUNCTION__, __FILE__, __LINE__);
617 return NULL; 616 return NULL;
618 } 617 }
619 618
620 WARN("s image_data: %p", image_data); 619 WRN("s image_data: %p", image_data);
621 620
622 return evas_cache_engine_image_copied_data(re->cache, 621 return evas_cache_engine_image_copied_data(re->cache,
623 w, h, 622 w, h,
@@ -632,7 +631,7 @@ evas_engine_sdl16_image_new_from_data(void *data, int w, int h, DATA32* image_da
632 631
633 if (cspace != EVAS_COLORSPACE_RGB565_A5P) 632 if (cspace != EVAS_COLORSPACE_RGB565_A5P)
634 { 633 {
635 WARN("Unsupported colorspace %d in %s() (%s:%d)", 634 WRN("Unsupported colorspace %d in %s() (%s:%d)",
636 cspace, __FUNCTION__, __FILE__, __LINE__); 635 cspace, __FUNCTION__, __FILE__, __LINE__);
637 return NULL; 636 return NULL;
638 } 637 }
@@ -1030,6 +1029,13 @@ module_open(Evas_Module *em)
1030 if (!em) return 0; 1029 if (!em) return 0;
1031 /* get whatever engine module we inherit from */ 1030 /* get whatever engine module we inherit from */
1032 if (!_evas_module_engine_inherit(&pfunc, "software_16")) return 0; 1031 if (!_evas_module_engine_inherit(&pfunc, "software_16")) return 0;
1032 _evas_engine_soft16_sdl_log_dom = eina_log_domain_register("EvasSoft16SDL",EVAS_DEFAULT_LOG_COLOR);
1033 if(_evas_engine_soft16_sdl_log_dom < 0)
1034 {
1035 EINA_LOG_ERR("Impossible to create a log domain for the Soft16_SDL engine.\n");
1036 return 0;