Assorted small volume render related fixes.
[blender.git] / source / blender / render / intern / source / rayshade.c
index ed52f37fcfa337cb7271b242538389bc0c9de5b2..b4a43373ef490e9574709676a1973e274709b213 100644 (file)
@@ -558,19 +558,9 @@ void shade_ray(Isect *is, ShadeInput *shi, ShadeResult *shr)
                        shi->mat= vlr->mat;             /* shi->mat is being set in nodetree */
                }
                else {
-                       int tempdepth;
-                       /* XXX dodgy business here, set ray depth to -1
-                        * to ignore raytrace in shade_material_loop()
-                        * this could really use a refactor --Matt */
-                       if (shi->volume_depth == 0) {
-                               tempdepth = shi->depth;
-                               shi->depth = -1;
-                               shade_material_loop(shi, shr);
-                               shi->depth = tempdepth;
-                       } else {
-                               shade_material_loop(shi, shr);
-                       }
+                       shade_material_loop(shi, shr);
                }
+               
                /* raytrace likes to separate the spec color */
                VECSUB(shr->diff, shr->combined, shr->spec);
        }