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:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-11-28 21:55:01 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-11-28 21:55:01 +0400
commit3ff8ff90ea66481b2604c147312a3348daece0c6 (patch)
treeb6aebc0e6eb71556834bde499dd2fb97b94540f0 /source/blender/blenloader
parent9aaa67cc4c4e1116dffe802969ea3a17ff88e4d8 (diff)
Reset V3D_RENDER_SHADOW flag on file loading.
This flag shouldn't be saved in .blend files but because of strange reason some files contains this flags which leads to object disappearing when disabling buffer shadow in material. Current trunk shouldn't be saving this flag and most probably buggy files were saved in some intermediate version of blender where this flag can be be saved. This should fix remained issue in #29255: Object invisible and weird polygons appearance
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 3db36a075d7..61d023d7fc0 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -12608,6 +12608,7 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
{
Scene *sce;
MovieClip *clip;
+ bScreen *sc;
for(sce = main->scene.first; sce; sce = sce->id.next) {
if (sce->r.im_format.depth == 0) {
@@ -12626,6 +12627,19 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
settings->default_search_size= 51;
}
}
+
+ for (sc= main->screen.first; sc; sc= sc->id.next) {
+ ScrArea *sa;
+ for (sa= sc->areabase.first; sa; sa= sa->next) {
+ SpaceLink *sl;
+ for (sl= sa->spacedata.first; sl; sl= sl->next) {
+ if(sl->spacetype==SPACE_VIEW3D) {
+ View3D *v3d= (View3D *)sl;
+ v3d->flag2&= ~V3D_RENDER_SHADOW;
+ }
+ }
+ }
+ }
}
/* WATCH IT!!!: pointers from libdata have not been converted yet here! */