Public Member Functions | Protected Member Functions

MFnLambertShader Class Reference

Search for all occurrences

Detailed Description

Manage Lambert shaders.

MFnLambertShader facilitates creation and manipulation of dependency graph nodes representing lambertian shaders.

#include <MFnLambertShader.h>

Inheritance diagram for MFnLambertShader:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual MFn::Type type () const
 Function set type.
virtual ~MFnLambertShader ()
 Destructor.
 MFnLambertShader ()
 Default constructor.
 MFnLambertShader (MObject &object, MStatus *ReturnStatus=NULL)
 Constructor.
MObject create (bool UIvisible=true, MStatus *ReturnStatus=NULL)
 Creates a new lambert shader dependency graph node and adds it to the dependency graph.
short refractedRayDepthLimit (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "refractedRayDepthLimit" attribute of a lambert shader node.
MStatus setRefractedRayDepthLimit (const short &new_limit)
 Sets the value of the "refractedRayDepthLimit" attribute of a lambert shader node.
float refractiveIndex (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "refractiveIndex" attribute of a lambert shader node.
MStatus setRefractiveIndex (const float &refractive_index)
 Sets the value of the "refractiveIndex" attribute of a shader node.
bool rtRefractedColor (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "rtRefractedColor" attribute of a shader node.
MStatus setRtRefractedColor (const bool &rt_refracted_color)
 Sets the value of the "rtRefractedColor" attribute of a shader node.
float diffuseCoeff (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "diffuseCoeff" attribute of a lambert shader node.
MStatus setDiffuseCoeff (const float &diffuse_coeff)
 Sets the value of the "diffuseCoeff" attribute of a shader node.
MColor color (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "color" attribute of a shader node.
MStatus setColor (const MColor &col)
 Sets the value of the "color" attribute of a shader node.
MColor transparency (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "transparency" attribute of a shader node.
MStatus setTransparency (const MColor &transp)
 Sets the value of the "transparency" attribute of a shader node.
MColor ambientColor (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "ambientColor" attribute of a shader node.
MStatus setAmbientColor (const MColor &ambient_color)
 Sets the value of the "ambientColor" attribute of a shader node.
MColor incandescence (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "incandescence" attribute of a shader node.
MStatus setIncandescence (const MColor &incand)
 Sets the value of the "incandescence" attribute of a shader node.
float translucenceCoeff (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "translucenceCoeff" attribute of a lambert shader node.
MStatus setTranslucenceCoeff (const float &translucence_coeff)
 Sets the value of the "translucenceCoeff" attribute of a shader node.
float glowIntensity (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "glowIntensity" attribute of a shader node.
MStatus setGlowIntensity (const float &glow_intensity)
 Sets the value of the "glowIntensity" attribute of a shader node.
bool hideSource (MStatus *ReturnStatus=NULL) const
 Retrieves the value of the "hideSource" attribute of a shader node.
MStatus setHideSource (const bool &hide_source)
 Sets the value of the "hideSource" attribute of a shader node.
 MFnLambertShader (const MObject &object, MStatus *ReturnStatus=NULL)
 Constructor.

Protected Member Functions

virtual const char * className () const
 Class name.

Constructor & Destructor Documentation

MFnLambertShader ( MObject object,
MStatus ReturnStatus = NULL 
)

Constructor.

Class constructor that initializes the function set to the given MObject.

Parameters:
[in]objectThe MObject to attach the function set to
[out]ReturnStatusthe return status
Status Codes:
MFnLambertShader ( const MObject object,
MStatus ReturnStatus = NULL 
)

Constructor.

Class constructor that initializes the function set to the given MObject.

Parameters:
[in]objectThe MObject to attach the function set to
[out]ReturnStatusthe return status
Status Codes:

Member Function Documentation

MFn::Type type ( ) const [virtual]

Function set type.

Return the class type : MFn::kLambert.

Reimplemented from MFnDependencyNode.

Reimplemented in MFnBlinnShader, MFnPhongShader, and MFnReflectShader.

const char * className ( ) const [protected, virtual]

Class name.

Return the class name : "MFnLambertShader".

Reimplemented from MFnDependencyNode.

Reimplemented in MFnBlinnShader, MFnPhongShader, and MFnReflectShader.

MObject create ( bool  UIvisible = true,
MStatus ReturnStatus = NULL 
)

Creates a new lambert shader dependency graph node and adds it to the dependency graph.

If the UIvisible parameter is true, the new node will be connected to the shader classification node (which allows the UI to recognize the node as a shader). If UIvisible is false, the node will be created in isolation.

Parameters:
[in]UIvisibledetermines whether or not the new node will be connected to the shader classification node.
[out]ReturnStatusreturn status
Returns:
MObject representing the new dependency node.
Status Codes:
  • MS::kSuccess operation successful
  • MS::kInsufficientMemory ran out of memory
  • MS::kNoModelActive no model is currently active
  • MS::kLicenseFailure application not licensed for attempted operation
  • MS::kFailure the new node could not be created, or the new node could not be added to the dependency graph, or the new node could not be connected to the classification node.

Reimplemented in MFnBlinnShader, and MFnPhongShader.

short refractedRayDepthLimit ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "refractedRayDepthLimit" attribute of a lambert shader node.

This attribute represents the maximum refracted ray depth used in the shading calculation.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "refractedRayDepthLimit" attribute of the node.
Status Codes:
MStatus setRefractedRayDepthLimit ( const short &  refracted_ray_depth_limit)

Sets the value of the "refractedRayDepthLimit" attribute of a lambert shader node.

Parameters:
[in]refracted_ray_depth_limitvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
float refractiveIndex ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "refractiveIndex" attribute of a lambert shader node.

This attribute represents the refractive index of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "refractiveIndex" attribute of the shader node.
Status Codes:
MStatus setRefractiveIndex ( const float &  refractive_index)

Sets the value of the "refractiveIndex" attribute of a shader node.

Parameters:
[in]refractive_indexvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
bool rtRefractedColor ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "rtRefractedColor" attribute of a shader node.

This attribute determines whether the shader uses the value of the "refractedColor" attribute for the refracted color or calculated the refracted color itself.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "rtRefractedColor" attribute of the shader node.
Status Codes:
MStatus setRtRefractedColor ( const bool &  rt_refracted_color)

Sets the value of the "rtRefractedColor" attribute of a shader node.

Parameters:
[in]rt_refracted_colorvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
float diffuseCoeff ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "diffuseCoeff" attribute of a lambert shader node.

This attribute represents the diffuse reflectivity of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "diffuseCoeff" attribute of the shader node.
Status Codes:
MStatus setDiffuseCoeff ( const float &  diffuse_coeff)

Sets the value of the "diffuseCoeff" attribute of a shader node.

Parameters:
[in]diffuse_coeffvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
MColor color ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "color" attribute of a shader node.

This attribute represents the surface color of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "color" attribute of the shader node.
Status Codes:
MStatus setColor ( const MColor col)

Sets the value of the "color" attribute of a shader node.

Parameters:
[in]colvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
MColor transparency ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "transparency" attribute of a shader node.

This attribute represents the surface transparency of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "transparency" attribute of the shader node.
Status Codes:
MStatus setTransparency ( const MColor transp)

Sets the value of the "transparency" attribute of a shader node.

Parameters:
[in]transpvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
MColor ambientColor ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "ambientColor" attribute of a shader node.

This attribute represents the ambient color of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "ambientColor" attribute of the shader node.
Status Codes:
MStatus setAmbientColor ( const MColor ambient_color)

Sets the value of the "ambientColor" attribute of a shader node.

Parameters:
[in]ambient_colorvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
MColor incandescence ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "incandescence" attribute of a shader node.

This attribute represents the incandescence of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "incandescence" attribute of the shader node.
Status Codes:
MStatus setIncandescence ( const MColor incand)

Sets the value of the "incandescence" attribute of a shader node.

Parameters:
[in]incandvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
float translucenceCoeff ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "translucenceCoeff" attribute of a lambert shader node.

This attribute represents a constant multiplier applied to the transparency attribute of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "translucenceCoeff" attribute of the shader node.
Status Codes:
MStatus setTranslucenceCoeff ( const float &  translucence_coeff)

Sets the value of the "translucenceCoeff" attribute of a shader node.

Parameters:
[in]translucence_coeffvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
float glowIntensity ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "glowIntensity" attribute of a shader node.

This attribute represents the constant multplier applied to the glow color of the shader.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "glowIntensity" attribute of the shader node.
Status Codes:
MStatus setGlowIntensity ( const float &  glow_intensity)

Sets the value of the "glowIntensity" attribute of a shader node.

Parameters:
[in]glow_intensityvalue to which the attribute will be set.
Returns:
Return status
Status Codes:
bool hideSource ( MStatus ReturnStatus = NULL) const

Retrieves the value of the "hideSource" attribute of a shader node.

This attribute determines whether or not the computed surface color is used in the shading computation. If hideSource is true, then only the computed shader glow color will be used. Otherwise, both the glow and surface colors will be used.

Parameters:
[out]ReturnStatusreturn status
Returns:
The value of the "hideSource" attribute of the shader node.
Status Codes:
MStatus setHideSource ( const bool &  hide_source)

Sets the value of the "hideSource" attribute of a shader node.

Parameters:
[in]hide_sourcevalue to which the attribute will be set.
Returns:
Return status
Status Codes:

MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader
MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader MFnLambertShader