|
Are you doing a render region or a preview? If you’re using render region, make sure you enable caustics in the render region options, otherwise, if using the preview, enable them in the render options.
Alternatively you can simply set your region to use the current pass options and always enable caustics in there.
Also note that GI/Caustics do not work with infinite lights, which is the default scene light. You need to create a point/spot light and enable caustics with it.
Example:
NewScene ,false
' Delete the default light and create a new point light
DeleteObj "light"
GetPrimLight "Point.Preset", "Point"
Translate "Point", 5.0, 7.5, -4.0
SetValue "Point.light.Caustics", True
' Create grid
CreatePrim "Grid", "MeshSurface" SetValue "grid.grid.ulength", 32
SetValue "grid.grid.vlength", 32
SetValue "grid.visibility.causcast", True
' Create semi-transparent sphere
CreatePrim "Sphere", "NurbsSurface"
SetValue "sphere.sphere.radius", 2
Translate "sphere", 0, 2.5, 0
ApplyShader "Phong", "sphere"
SetValue "sphere.Material.Phong.transparency.red", 0.75
SetValue "sphere.Material.Phong.transparency.green", 0.75
SetValue "sphere.Material.Phong.transparency.blue", 0.75
SetValue "sphere.visibility.causcast", True
' Set the region to use the current options ' and make sure caustics and photon map rebuild is on.
SetValue "Views.ViewA.RenderRegion.UsePassOptions,Views.ViewB.RenderRegion.UsePassOptions,Views.ViewC.RenderRegion.UsePassOptions,Views.ViewD.RenderRegion.UsePassOptions", Array(True, True, True, True)
SetValue "Passes.mentalray.CausticEnable", True
SetValue "Passes.mentalray.PhotonMapRebuild", True
RenderRegionCreate siViewportB
|