The volume location is used to invoke volume plugins or turn specific primitives into volumes.  All volume locations will look for the following attributes:

  • float attribute arnoldStatements.step_size, although this is only required to be set for sphere and box geometry types (see below).  The arnoldStatements.step_size attribute can be set in the ArnoldObjectSettings node.
  • float attribute arnoldStatements.bounds_slack, which optionally expands the volume bounds to account for upres and displacement via the volume shader's position.  This can be set on the ArnoldObjectSettings node.
  • Any arbitrary user data (geometry.arbitrary) will be passed along to Arnold, although only the primitive (Arnold constant) scope data will be passed along.  For convenience, these attributes can be set up with the ArnoldUserData node.

geometry.type

Locations of type volume have a standard attribute geometry.type which indicates what the rest of the attributes mean.  The Katana documentation indicates this is is a PRMan-only location type, but KtoA also uses it and expects geometry.type to be one of the following strings:

  • volumedso
  • volumeplugin
  • sphere
  • box

Type volumedso and volumeplugin

These are synonyms, and indicate that KtoA is to translate this as an Arnold volume  node (Arnold 4.2.x) or as a custom volume node (Arnold 5.0).  Once the type is indicated, it will further search for the rendererProcedural attribute group and translate the arguments as if this were a renderer procedural.  This is because Arnold volume plugins are very similar to procedural plugins except for a few parameters that are volume-specific (such as step_size).  Note that the step size is not required to be set, and if it is missing the volume plugin will compute a natural step size for the volume.

 

For more information on procedural arguments that can be passed along to each specific volume plugin, please see the page on procedural locations.

Type sphere

This type requires the arnoldStatements.step_size attribute to be set. It also looks for the geometry.radius attribute to control the size of the sphere volume.

Type box

This type requires the arnoldStatements.step_size attribute to be set. It also looks for the bound attribute to control the size of the box volume (the bound consisting of 6 doubles in order of xmin, xmax, ymin, ymax, zmin, zmax).

 

 

  • No labels