11.07.2015 Views

mental ray Architectural and Design Visualization Shader Library

mental ray Architectural and Design Visualization Shader Library

mental ray Architectural and Design Visualization Shader Library

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

74 3 Sun <strong>and</strong> Skymultiplier sets the intensity <strong>and</strong> tint color modifies the light color. When it is white, <strong>and</strong>the multiplier is 1.0, the light emitted is equal in intensity (<strong>and</strong> color) to the environmentlight that FG would have seen if allowed to send many thous<strong>and</strong>s of FG <strong>ray</strong>s 6 .The light normally shines in the positive Z direction of the light instance’s coordinate space.If reverse is on, it shines in the negative Z direction.cutoff threshold is a performance optimization option. Any light below this level is ignored,<strong>and</strong> no shadow <strong>ray</strong>s are traced (which is what consumes the bulk of the render time of an arealight). Of course, this makes the scene slightly darker since light is ignored, but can save a lotof excess render time.shadows can turn shadows on <strong>and</strong> off.If use custom environment is off, the shader looks in the global camera environment forthe color of the light. If it is on, it calls the shader passed as custom environment to findthe color.Tip: While the shader is intended to be a portal to an environment, one can also treat it as a“light card” shader by putting a shader returning a solid color as the custom environment,for example using mib blackbody creates a light card with a given color temperature.If use custom environment is on but no custom environment is actually passed, theshader behaves as a white light card.visible defines if the light emitting surface is visible or not. When off, eye <strong>ray</strong>s, reflection<strong>ray</strong>s etc. go straight through so the portal light itself remains unseen (<strong>and</strong> we still “see”out the window). When on, the actual light emitting surface becomes visible to eye <strong>ray</strong>s,reflection <strong>ray</strong>s etc (<strong>and</strong> one do not “see” out the window any more, although one still “see”the environment shaders result). The on mode is useful when using mia portal light as a lightcard shader.When lookup using fg <strong>ray</strong>s is off, the environment shader is looked up with a normal callto mi trace environment(). However, some shaders behave differently if they are called byan FG <strong>ray</strong> or by another <strong>ray</strong> (the mia physicalsky shader, for example, does not show the“image” of the visible sun to FG <strong>ray</strong>s). Since the idea of mia portal light is to act as an “FGconcentrator” it should therefore follow that behavior. So when lookup using fg <strong>ray</strong>s is on,it calls the environment with the <strong>ray</strong> type set to miRAY FINALGATHER, so that shadersthat switch behavior based on this can return the color appropriate for a FG <strong>ray</strong>.If shadow <strong>ray</strong> extension is zero, the shader begins tracing shadow <strong>ray</strong>s “at” the light. Whenpositive, the shadow <strong>ray</strong>s actually start that distance “outdoors”. So if there is a large objectjust outside the window, it’s shadow will be taken into account. Conversely, a negative valueallows the shadow <strong>ray</strong>s to begin that distance inside the window, which can allow them to“skip” over troublesome geometry near the window (flowers, curtains) that would otherwisejust introduce noise into the shadows.6 For FG filter 0, the unbiased mode.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!