diff options
author | Miika Hamalainen <blender@miikah.org> | 2011-11-09 19:46:53 +0400 |
---|---|---|
committer | Miika Hamalainen <blender@miikah.org> | 2011-11-09 19:46:53 +0400 |
commit | 1b4a54ad73c058baa59ffdc9e5f18b0b79030fb0 (patch) | |
tree | a5b84d392ea14b0d760a5e24f7a8e51f203d558c /source/blender/blenloader | |
parent | edec46b0a6aac18f406991b9e16228d4bd848c61 (diff) | |
parent | bc5ec4e69cf3308c2563239c0e8372b853800a78 (diff) |
Merge with trunk r41701soc-2011-carrot
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index a870dcc2e94..ca98849a469 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -5646,6 +5646,7 @@ static void direct_link_screen(FileData *fd, bScreen *sc) else if(sl->spacetype==SPACE_BUTS) { SpaceButs *sbuts= (SpaceButs *)sl; sbuts->path= NULL; + sbuts->texuser= NULL; } else if(sl->spacetype==SPACE_CONSOLE) { SpaceConsole *sconsole= (SpaceConsole *)sl; @@ -6026,7 +6027,7 @@ static BHead *read_libblock(FileData *fd, Main *main, BHead *bhead, int flag, ID if(id->flag & LIB_FAKEUSER) id->us= 1; else id->us= 0; id->icon_id = 0; - id->flag &= ~LIB_ID_RECALC; + id->flag &= ~(LIB_ID_RECALC|LIB_ID_RECALC_DATA); /* this case cannot be direct_linked: it's just the ID part */ if(bhead->code==ID_ID) { @@ -7270,6 +7271,22 @@ static void do_versions_nodetree_image_default_alpha_output(bNodeTree *ntree) } } +static void do_version_ntree_tex_mapping_260(void *UNUSED(data), ID *UNUSED(id), bNodeTree *ntree) +{ + bNode *node; + + for(node=ntree->nodes.first; node; node=node->next) { + if(node->type == SH_NODE_MAPPING) { + TexMapping *tex_mapping; + + tex_mapping= node->storage; + tex_mapping->projx= PROJ_X; + tex_mapping->projy= PROJ_Y; + tex_mapping->projz= PROJ_Z; + } + } +} + static void do_versions(FileData *fd, Library *lib, Main *main) { /* WATCH IT!!!: pointers from libdata have not been converted */ @@ -12355,6 +12372,13 @@ static void do_versions(FileData *fd, Library *lib, Main *main) } } + if (main->versionfile < 260 || (main->versionfile == 260 && main->subversionfile < 2)) { + bNodeTreeType *ntreetype= ntreeGetType(NTREE_SHADER); + + if(ntreetype && ntreetype->foreach_nodetree) + ntreetype->foreach_nodetree(main, NULL, do_version_ntree_tex_mapping_260); + } + /* put compatibility code here until next subversion bump */ { { |