diff options
author | Ton Roosendaal <ton@blender.org> | 2004-10-29 01:12:26 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2004-10-29 01:12:26 +0400 |
commit | 1b293777b8deffda223418404d276df5975fb244 (patch) | |
tree | 5818eff5a960ef0f34c278d20db48823eea49a14 /source | |
parent | 8c0b126bc2f9549eaae59f056f78812540c670a6 (diff) |
Brought back overkill of displist creation for armatures and deform...
Got some testfiles that I cannot get to work quickly, better do this
after release (again)
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/armature.c | 3 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/displist.c | 29 |
2 files changed, 17 insertions, 15 deletions
diff --git a/source/blender/blenkernel/intern/armature.c b/source/blender/blenkernel/intern/armature.c index 0c30e53ec16..d0ee75df1a3 100644 --- a/source/blender/blenkernel/intern/armature.c +++ b/source/blender/blenkernel/intern/armature.c @@ -1197,11 +1197,12 @@ void make_displists_by_armature (Object *ob) for (base= G.scene->base.first; base; base= base->next){ if ((ob==base->object->parent) && (base->lay & G.scene->lay)) if ((base->object->partype==PARSKEL) || (base->object->type==OB_MBALL)) - freedisplist(&base->object->disp); + makeDispList(base->object); } } /* (ton) changed this; now a free displist is sufficient, drawobject.c will make disp +(ton) changed it back... doesnt work yet, do it after release */ } diff --git a/source/blender/blenkernel/intern/displist.c b/source/blender/blenkernel/intern/displist.c index 3c73643ebad..9ab1606af1b 100644 --- a/source/blender/blenkernel/intern/displist.c +++ b/source/blender/blenkernel/intern/displist.c @@ -2331,6 +2331,7 @@ void test_all_displists(void) Base *base; Object *ob; unsigned int lay; + int makedisp; /* background */ lay= G.scene->lay; @@ -2339,6 +2340,7 @@ void test_all_displists(void) while(base) { if(base->lay & lay) { ob= base->object; + makedisp= 0; if(ob->type==OB_MBALL && (ob->ipo || ob->parent)) { // find metaball object holding the displist @@ -2349,24 +2351,23 @@ void test_all_displists(void) if(ob->disp.first == NULL) { ob= find_basis_mball(ob); } - freedisplist(&ob->disp); + makedisp= 1; } else if(ob->parent) { if (ob->parent->type == OB_LATTICE) - freedisplist_object(ob); - else if ((ob->parent->type == OB_IKA) && (ob->partype == PARSKEL)) - freedisplist_object(ob); + makedisp= 1; else if ((ob->parent->type==OB_ARMATURE) && (ob->partype == PARSKEL)) - freedisplist_object(ob); + makedisp= 1; else if ((ob->parent->type==OB_CURVE) && (ob->partype == PARSKEL)) - freedisplist_object(ob); + makedisp= 1; } if(ob->hooks.first) { ObHook *hook; for(hook= ob->hooks.first; hook; hook= hook->next) { - if(hook->parent) freedisplist_object(ob); + if(hook->parent) + makedisp= 1; break; } } @@ -2378,14 +2379,14 @@ void test_all_displists(void) if(ob!=G.obedit) { Curve *cu= ob->data; - if(cu->key ) freedisplist_object(ob); //makeDispList(ob); + if(cu->key ) makedisp= 1; if(cu->bevobj) { Curve *cu1= cu->bevobj->data; - if(cu1->key ) freedisplist_object(ob); + if(cu1->key ) makedisp= 1; } if(cu->taperobj) { Curve *cu1= cu->taperobj->data; - if(cu1->key ) freedisplist_object(ob); + if(cu1->key ) makedisp= 1; } } } @@ -2394,7 +2395,7 @@ void test_all_displists(void) if(cu->textoncurve) { if( ((Curve *)cu->textoncurve->data)->key ) { text_to_curve(ob, 0); - freedisplist_object(ob); //makeDispList(ob); + makedisp= 1; } } } @@ -2403,7 +2404,7 @@ void test_all_displists(void) Effect *eff= ob->effect.first; while(eff) { if(eff->type==EFF_WAVE) { - freedisplist_object(ob); + makedisp= 1; break; } eff= eff->next; @@ -2411,10 +2412,10 @@ void test_all_displists(void) } if(ob!=G.obedit) { if(( ((Mesh *)(ob->data))->key )) - freedisplist_object(ob); + makedisp= 1; } } - + if(makedisp) makeDispList(ob); } if(base->next==0 && G.scene->set && base==G.scene->base.last) base= G.scene->set->base.first; else base= base->next; |