RenderMan Volume Shader

From K-3D

Jump to: navigation, search

Global Variables

The following table lists the set of global variables that can be used by volume shaders:

Name Type Storage Description
Ci color varying Attenuated ray color
Oi color varying Attenuated ray opacity
 
P point varying Light ray endpoint
I vector varying Ray direction (pointing toward P)
E point uniform Position of the eye
Ci color varying Ray color
Oi color varying Ray opacity
ncomps float uniform Number of color components
time float uniform Current shutter time
dtime float uniform The amount of time covered by this shading sample.

Geometry of Shading

A volume shader is not associated with a surface, but rather attenuates a ray color as it travels through space. As such, it does not have access to any geometric surface parameters, but only to the light ray I and its associated values. The shader computes the new ray color at the ray origin P

Personal tools