Public Member Functions

IMRPhysicalSunLight Class Reference

Search for all occurrences

Detailed Description

Access interface for the Mental Ray Physical Sun Light.

This class represents the Mental Ray Physical Sun Light implemented by 3ds Max. Given a pointer to a sun light, one can get the parameters as follows:

Object* sunlight = // obtain a pointer to an object
BaseInterface* sunInterface = sunlight->GetInterface(IID_MR_PHYSICAL_SUN_LIGHT);
IMRPhysicalSunLight* physSunInterface =  dynamic_cast<IMRPhysicalSunLight*>(sunInterface);

#include <imrPhysicalSunLight.h>

Inheritance diagram for IMRPhysicalSunLight:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual Interface_ID  GetID ()
  Returns the Interface ID of this interface.
virtual  ~IMRPhysicalSunLight ()
  A virtual destructor for the interface.
Inherit from mrSky

Uses the equivalent settings from the mrSky Parameters rollout for the remaining mr Physical Sky Parameters rollout settings, except for Aerial Perspective.

Default=on.

virtual bool  getInheritFromSky (TimeValue &t, Interval &valid) const =0
  Gets whether or not the environment map inherits from mrSky.
virtual bool  setInheritFromSky (TimeValue t, bool inheritFromSky)=0
  Sets whether or not the environment map inherits from mrSky.
Photon Target Enabled

Focus global-illumination photons on an area of interest.

For example, if you've modeled a huge city as a backdrop, but are rendering only a room interior, you probably don't want mental ray to shoot photons over the entire city, with the result that only a few will find their way into the room. When on, uses the Radius (or PhotonTarget) setting with respect to the light target.

virtual bool  getPhotonTargetEnabled (TimeValue &t, Interval &valid) const =0
  Gets whether or not the a photon target is enabled.
virtual bool  setPhotonTargetEnabled (TimeValue t, bool enablePhotonTarget)=0
  Sets whether or not the a photon target is enabled.
Photon Target

The radial distance from the light target in which the mr Sun casts GI photons.

virtual float  getPhotonTarget (TimeValue &t, Interval &valid) const =0
  Gets the radial distance from the photon target.
virtual bool  getPhotonTarget (TimeValue t, float photonTarget)=0
  Sets the radial distance from the photon target.
Multiplier

The multiplier for the value of the sun's light output.

virtual float  getMultiplier (TimeValue &t, Interval &valid) const =0
  Gets the value of the multiplier for the sun's light output.
virtual bool  setMultiplier (TimeValue t, float multiplier)=0
  Sets the value of the multiplier for the sun's light output.
Sky Multiplier

The multiplier for the value of the sky's brightness.

virtual float  getSkyMultiplier (TimeValue &t, Interval &valid) const =0
  Gets the value of the multiplier for the sky's brightness.
virtual bool  setSkyMultiplier (TimeValue t, float skyMultiplier)=0
  Sets the value of the multiplier for the sky's brightness.
Haze

The amount of particulate matter in the air.

Possible values range from 0.0 (a completely clear day) to 15.0 (extremely overcast, or a sandstorm in the Sahara). Default=0.0.

virtual float  getHaze (TimeValue &t, Interval &valid) const =0
  Gets the haze value of the sky.
virtual bool  setHaze (TimeValue t, float haze)=0
  Sets the haze value of the sky.
Red/Blue Shift

Provides artistic control over the redness of the sky light.

The default value of 0.0 is the physically correct value (calculated for a 6500K whitepoint), but can be changed with this parameter, which ranges from -1.0 (extremely blue) to 1.0 (extremely red).

virtual float  getRedBlueShift (TimeValue &t, Interval &valid) const =0
  Gets the red/blue tint value of the sky.
virtual bool  setRedBlueShift (TimeValue t, float redBlueShift)=0
  Sets the red/blue tint value of the sky.
Saturation

Provides artistic control over saturation of the sky light.

The default value of 1.0 is the physically calculated saturation level. Possible values range from 0.0 (black and white) to 2.0 (extremely high saturation).

virtual float  getSaturation (TimeValue &t, Interval &valid) const =0
  Gets the saturation value of the sky.
virtual bool  setSaturation (TimeValue t, float saturation)=0
  Sets the saturation value of the sky.
Horizon Height

The vertical position of the horizon.

Default=0.0.

virtual float  getHorizonHeight (TimeValue &t, Interval &valid) const =0
  Gets the horizon height value.
virtual bool  setHorizonHeight (TimeValue t, float horizonHeight)=0
  Sets the horizon height value.
Shadow Softness

The softness of shadow edges.

The default value of 1.0 accurately matches the softness of real solar shadows. Lower values make the shadows sharper and higher values make them softer.

virtual float  getShadowSoftness (TimeValue &t, Interval &valid) const =0
  Gets the value of the shadow softness.
virtual bool  setShadowSoftness (TimeValue t, float shadowSoftness)=0
  Sets the value of the shadow softness.
Shadow Samples

The number of shadow samples for the soft shadows.

If it is set to 0, no soft shadows are generated. Default=8.

virtual int  getShadowSamples (TimeValue &t, Interval &valid) const =0
  Gets the number of shadow samples.
virtual bool  setShadowSamples (TimeValue t, int shadowSamples)=0
  Sets the number of shadow samples.

Constructor & Destructor Documentation

virtual ~IMRPhysicalSunLight ( ) [inline, virtual]

A virtual destructor for the interface.

{};

Member Function Documentation

virtual Interface_ID GetID ( ) [inline, virtual]

Returns the Interface ID of this interface.

Reimplemented from BaseInterface.

{ return IID_MR_PHYSICAL_SUN_LIGHT; };
virtual bool getInheritFromSky ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets whether or not the environment map inherits from mrSky.

