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-10-10 18:32:08 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-10-10 18:32:08 +0400
commit21a755b4f50413e7c1404896b0d78e599bad9c65 (patch)
tree0758d2ed918eb3a97585b3a0b35e4db0883e83b7 /source/blender/blenloader
parent90b3bd84daf24199aa8b389277a88dd722f7ab06 (diff)
Fix #28857: 2.60 rc1 regression?
If displacement mapping is used, normals shouldn't be flipped.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 9ba539acb16..38b4a773650 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -12123,12 +12123,14 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
if(mtex) {
if((mtex->texflag&MTEX_BUMP_FLIPPED)==0) {
- if((mtex->mapto&MAP_NORM) && mtex->texflag&(MTEX_COMPAT_BUMP|MTEX_3TAP_BUMP|MTEX_5TAP_BUMP)) {
- Tex *tex= newlibadr(fd, lib, mtex->tex);
+ if((mtex->mapto&MAP_DISPLACE)==0) {
+ if((mtex->mapto&MAP_NORM) && mtex->texflag&(MTEX_COMPAT_BUMP|MTEX_3TAP_BUMP|MTEX_5TAP_BUMP)) {
+ Tex *tex= newlibadr(fd, lib, mtex->tex);
- if(!tex || (tex->imaflag&TEX_NORMALMAP)==0) {
- mtex->norfac= -mtex->norfac;
- mtex->texflag|= MTEX_BUMP_FLIPPED;
+ if(!tex || (tex->imaflag&TEX_NORMALMAP)==0) {
+ mtex->norfac= -mtex->norfac;
+ mtex->texflag|= MTEX_BUMP_FLIPPED;
+ }
}
}
}