#include "evas_render2.h"
/* Enable this for extra verbose rendering debug logs */
-//#define REND_DBG
+//#define REND_DBG 1
#define STDOUT_DBG
#ifdef REND_DBG
static FILE *dbf = NULL;
static int __RD_level = 0;
+static int __RD_enable = REND_DBG;
static void
rend_dbg(const char *txt)
fflush(dbf);
}
#define RD(xxxx, args...) \
- do { \
+ do { if (__RD_enable) { \
char __tmpbuf[4096]; int __tmpi; \
__RD_level = xxxx; \
if (xxxx) { \
} \
snprintf(__tmpbuf, sizeof(__tmpbuf), ##args); \
rend_dbg(__tmpbuf); \
- } while (0)
+ } } while (0)
#define IFRD(ifcase, xxxx, args...) \
- if (ifcase) { \
+ if (__RD_enable && (ifcase)) { \
char __tmpbuf[4096]; int __tmpi; \
__RD_level = xxxx; \
if (xxxx) { \
int fx, int fy,
Eina_Bool alpha,
Eina_Bool do_async,
- unsigned int *offset)
+ unsigned int *offset, int level)
{
Evas_Object *eo_obj;
Evas_Object_Protected_Data *obj;
Eina_Bool clean_them = EINA_FALSE;
eina_evlog("+render_setup", eo_e, 0.0, NULL);
- RD(0, " [--- UPDATE %i %i %ix%i\n", ux, uy, uw, uh);
+ RD(level, " [--- UPDATE %i %i %ix%i\n", ux, uy, uw, uh);
off_x = cx - ux;
off_y = cy - uy;
if (obj == top) break;
/* if it's in our outpout rect and it doesn't clip anything */
- RD(0, " OBJ: [%p", obj);
+ RD(level, " OBJ: [%p", obj);
IFRD(obj->name, 0, " '%s'", obj->name);
- RD(0, "] '%s' %i %i %ix%i\n", obj->type, obj->cur->geometry.x, obj->cur->geometry.y, obj->cur->geometry.w, obj->cur->geometry.h);
+ RD(level, "] '%s' %i %i %ix%i\n", obj->type, obj->cur->geometry.x, obj->cur->geometry.y, obj->cur->geometry.w, obj->cur->geometry.h);
if ((evas_object_is_in_output_rect(eo_obj, obj, ux - fx, uy - fy, uw, uh) ||
(obj->is_smart)) &&
(!obj->clip.clipees) &&
{
int x, y, w, h;
- RD(0, " DRAW (vis: %i, a: %i, clipees: %p)\n", obj->cur->visible, obj->cur->color.a, obj->clip.clipees);
+ RD(level, " DRAW (vis: %i, a: %i, clipees: %p)\n", obj->cur->visible, obj->cur->color.a, obj->clip.clipees);
if ((e->temporary_objects.count > *offset) &&
(eina_array_data_get(&e->temporary_objects, *offset) == obj))
(*offset)++;
surface, off_x + fx,
off_y + fy, 0,
cx, cy, cw, ch,
- NULL, 4,
+ NULL, level + 3,
EINA_FALSE,
do_async);
e->engine.func->context_cutout_clear(e->engine.data.output,
eina_evlog("-render_objects", eo_e, 0.0, NULL);
/* free obscuring objects list */
OBJS_ARRAY_CLEAN(&e->temporary_objects);
- RD(0, " ---]\n");
+ if (top) RD(level, " ---] SNAPSHOT [obj:%p sfc:%p]\n", top, surface);
+ else RD(level, " ---]\n");
return clean_them;
}
pseudo_canvas = _evas_object_image_surface_get(obj->object, obj);
+ RD(0, " SNAPSHOT [obj:%p sfc:%p ur:%d,%d %dx%d]\n", obj, pseudo_canvas, ur.x, ur.y, ur.w, ur.h);
ctx = e->engine.func->context_new(e->engine.data.output);
clean_them |= evas_render_updates_internal_loop(eo_e, e, pseudo_canvas, ctx,
obj,
cr.x, cr.y, cr.w, cr.h,
fx, fy, alpha,
do_async,
- &offset);
+ &offset, 1);
e->engine.func->context_free(e->engine.data.output, ctx);
// Force the object has changed for filter to take it into
cx, cy, cw, ch,
fx, fy, alpha,
do_async,
- &offset);
+ &offset, 0);
if (!do_async)
{
eina_evlog("+render_push", eo_e, 0.0, NULL);