Parameters:
[in] t - The time at which we're getting the value
[in] valid - The interval at which we're getting the value
Returns:
A boolean if we're inheriting from mrSky or not
virtual bool setInheritFromSky ( TimeValue  t,
bool  inheritFromSky 
) [pure virtual]

Sets whether or not the environment map inherits from mrSky.

Parameters:
[in] t - The time at which to set the value
[in] inheritFromSky - A boolean value of what whether or not we're inheriting from mrSky
Returns:
true if the setting was successful
virtual bool getPhotonTargetEnabled ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets whether or not the a photon target is enabled.

Parameters:
[in] t - The time at which we're getting the value
[in] valid - The interval at which we're getting the value
Returns:
A boolean if a photon target is enabled
virtual bool setPhotonTargetEnabled ( TimeValue  t,
bool  enablePhotonTarget 
) [pure virtual]

Sets whether or not the a photon target is enabled.

Parameters:
[in] t - The time at which to set the horizon height
[in] enablePhotonTarget - A boolean value to enable/disable a photon target
Returns:
true if the setting was successful
virtual float getPhotonTarget ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the radial distance from the photon target.

Parameters:
[in] t - The time at which we're getting the radius
[in] valid - The interval at which we're getting the radius
Returns:
The current radius from the photon target
virtual bool getPhotonTarget ( TimeValue  t,
float  photonTarget 
) [pure virtual]

Sets the radial distance from the photon target.

Parameters:
[in] t - The time at which to set the radius
[in] photonTarget - The value of what to set photon target radius to
Returns:
true if the setting was successful
virtual float getMultiplier ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the value of the multiplier for the sun's light output.

Parameters:
[in] t - The time at which we're getting the multiplier
[in] valid - The interval at which we're getting the multiplier
Returns:
The value of the multiplier
virtual bool setMultiplier ( TimeValue  t,
float  multiplier 
) [pure virtual]

Sets the value of the multiplier for the sun's light output.

Parameters:
[in] t - The time at which to set the multiplier
[in] multiplier - The value of what to set the multiplier to
Returns:
true if the setting was successful
virtual float getSkyMultiplier ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the value of the multiplier for the sky's brightness.

Parameters:
[in] t - The time at which we're getting the multiplier
[in] valid - The interval at which we're getting the multiplier
Returns:
The value of the multiplier
virtual bool setSkyMultiplier ( TimeValue  t,
float  skyMultiplier 
) [pure virtual]

Sets the value of the multiplier for the sky's brightness.

Parameters:
[in] t - The time at which to set the multiplier
[in] skyMultiplier - The value of what to set the multiplier to
Returns:
true if the setting was successful
virtual float getHaze ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the haze value of the sky.

Parameters:
[in] t - The time at which we're getting the haze value
[in] valid - The interval at which we're getting the haze value
Returns:
The value of the haze
virtual bool setHaze ( TimeValue  t,
float  haze 
) [pure virtual]

Sets the haze value of the sky.

Parameters:
[in] t - The time at which to set the haze value
[in] haze - The value of what to set the haze value to
Returns:
true if the setting was successful
virtual float getRedBlueShift ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the red/blue tint value of the sky.

Parameters:
[in] t - The time at which we're getting the red/blue shift
[in] valid - The interval at which we're getting the red/blue shift
Returns:
The value of the red/blue shift
virtual bool setRedBlueShift ( TimeValue  t,
float  redBlueShift 
) [pure virtual]

Sets the red/blue tint value of the sky.

Parameters:
[in] t - The time at which to set the red/blue shift
[in] redBlueShift - The value of what to set the red/blue shift to
Returns:
true if the setting was successful
virtual float getSaturation ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the saturation value of the sky.

Parameters:
[in] t - The time at which we're getting the saturation value
[in] valid - The interval at which we're getting the saturation value
Returns:
The value of the saturation
virtual bool setSaturation ( TimeValue  t,
float  saturation 
) [pure virtual]

Sets the saturation value of the sky.

Parameters:
[in] t - The time at which to set the saturation
[in] saturation - The value of what to set the saturation to
Returns:
true if the setting was successful
virtual float getHorizonHeight ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the horizon height value.

Parameters:
[in] t - The time at which we're getting the horizon height
[in] valid - The interval at which we're getting the horizon height
Returns:
The value of the horizon height
virtual bool setHorizonHeight ( TimeValue  t,
float  horizonHeight 
) [pure virtual]

Sets the horizon height value.

Parameters:
[in] t - The time at which to set the horizon height
[in] horizonHeight - The value of what to set the horizon height to
Returns:
true if the setting was successful
virtual float getShadowSoftness ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the value of the shadow softness.

Parameters:
[in] t - The time at which we're getting the value
[in] valid - The interval at which we're getting the value
Returns:
The value of the shadow softness
virtual bool setShadowSoftness ( TimeValue  t,
float  shadowSoftness 
) [pure virtual]

Sets the value of the shadow softness.

Parameters:
[in] t - The time at which to set the value
[in] shadowSoftness - The value of what to set the shadow softness to
Returns:
true if the setting was successful
virtual int getShadowSamples ( TimeValue &  t,
Interval valid 
) const [pure virtual]

Gets the number of shadow samples.

Parameters:
[in] t - The time at which we're getting the value
[in] valid - The interval at which we're getting the value
Returns:
The number of samples being used for soft shadows.
virtual bool setShadowSamples ( TimeValue  t,
int  shadowSamples 
) [pure virtual]

Sets the number of shadow samples.

Parameters:
[in] t - The time at which to set the value
[in] shadowSamples - The value of what to set number of samples to
Returns:
true if the setting was successful

IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight
IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight IMRPhysicalSunLight