Revision: 48367
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=48367
Author:   nazgul
Date:     2012-06-28 10:05:22 +0000 (Thu, 28 Jun 2012)
Log Message:
-----------
Move color management check stuff from blo_read_file_internal to setup_app_data

Modified Paths:
--------------
    branches/soc-2011-tomato/source/blender/blenkernel/intern/blender.c
    branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c

Modified: branches/soc-2011-tomato/source/blender/blenkernel/intern/blender.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenkernel/intern/blender.c 
2012-06-28 09:37:30 UTC (rev 48366)
+++ branches/soc-2011-tomato/source/blender/blenkernel/intern/blender.c 
2012-06-28 10:05:22 UTC (rev 48367)
@@ -91,6 +91,8 @@
 
 #include "WM_api.h" // XXXXX BAD, very BAD dependency (bad level call) - 
remove asap, elubie
 
+#include "IMB_colormanagement.h"
+
 #ifdef WITH_PYTHON
 #include "BPY_extern.h"
 #endif
@@ -324,7 +326,11 @@
 
        /* baseflags, groups, make depsgraph, etc */
        BKE_scene_set_background(G.main, CTX_data_scene(C));
-       
+
+       if (mode != 'u') {
+               IMB_colormanagement_check_file_config(G.main);
+       }
+
        MEM_freeN(bfd);
 
        (void)curscene; /* quiet warning */

Modified: branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c        
2012-06-28 09:37:30 UTC (rev 48366)
+++ branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c        
2012-06-28 10:05:22 UTC (rev 48367)
@@ -144,7 +144,6 @@
 #include "BKE_sound.h"
 
 #include "IMB_imbuf.h"  // for proxy / timecode versioning stuff
-#include "IMB_colormanagement.h"
 
 #include "NOD_socket.h"
 
@@ -8009,12 +8008,6 @@
        
        link_global(fd, bfd);   /* as last */
 
-       /* OCIO_TODO: is there nicer place for this? */
-       /* ... no its not, perhaps setup_app_data? - campbell */
-       if (fd->memfile == NULL) {  /* don't do this for UNDO */
-               IMB_colormanagement_check_file_config(bfd->main);
-       }
-
        return bfd;
 }
 

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to