Bugfix #4882
New toolsettings variable "select_thresh" was not initialized. This caused the option "similar normals" to not work really (uses a dot product). It now is initialized (scene.c) as well as corrected in do_versions for saved files.
This commit is contained in:
@@ -224,6 +224,7 @@ Scene *add_scene(char *name)
|
||||
sce->toolsettings->uvcalc_mapdir = 1;
|
||||
sce->toolsettings->uvcalc_mapalign = 1;
|
||||
sce->toolsettings->unwrapper = 1;
|
||||
sce->toolsettings->select_thresh= 0.01f;
|
||||
|
||||
sce->jumpframe = 10;
|
||||
sce->audio.mixrate = 44100;
|
||||
|
||||
@@ -5561,7 +5561,15 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(main->versionfile <= 242) {
|
||||
Scene *sce;
|
||||
|
||||
for(sce= main->scene.first; sce; sce= sce->id.next) {
|
||||
if (sce->toolsettings->select_thresh == 0.0f)
|
||||
sce->toolsettings->select_thresh= 0.01f;
|
||||
}
|
||||
}
|
||||
|
||||
/* WATCH IT!!!: pointers from libdata have not been converted yet here! */
|
||||
/* WATCH IT 2!: Userdef struct init has to be in src/usiblender.c! */
|
||||
|
||||
Reference in New Issue
Block a user