summaryrefslogtreecommitdiff
path: root/legacy/evas
diff options
context:
space:
mode:
authorCedric BAIL <cedric.bail@free.fr>2010-05-05 11:36:21 +0000
committerCedric BAIL <cedric.bail@free.fr>2010-05-05 11:36:21 +0000
commit7bcd87e551f58087b4d80693a8c006a32d1be368 (patch)
tree93b2378d41cb7b30a6d5a14471fab1689d921af0 /legacy/evas
parentbb85e11b50d21dbcfe4933c14bdeeb18e58d999b (diff)
* evas: bring back object cache.
SVN revision: 48620
Diffstat (limited to 'legacy/evas')
-rw-r--r--legacy/evas/src/lib/canvas/evas_render.c46
1 files changed, 25 insertions, 21 deletions
diff --git a/legacy/evas/src/lib/canvas/evas_render.c b/legacy/evas/src/lib/canvas/evas_render.c
index 039e9ebe6c..e871e9e819 100644
--- a/legacy/evas/src/lib/canvas/evas_render.c
+++ b/legacy/evas/src/lib/canvas/evas_render.c
@@ -483,7 +483,7 @@ _evas_render_phase1_process(Evas *e,
483static void 483static void
484_evas_render_check_pending_objects(Eina_Array *pending_objects, Evas *e) 484_evas_render_check_pending_objects(Eina_Array *pending_objects, Evas *e)
485{ 485{
486 int i; 486 unsigned int i;
487 487
488 for (i = 0; i < pending_objects->count; ++i) 488 for (i = 0; i < pending_objects->count; ++i)
489 { 489 {
@@ -568,7 +568,7 @@ pending_change(void *data, void *gdata __UNUSED__)
568 return obj->changed ? EINA_TRUE : EINA_FALSE; 568 return obj->changed ? EINA_TRUE : EINA_FALSE;
569} 569}
570 570
571static void 571static Eina_Bool
572evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface, 572evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
573 int off_x, int off_y, int mapped 573 int off_x, int off_y, int mapped
574#ifdef REND_DGB 574#ifdef REND_DGB
@@ -578,6 +578,7 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
578{ 578{
579 void *ctx; 579 void *ctx;
580 Evas_Object *obj2; 580 Evas_Object *obj2;
581 Eina_Bool clean_them = EINA_FALSE;
581 582
582 evas_object_clip_recalc(obj); 583 evas_object_clip_recalc(obj);
583 RDI(level); 584 RDI(level);
@@ -589,7 +590,7 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
589 { 590 {
590 RDI(level); 591 RDI(level);
591 RD(" }\n"); 592 RD(" }\n");
592 return; 593 return clean_them;
593 } 594 }
594 } 595 }
595 else if (!(((evas_object_is_active(obj) && (!obj->clip.clipees) && 596 else if (!(((evas_object_is_active(obj) && (!obj->clip.clipees) &&
@@ -598,7 +599,7 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
598 { 599 {
599 RDI(level); 600 RDI(level);
600 RD(" }\n"); 601 RD(" }\n");
601 return; 602 return clean_them;
602 } 603 }
603 604
604 // set render_pre - for child objs that may not have gotten it. 605 // set render_pre - for child objs that may not have gotten it.
@@ -611,6 +612,8 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
611 int sw, sh; 612 int sw, sh;
612 int changed = 0, rendered = 0; 613 int changed = 0, rendered = 0;
613 614
615 clean_them = EINA_TRUE;
616
614 sw = obj->cur.geometry.w; 617 sw = obj->cur.geometry.w;
615 sh = obj->cur.geometry.h; 618 sh = obj->cur.geometry.h;
616 RDI(level); 619 RDI(level);
@@ -619,7 +622,7 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
619 { 622 {
620 RDI(level); 623 RDI(level);
621 RD(" }\n"); 624 RD(" }\n");
622 return; 625 return clean_them;
623 } 626 }
624 627
625 p = obj->cur.map->points; 628 p = obj->cur.map->points;
@@ -715,13 +718,13 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
715 EINA_INLIST_FOREACH 718 EINA_INLIST_FOREACH
716 (evas_object_smart_members_get_direct(obj), obj2) 719 (evas_object_smart_members_get_direct(obj), obj2)
717 { 720 {
718 evas_render_mapped(e, obj2, ctx, 721 clean_them |= evas_render_mapped(e, obj2, ctx,
719 obj->cur.map->surface, 722 obj->cur.map->surface,
720 off_x, off_y, 1 723 off_x, off_y, 1
721#ifdef REND_DGB 724#ifdef REND_DGB
722 , level + 1 725 , level + 1
723#endif 726#endif
724 ); 727 );
725 } 728 }
726 } 729 }
727 else 730 else
@@ -774,13 +777,13 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
774 EINA_INLIST_FOREACH 777 EINA_INLIST_FOREACH
775 (evas_object_smart_members_get_direct(obj), obj2) 778 (evas_object_smart_members_get_direct(obj), obj2)
776 { 779 {
777 evas_render_mapped(e, obj2, ctx, 780 clean_them |= evas_render_mapped(e, obj2, ctx,
778 surface, 781 surface,
779 off_x, off_y, 1 782 off_x, off_y, 1
780#ifdef REND_DGB 783#ifdef REND_DGB
781 , level + 1 784 , level + 1
782#endif 785#endif
783 ); 786 );
784 } 787 }
785 } 788 }
786 else 789 else
@@ -798,6 +801,8 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
798 } 801 }
799 RDI(level); 802 RDI(level);
800 RD(" }\n"); 803 RD(" }\n");
804
805 return clean_them;
801} 806}
802 807
803static Eina_List * 808static Eina_List *
@@ -1084,12 +1089,12 @@ evas_render_updates_internal(Evas *e,
1084 } 1089 }
1085 } 1090 }
1086#endif 1091#endif
1087 evas_render_mapped(e, obj, e->engine.data.context, 1092 clean_them |= evas_render_mapped(e, obj, e->engine.data.context,
1088 surface, off_x, off_y, 0 1093 surface, off_x, off_y, 0
1089#ifdef REND_DGB 1094#ifdef REND_DGB
1090 , 1 1095 , 1
1091#endif 1096#endif
1092 ); 1097 );
1093 e->engine.func->context_cutout_clear(e->engine.data.output, 1098 e->engine.func->context_cutout_clear(e->engine.data.output,
1094 e->engine.data.context); 1099 e->engine.data.context);
1095 } 1100 }
@@ -1176,8 +1181,7 @@ evas_render_updates_internal(Evas *e,
1176 1181
1177 /* If their are some object to restack or some object to delete, 1182 /* If their are some object to restack or some object to delete,
1178 * it's useless to keep the render object list around. */ 1183 * it's useless to keep the render object list around. */
1179// if (clean_them) 1184 if (clean_them)
1180 if (1)
1181 { 1185 {
1182 eina_array_clean(&e->active_objects); 1186 eina_array_clean(&e->active_objects);
1183 eina_array_clean(&e->render_objects); 1187 eina_array_clean(&e->render_objects);