LightscapeLight::AreaLightCustAttrib Class Reference


Detailed Description

Area Lights sampling custom attribute.

This class holds the sampling information and additional information for area lights.

#include <lslights.h>

Inheritance diagram for LightscapeLight::AreaLightCustAttrib:
Inheritance graph
[legend]

List of all members.

Public Types

enum   {
  kDefaultSamples_Area = 32, kDefaultSamples_Linear = kDefaultSamples_Area, kDefaultSamples_Cylinder = kDefaultSamples_Area, kDefaultSamples_Sphere = kDefaultSamples_Area,
  kDefaultSamples_Disc = kDefaultSamples_Area, kDefaultSamples_Point = 0
}
 

Default number of samples.

More...

Public Member Functions

virtual bool  AreaLightComputationEnabled (TimeValue t, Interval *valid=NULL) const =0
  Returns whether the area light computation is enabled.
virtual BOOL  IsLightShapeRenderingEnabled (TimeValue t, Interval *valid=NULL) const =0
  Returns whether the light's shape is rendered.
virtual void  LightShapeRenderingEnabled (TimeValue t, BOOL on)=0
  Set whether the light's shape is rendered.
virtual Interface_ID  GetID ()
  Returns the Interface ID for this class, LS_AREALIGHTCUSTATTRIB_INTERFACE_ID.
virtual int  GetNumSamples (TimeValue t, Interval *valid=NULL) const =0
  Returns the number of samples to be used.
virtual void  SetNumSamples (TimeValue t, int numSamples)=0
  Sets the number of samples to be used.

Static Public Attributes

static const BOOL  kDefault_EnableAreaLight = TRUE
  Default value of the area light computation state.
static const BOOL  kDefault_EnableLightShapeRendering = FALSE
  Default value of the light shape rendering state.

Member Enumeration Documentation

anonymous enum

Default number of samples.

Enumerator:
kDefaultSamples_Area 

Default num samples for area lights.

kDefaultSamples_Linear 

Default num samples for linear lights.

kDefaultSamples_Cylinder 

Default num samples for cylinder lights.

kDefaultSamples_Sphere 

Default num samples for sphere lights.

kDefaultSamples_Disc 

Default num samples for disc lights.

kDefaultSamples_Point 

Default num samples for point lights.


Member Function Documentation

virtual bool AreaLightComputationEnabled ( TimeValue  t,
Interval valid = NULL 
) const [pure virtual]

Returns whether the area light computation is enabled.

Parameters:
[in] t - The time at which the value is retrieved
[in,out] valid - If this argument is not NULL, the validity of this value is intersected with the interval pointed to by this argument.
Returns:
always the value kDefault_EnableAreaLight
virtual BOOL IsLightShapeRenderingEnabled ( TimeValue  t,
Interval valid = NULL 
) const [pure virtual]

Returns whether the light's shape is rendered.

Parameters:
[in] t - The time at which the value is retrieved
[in,out] valid - If this argument is not NULL, the validity of this value is intersected with the interval pointed to by this argument.
Returns:
TRUE if the light shape is rendered
virtual void LightShapeRenderingEnabled ( TimeValue  t,
BOOL  on 
) [pure virtual]

Set whether the light's shape is rendered.

Parameters:
[in] t - The time at which the value is retrieved
[in] on - Render or not the light shape in mental ray
Returns:
TRUE if the light shape is rendered
virtual int GetNumSamples ( TimeValue  t,
Interval valid = NULL 
) const [pure virtual]

Returns the number of samples to be used.

Postcondition:
The number of samples should be a power of 2
Parameters:
[in] t - The time at which the number of samples is retrieved.
[in,out] valid - If this argument is not NULL, the validity of this number of samples is intersected with the interval pointed to by this argument.
Returns:
The number of samples
virtual void SetNumSamples ( TimeValue  t,
int  numSamples 
) [pure virtual]

Sets the number of samples to be used.

Precondition:
The number of samples should be a power of 2
Parameters:
[in] t - The time at which the number of samples is set.
[in] numSamples - The number of sample to use.
virtual Interface_ID GetID ( ) [inline, virtual]

Returns the Interface ID for this class, LS_AREALIGHTCUSTATTRIB_INTERFACE_ID.

Reimplemented from BaseInterface.

{ return LS_AREALIGHTCUSTATTRIB_INTERFACE_ID; }   

Member Data Documentation

const BOOL kDefault_EnableAreaLight = TRUE [static]

Default value of the area light computation state.

const BOOL kDefault_EnableLightShapeRendering = FALSE [static]

Default value of the light shape rendering state.


LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib
LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib LightscapeLight::AreaLightCustAttrib