[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [12278] trunk/blender/source/blender/ render/intern/source/rayshade.c: * Fix for bug # 7396 " Refraction Pass Being added to combined when not told to"

Matt Ebb matt at mke3.net
Thu Oct 18 11:18:04 CEST 2007


Revision: 12278
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=12278
Author:   broken
Date:     2007-10-18 11:18:04 +0200 (Thu, 18 Oct 2007)

Log Message:
-----------
* Fix for bug # 7396 "Refraction Pass Being added to combined when not told to"

For the record, I think the way these reflection and refraction passes are handled (as a difference against the diffuse pass) is not very useful - especially if you want to do colour corrections, blurring, etc. It would be much more practical for the passes to contain the ray result returned by the raytrace... 

Modified Paths:
--------------
    trunk/blender/source/blender/render/intern/source/rayshade.c

Modified: trunk/blender/source/blender/render/intern/source/rayshade.c
===================================================================
--- trunk/blender/source/blender/render/intern/source/rayshade.c	2007-10-18 07:06:01 UTC (rev 12277)
+++ trunk/blender/source/blender/render/intern/source/rayshade.c	2007-10-18 09:18:04 UTC (rev 12278)
@@ -1098,8 +1098,8 @@
 		if(shi->passflag & SCE_PASS_REFRACT)
 			VECSUB(shr->refr, diff, olddiff);
 		
-		if(shi->combinedflag & SCE_PASS_REFRACT)
-			VECCOPY(olddiff, diff);
+		if(!(shi->combinedflag & SCE_PASS_REFRACT))
+			VECSUB(diff, diff, shr->refr);
 		
 		shr->alpha= tracol[3];
 	}





More information about the Bf-blender-cvs mailing list