diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-03-26 12:10:12 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-03-26 12:10:12 +0400 |
commit | ce4eb573017550c37e8119681a1e83c2e646c66f (patch) | |
tree | 6095b0d2f19876eb1371a164479d7c64f3986fed /source/blender/blenkernel | |
parent | 4ade85612c95c81d3d45826a93bd24ee9c3c9dd4 (diff) |
fix [#30653] Wrong image at UV/Image Editor window
render results would be displayed on loading new files if the scene names matches, now free render-results so as not to display stale data - also saves some memory.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/blender.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/blender.c b/source/blender/blenkernel/intern/blender.c index 26c59129914..b8df30c5de9 100644 --- a/source/blender/blenkernel/intern/blender.c +++ b/source/blender/blenkernel/intern/blender.c @@ -78,6 +78,7 @@ #include "BKE_screen.h" #include "BKE_sequencer.h" #include "BKE_sound.h" +#include "RE_pipeline.h" #include "BLO_undofile.h" @@ -199,6 +200,11 @@ static void setup_app_data(bContext *C, BlendFileData *bfd, const char *filepath recover= (G.fileflags & G_FILE_RECOVER); + /* Free all render results, without this stale data gets displayed after loading files */ + if (mode != 'u') { + RE_FreeAllRenderResults(); + } + /* Only make filepaths compatible when loading for real (not undo) */ if (mode != 'u') { clean_paths(bfd->main); |