Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Reverted from v. 5

Description

This class allows you to manipulate emitter components. Each material layer can contain one emitter. See here for a description of the Maxwell emitter mode.

Texturable attributes: mxi (AttrType_Double, value used as intensity multiplier when textured, ignored when not textured).

Base class: MaxwellMayaMaterialComponent.

Methods

voidDestroy()
voidSetEnabled(bool enabled)
boolGetEnabled() const
voidSetEmissionType(EmissionType type)
EmissionTypeGetEmissionType() const
voidSetColorType(ColorType type)
ColorTypeGetColorType() const
voidSetRGBColor(const MFloatVector& color)
voidGetRGBColor(MFloatVector& color) const
voidSetCorrelatedColor(double temperature)
doubleGetCorrelatedColor() const
voidSetOutputType(OutputType type)
OutputTypeGetOutputType() const
voidSetWatts(double watts)
doubleGetWatts() const
voidSetEfficacy(double efficacy)
doubleGetEfficacy() const
voidSetLuminance(double luminance)
doubleGetLuminance() const
voidSetIES(const MString& file, double intensity)
voidGetIES(MString& file, double& intensity) const
voidSetTemperature(double temperature)
doubleGetTemperature() const
 Inherited methods

void Destroy()

Destroys the emitter, removing it from the parent layer.

Anchor
Enabled
Enabled
void SetEnabled(bool enabled)
bool GetEnabled() const

Emitters can be disabled, in which case they do not participate in rendering in any way.

Attribute name: enabled (AttrType_Bool).

Anchor
EmissionType
EmissionType
void SetEmissionType(EmissionType type)
EmissionType GetEmissionType() const

Maxwell supports the following types of emitters:

  • EmissionType_ColorLuminance: an analytic model based on color and luminance.
  • EmissionType_Temperature: the emitter is defined by a single value called emission temperature which controls both the color and intensity of the light.
  • EmissionType_MXI: texture-based emission.

See here for a more in-depth explanation of the three types.

Attribute name: emissionType (AttrType_Int).

Anchor
ColorType
ColorType
void SetColorType(ColorType type)
ColorType GetColorType() const

When the emitter type is set to EmissionType_ColorLuminance, this attribute controls how the light color is specified:

  • ColorType_RGB: as a RGB value.
  • ColorType_Correlated: as a color temperature value.

See here for details.

Attribute name: colorType (AttrType_Int).

Anchor
RGBColor
RGBColor
void SetRGBColor(const MFloatVector& color)
void GetRGBColor(MFloatVector& color) const

This attribute represents the emission color when the emitter type is set to EmissionType_ColorLuminance and the color type is set to ColorType_RGB. The Python version of SetRGBColor takes the red, green and blue values as separate arguments (in the range 0..1), while GetRGBColor returns the color as a 3-tuple.

 Attribute name: colorRGB (AttrType_Color).

Anchor
CorrelatedColor
CorrelatedColor
void SetCorrelatedColor(double temperature)
double GetCorrelatedColor() const

This attribute controls the emission color when the emitter type is set to EmissionType_ColorLuminance and the color type is set to ColorType_Correlated.

Attribute name: colorCorrelated (AttrType_Double).

Anchor
OutputType
OutputType
void SetOutputType(OutputType type)
OutputType GetOutputType() const

This attribute controls how the output intensity is defined:

  • OutputType_WattsEfficacy: wattage and luminous efficacy values.
  • OutputType_LuminousPower: value in lumens.
  • OutputType_Illuminance: value in lux (lumens/sqm).
  • OutputType_LuminousIntensity: value in candelas.
  • OutputType_Luminance: value in nits (candelas/sqm).
  • OutputType_IES: an IES file is used to define spread and intensity.

This page contains more details about the output types.

Attribute name: outputType (AttrType_Int).

Anchor
Watts
Watts
void SetWatts(double watts)
double GetWatts() const

This attribute specifies the emission power in watts when the emitter type is set to EmissionType_ColorLuminance and the output type is set to OutputType_WattsEfficacy.

 Attribute name: watts (AttrType_Double).

Anchor
Efficacy
Efficacy
void SetEfficacy(double efficacy)
double GetEfficacy() const

This attribute specifies the luminous efficacy when the emitter type is set to EmissionType_ColorLuminance and the output type is set to OutputType_WattsEfficacy.

Attribute name: efficacy (AttrType_Double).

Anchor
Luminance
Luminance
void SetLuminance(double luminance)
double GetLuminance() const

This attribute specifies the luminance value when the emitter type is set to EmissionType_ColorLuminance and the output type is set to OutputType_LuminousPowerOutputType_IlluminanceOutputType_LuminousIntensity or OutputType_Luminance.

Attribute name: luminance (AttrType_Double).

Anchor
IES
IES
void SetIES(const MString& file, double intensity)
void GetIES(MString& file, double& intensity) const

Control the IES file and intensity multiplier when the emitter type is set to EmissionType_ColorLuminance and the output type is set to OutputType_IES. The intensity argument is optional in the Python version of SetIES and defaults to 1 if not present. GetIES takes no arguments in Python and returns the values as a 2-tuple.

Attribute names: iesFile (AttrType_String), iesIntensity (AttrType_Double).

Anchor
Temperature
Temperature
void SetTemperature(double temperature)
double GetTemperature() const

This attribute represents the emission temperature when the emitter type is set to EmissionType_Temperature. Not to be confused with the correlated color attribute, which only controls the emission color when the type is set to EmissionType_ColorLuminance. This attribute defines both the emission color and the intensity. 

Attribute name: temperature (AttrType_Double).