These shaders return colors from color textures that are mapped to finite or infinite distances. They are useful for adding background or foreground plates to the rendered scene. Environments must be used for environment shaders, overlays must be used for lens shaders, and textures must be used for texture or material shaders on a plane or other object in the scene.
Given a texture shader, assume that the texture it produces is wrapped on an infinite sphere around the scene, evaluate the texture, and return the color. This is useful for environment shaders.
color "mib_lookup_spherical" (
vector "dir",
scalar "rotate",
color texture "tex")
Same as the spherical environment shader, but accept either one or six textures mapped on an infinite cube. This is useful for environment shaders.
color "mib_lookup_cube1" (
vector "point",
vector "dir",
vector "size",
color texture "tex")
color "mib_lookup_cube6" (
vector "point",
vector "dir",
vector "size",
color texture "tex_mx",
color texture "tex_px",
color texture "tex_my",
color texture "tex_py",
color texture "tex_mz",
color texture "tex_pz")
This environment shader is most useful for projecting regular patterns onto geometry, for example for surface quality control. The cylinder does not have caps, so it might happen that rays do not hit the cylinder. The cylinder is defined by a transformation which transforms from world to canonical cylinder space, and two scalars that allow cutting off part of the cylinder. If both begin and end are zero, a full cylinder is selected.
color "mib_lookup_cylindrical" (
transform "xform",
scalar "begin",
scalar "end",
color texture "tex" )
Given a texture shader, place it in the background of the scene such that the edges of the texture line up with the edges of the rendered image. Factors can be applied to stretch and pan the texture, to allow for lenses that bend rays away from the center. The purpose of this environment is inserting background plates. Returns a color. This is useful in three different types of shaders:
color "mib_lookup_background" (
vector "zoom",
vector "pan",
boolean "torus_u",
boolean "torus_v",
color texture "tex")
Copyright (©) 1986-2009 by mental images GmbH