Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2005-04-10 04:00:34 +0400
committerDaniel Dunbar <daniel@zuster.org>2005-04-10 04:00:34 +0400
commitb1675a345af475486e85756a5d18c8cf7243bacb (patch)
tree0d4dc9f7d01c7fff3fa814c125b5b6f4829aaacf
parentae91ba8ba6c08a734d588dc46a2ecded4459e3fd (diff)
- made shadedisplist not free all object displist data...
this messed with data caches which messed with assumptions made by drawing code (and was just silly not to mention). here be dragons...
-rw-r--r--source/blender/blenkernel/intern/displist.c11
-rw-r--r--source/blender/src/drawobject.c2
-rw-r--r--source/blender/src/vpaint.c2
3 files changed, 7 insertions, 8 deletions
diff --git a/source/blender/blenkernel/intern/displist.c b/source/blender/blenkernel/intern/displist.c
index 6fc0077d275..1164e46136e 100644
--- a/source/blender/blenkernel/intern/displist.c
+++ b/source/blender/blenkernel/intern/displist.c
@@ -797,10 +797,12 @@ void shadeDispList(Object *ob)
/* we extract dl_verts, deform info */
dldeform= find_displist(&ob->disp, DL_VERTS);
- if(dldeform) BLI_remlink(&ob->disp, dldeform);
- /* Metaballs have the standard displist in the Object */
- if(ob->type!=OB_MBALL) freedisplist(&ob->disp);
+ dl = find_displist(&ob->disp, DL_VERTCOL);
+ if (dl) {
+ BLI_remlink(&ob->disp, dl);
+ free_disp_elem(dl);
+ }
need_orco= 0;
for(a=0; a<ob->totcol; a++) {
@@ -1169,9 +1171,6 @@ void shadeDispList(Object *ob)
ma= give_current_material(ob, a+1);
if(ma) end_render_material(ma);
}
-
- /* this one was temporally removed */
- if(dldeform) BLI_addtail(&ob->disp, dldeform);
}
void reshadeall_displist(void)
diff --git a/source/blender/src/drawobject.c b/source/blender/src/drawobject.c
index 309cc7b449e..fa4ac4773a6 100644
--- a/source/blender/src/drawobject.c
+++ b/source/blender/src/drawobject.c
@@ -1783,7 +1783,7 @@ static void draw_mesh_fancy(Object *ob, DerivedMesh *baseDM, DerivedMesh *realDM
dl = ob->disp.first;
if (!dl || !dl->col1) {
shadeDispList(ob);
- dl = ob->disp.first;
+ dl = find_displist(&ob->disp, DL_VERTCOL);
}
obCol1 = dl->col1;
obCol2 = dl->col2;
diff --git a/source/blender/src/vpaint.c b/source/blender/src/vpaint.c
index 3c584b850e8..35704851d74 100644
--- a/source/blender/src/vpaint.c
+++ b/source/blender/src/vpaint.c
@@ -247,7 +247,7 @@ void make_vertexcol() /* single ob */
if(dl==0 || dl->col1==NULL) {
shadeDispList(ob);
- dl= ob->disp.first;
+ dl= find_displist(&ob->disp, DL_VERTCOL);
}
if(dl && dl->col1) {
int i;