Encapsulates the functionality common to all volume lights.
#include <AlVolumeLight.h> class AlVolumeLight: public AlLight virtual ~AlVolumeLight(); virtual AlObject* copyWrapper() const; virtual AlObjectType type() const; boolean shadows() const; boolean specular() const; boolean turbulenceAnimated() const; boolean turbulenceDirectional() const; int turbulenceSpaceRes() const; int turbulenceTimeRes() const; double intensity() const; double decay() const; double decayStart() const; double directionality() const; double concentric() const; double directional() const; double radial() const; double dropoff() const; double dropoffStart() const; double turbulenceIntensity() const; double turbulenceSpread() const; double turbulencePersistance() const; double turbulenceGranularity() const; double turbulenceRoughness() const; double turbulenceVariability() const; statusCode setShadows(boolean); statusCode setSpecular(boolean); statusCode setTurbulenceAnimated(boolean); statusCode setTurbulenceDirectional(boolean); statusCode setTurbulenceSpaceRes(int); statusCode setTurbulenceTimeRes(int); statusCode setIntensity( double ); statusCode setDecay(double); statusCode setDecayStart(double); statusCode setDirectionality(double); statusCode setConcentric(double); statusCode setDirectional(double); statusCode setRadial(double); statusCode setDropoff(double); statusCode setDropoffStart(double); statusCode setTurbulenceIntensity(double); statusCode setTurbulenceSpread(double); statusCode setTurbulencePersistance(double); statusCode setTurbulenceGranularity(double); statusCode setTurbulenceRoughness(double); statusCode setTurbulenceVariability(double);
There are two ways that this class is used. If the user instantiates and calls the create method on an AlVolumeLight, the resulting object is a box volume light. This light has all the special effects parameters in a cubic volume.
Alternatively, the user could instantiate and create an AlSphereLight, AlCylinderLight, AlTorusLight, AlConeLight or AlBoxLight (which are all considered "volume" and which are all derived from this light class).
Note that volume lights differ in their shape, the way that their direction components are interpreted with respect to that shape, and the way that dropoff and decay are applied.
Deletes an AlVolumeLight wrapper object.
Returns the class identifier, kVolumeLightType.
Returns the volume light’s shadow flag (that is, does the light cast shadows). This method returns FALSE if the light is not valid.
Returns the volume light’s specular flag (that is, will this light contribute to specular component). This method returns FALSE if the light is not valid.
Returns the turbulence Animated flag. If the flag is TRUE, then a 4D turbulence table is built. Otherwise a 3D table is built. This method returns FALSE if the light is not valid.
Returns the turbulence Directional flag. If the flag is TRUE, then turbulence will be relative to the local light direction. This method returns FALSE if the light is not valid.
Returns the turbulence space Resolution (the size of the turbulence table in each dimension). -1 is returned if the light is not valid.
Returns the turbulence time Resolution (the size of the turbulence table in time dimension). -1 is returned if the light is not valid.
Returns the volume light’s intensity. -1 is returned if the light is not valid.
Returns the volume light’s decay. -1 is returned if the light is not valid.
Returns the proportion of the distance from the center where the decay starts. -1 is returned if the light is not valid.
Returns the volume light’s directionality. -1 is returned if the light is not valid.
Returns the relative strength of the concentric component of the light. -1 is returned if the light is not valid.
Returns the relative strength of the directional component of the light. -1 is returned if the light is not valid.
Returns the relative strength of the radial component of the light. -1 is returned if the light is not valid.
Returns the volume light’s dropoff. -1 is returned if the light is not valid.
Returns the portion of the distance from the center to where the dropoff starts. -1 is returned if the light is not valid.
Returns the light’s turbulence intensity. -1 is returned if the light is not valid.
Returns the light’s turbulence spread (space scale). -1 is returned if the light is not valid.
Returns the light’s turbulence Persistence (time scale). -1 is returned if the light is not valid.
Returns the light’s turbulence granularity (high-pass cutoff). -1 is returned if the light is not valid.
Returns the light’s turbulence Roughness (low-pass space cutoff). -1 is returned if the light is not valid.
Returns the light’s turbulence Variability (low-pass time cutoff). -1 is returned if the light is not valid.
Sets the shadows flag.
< shadows - TRUE if shadows are to be cast
sSuccess - setting shadows succeeded
sInvalidObject - not a valid volume light
Sets the volume light’s specular flag (that is, will this light contribute to specular component).
< specular - TRUE if the light contributes to the specular component
sSuccess - setting specular succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence Animated flag.
< animated - TRUE if a 4D turbulence table is to be built
- FALSE if a 3D table is to be built
sSuccess - setting the animated succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence Directional flag.
< directional - TRUE if turbulence is relative to the local light direction
sSuccess - setting the turbulence flag succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence space Resolution.
Note that the product time_res*space_res should be <= 256 or you risk running out of swap space and patience.
< space_res - the size of the turbulence table in each direction
sSuccess - setting space resolution succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - space_res out of range 1..32
sFailure - setting failed
Sets the turbulence time Resolution.
Note that the product time_res*space_res should be <= 256 or you risk running out of swap space and patience.
< time_res - the size of the turbulence table in the time dimension
sSuccess - setting time resolution succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - time_res out of range 1..32
sFailure - setting failed
Sets the volume light’s intensity.
< intensity - the intensity of the light
sSuccess - setting the intensity succeeded
sInvalidObject - the light is not valid
sFailure - setting failed
Sets the volume light’s decay (please see the volume light documentation in the Menu Book; this decay is significantly different from the standard light decay).
< decay - the decay of the light (from 0 to 1)
sSuccess - setting decay succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - decay out of range 0..1
sFailure - setting failed
Sets the proportion of the distance from the center to where the decay starts.
< decay_start - proportion of the distance from the center to the start
sSuccess - setting decay succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - decay out of range 0..1
sFailure - setting failed
Sets the volume light’s directionality.
< directionality - this is from 0 to 1
sSuccess - setting directionality succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - the directionality was out of the range 0..1
sFailure - setting failed
Sets the relative strength of the concentric component of the light.
< concentric - relative strength from 0 to 1
sSuccess - setting specular succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - concentric out of range 0..1
sFailure - setting failed
Sets the relative strength of the directional component of the light.
< directional - the strength from 0 to 1
sSuccess - setting directional succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - directional out of range 0..1
sFailure - setting failed
Sets the relative strength of the radial component of the light.
< radial - the strength from 0 to 1
sSuccess - setting radial succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - radial out of range 0..1
sFailure - setting failed
Sets the volume light’s dropoff.
< dropoff - the dropoff from 0 to 50
sSuccess - setting volume succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - volume out of range 0..50
sFailure - setting failed
Sets the portion of the distance from the center to where the dropoff starts.
< dropoff_start - the distance from 0 to 1
sSuccess - setting dropoff succeeded
sInvalidObject - not a valid volume light
sInvalidArgument - dropoff out of range 0..1
sFailure - setting failed
Sets the turbulence intensity.
< intensity - the intensity to set
sSuccess - setting intensity succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence spread (on the space scale).
< spread - the spread to set
sSuccess - setting spread succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence Persistence (on the time scale).
< persistence - persistence to set
sSuccess - setting the Persistence succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence granularity (high-pass cutoff).
< granularity - granularity to set
sSuccess - setting granularity succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence Roughness (low-pass space cutoff).
< roughness - the roughness to set
sSuccess - setting roughness succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed
Sets the turbulence Variability (low-pass time cutoff).
< variability - the variability to set
sSuccess - setting Variability succeeded
sInvalidObject - not a valid volume light
sFailure - setting failed