[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [28353] branches/render25/source/blender/ render/intern/source/bake.c: Render Branch: merge over revision 27931 from trunk, missed this somehow.
Brecht Van Lommel
brecht at blender.org
Thu Apr 22 19:18:03 CEST 2010
Revision: 28353
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=28353
Author: blendix
Date: 2010-04-22 19:18:03 +0200 (Thu, 22 Apr 2010)
Log Message:
-----------
Render Branch: merge over revision 27931 from trunk, missed this somehow.
Revision Links:
--------------
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=27931
Modified Paths:
--------------
branches/render25/source/blender/render/intern/source/bake.c
Modified: branches/render25/source/blender/render/intern/source/bake.c
===================================================================
--- branches/render25/source/blender/render/intern/source/bake.c 2010-04-22 16:47:25 UTC (rev 28352)
+++ branches/render25/source/blender/render/intern/source/bake.c 2010-04-22 17:18:03 UTC (rev 28353)
@@ -704,10 +704,11 @@
for(ima= G.main->image.first; ima; ima= ima->id.next) {
ImBuf *ibuf= BKE_image_get_ibuf(ima, NULL);
ima->id.flag |= LIB_DOIT;
- if (ibuf)
+ if(ibuf) {
ibuf->userdata = NULL; /* use for masking if needed */
- if(ibuf->rect_float)
- ibuf->profile = IB_PROFILE_LINEAR_RGB;
+ if(ibuf->rect_float)
+ ibuf->profile = IB_PROFILE_LINEAR_RGB;
+ }
}
BLI_init_threads(&threads, do_bake_thread, re->params.r.threads);
@@ -755,8 +756,12 @@
for(ima= G.main->image.first; ima; ima= ima->id.next) {
if((ima->id.flag & LIB_DOIT)==0) {
ImBuf *ibuf= BKE_image_get_ibuf(ima, NULL);
- if (re->params.r.bake_filter) {
- if (usemask) {
+
+ if(!ibuf)
+ continue;
+
+ if(re->params.r.bake_filter) {
+ if(usemask) {
/* extend the mask +2 pixels from the image,
* this is so colors dont blend in from outside */
char *temprect;
@@ -785,8 +790,9 @@
ibuf->userdata= NULL;
}
}
+
ibuf->userflags |= IB_BITMAPDIRTY;
- if (ibuf->rect_float) IMB_rect_from_float(ibuf);
+ if(ibuf->rect_float) IMB_rect_from_float(ibuf);
}
}
More information about the Bf-blender-cvs
mailing list