diff --git a/clutter/clutter-debug.h b/clutter/clutter-debug.h index 90f352ef1..75ead7114 100644 --- a/clutter/clutter-debug.h +++ b/clutter/clutter-debug.h @@ -22,7 +22,8 @@ typedef enum { CLUTTER_DEBUG_SHADER = 1 << 12, CLUTTER_DEBUG_MULTISTAGE = 1 << 13, CLUTTER_DEBUG_ANIMATION = 1 << 14, - CLUTTER_DEBUG_LAYOUT = 1 << 15 + CLUTTER_DEBUG_LAYOUT = 1 << 15, + CLUTTER_DEBUG_PICK = 1 << 16 } ClutterDebugFlag; typedef enum { diff --git a/clutter/clutter-main.c b/clutter/clutter-main.c index 076ff1a44..417d58027 100644 --- a/clutter/clutter-main.c +++ b/clutter/clutter-main.c @@ -156,6 +156,7 @@ static const GDebugKey clutter_debug_keys[] = { { "texture", CLUTTER_DEBUG_TEXTURE }, { "event", CLUTTER_DEBUG_EVENT }, { "paint", CLUTTER_DEBUG_PAINT }, + { "pick", CLUTTER_DEBUG_PICK }, { "gl", CLUTTER_DEBUG_GL }, { "alpha", CLUTTER_DEBUG_ALPHA }, { "behaviour", CLUTTER_DEBUG_BEHAVIOUR }, @@ -637,6 +638,9 @@ _clutter_do_pick (ClutterStage *stage, pixel); CLUTTER_TIMER_STOP (_clutter_uprof_context, pick_read); + CLUTTER_NOTE (PICK, "Reusing pick buffer from previous render to fetch " + "actor at %i,%i", x, y); + /* FIXME: This is a lazy copy and paste of the logic at the end of this * function used when we actually do a pick render. It should be * consolidated somehow. @@ -672,6 +676,9 @@ _clutter_do_pick (ClutterStage *stage, else is_clipped = FALSE; + CLUTTER_NOTE (PICK, "Performing %s pick at %i,%i", + is_clipped ? "clippped" : "full", x, y); + cogl_disable_fog (); cogl_color_set_from_4ub (&stage_pick_id, 255, 255, 255, 255); CLUTTER_TIMER_START (_clutter_uprof_context, pick_clear);