Public Member Functions
MetaShaderRendererDef Class Reference

Detailed Description

Represents a custom renderer definition.

The MetaShaderRendererDef identifies the implementation of the shader for each of the renderers capable of using the shader, including the file location and name of the handler, and any renderer options (for example, the version number). Every ShaderDef must have at least one MetaShaderRendererDef defined (see ShaderDef::AddRendererDef).

See also:
ShaderDef::AddRendererDef, ShaderDef::RemoveRendererDef, ShaderDef::GetRendererDefByName, Renderer, ShaderDefinitions/netview_ShaderDefs Color Sampler example
Since:
9.0 (2011)

#include <xsi_metashaderrendererdef.h>

Inheritance diagram for MetaShaderRendererDef:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 MetaShaderRendererDef ()
 ~MetaShaderRendererDef ()
 MetaShaderRendererDef (const CRef &in_ref)
 MetaShaderRendererDef (const MetaShaderRendererDef &in_obj)
bool IsA (siClassID in_ClassID) const
siClassID GetClassID () const
MetaShaderRendererDefoperator= (const MetaShaderRendererDef &in_obj)
MetaShaderRendererDefoperator= (const CRef &in_ref)
CString GetCodePath ()
CStatus PutCodePath (const CString &in_codepath)
CString GetCodeText ()
CStatus PutCodeText (const CString &in_codetext)
ValueMap GetRendererOptions ()
CString GetSymbolName ()
CStatus PutSymbolName (const CString &in_symbolname)

Constructor & Destructor Documentation

Default constructor.

Default destructor.

MetaShaderRendererDef ( const CRef in_ref)

Constructor.

Parameters:
in_refconstant reference object.

Copy constructor.

Parameters:
in_objconstant class object.

Member Function Documentation

bool IsA ( siClassID  in_ClassID) const [virtual]

Returns true if a given class type is compatible with this API class.

Parameters:
in_ClassIDclass type.
Returns:
true if the class is compatible, false otherwise.

Reimplemented from SIObject.

siClassID GetClassID ( ) const [virtual]

Returns the type of the API class.

Returns:
The class type.

Reimplemented from SIObject.

MetaShaderRendererDef& operator= ( const MetaShaderRendererDef in_obj)

Creates an object from another object. The newly created object is set to empty if the input object is not compatible.

Parameters:
in_objconstant class object.
Returns:
The new MetaShaderRendererDef object.
Since:
9.0 (2011)
MetaShaderRendererDef& operator= ( const CRef in_ref)

Creates an object from a reference object. The newly created object is set to empty if the input reference object is not compatible.

Parameters:
in_refconstant class object.
Returns:
The new MetaShaderRendererDef object.
Since:
9.0 (2011)

Reimplemented from SIObject.

CString GetCodePath ( )

Returns the file path of the shader code to execute (for example, "\Application\bin\nt-x86-64\sibase.dll" or "{LIBS}/sibase.{EXT}". This is the same information as specified in the FileName entry under the MetaShader > Renderer section in a SPDL file.

Note:
If the file path hasn't been set then an empty string is returned.
Returns:
the code path.
See also:
MetaShaderRendererDef::GetCodeText, Shader::GetCodePath
Since:
9.0 (2011)
CStatus PutCodePath ( const CString in_codepath)

Sets the file path of the shader code to execute (for example, "\Application\bin\nt-x86-64\sibase.dll" or "{LIBS}/sibase.{EXT}". This is the same information as specified in the FileName entry under the MetaShader > Renderer section in a SPDL file.

Parameters:
in_codepaththe code path.
Returns:
CStatus
See also:
MetaShaderRendererDef::GetCodeText, Shader::GetCodePath
Since:
9.0 (2011)
CString GetCodeText ( )

Returns the text of the shader code to execute. This is the same as the embedded shader code specified between the "BeginText" and "EndText" block of the MetaShader > Renderer section in a SPDL file.

Note:
If the text hasn't been set then an empty string is returned.
Returns:
the code text.
See also:
MetaShaderRendererDef::GetCodePath, Shader::GetCodeText
Since:
9.0 (2011)
CStatus PutCodeText ( const CString in_codetext)

Sets the text of the shader code to execute. This is the same as the embedded shader code specified between the "BeginText" and "EndText" block of the MetaShader > Renderer section in a SPDL file.

Parameters:
in_codetextthe code text.
Returns:
Success/failure
See also:
MetaShaderRendererDef::GetCodePath, Shader::GetCodeText
Since:
9.0 (2011)
ValueMap GetRendererOptions ( )

Returns the renderer's options as a ValueMap. This is the same information as specified in the Options entry under the MetaShader > Renderer section in a SPDL file.

Returns:
the renderer's options.
See also:
Shader::GetRendererOption
Since:
9.0 (2011)
CString GetSymbolName ( )

Returns the symbol name of the shader code to execute. The symbol name is the name of the procedure to execute (for example, "material-phong_cg" is the symbol name for the Softimage Phong shader's Cg renderer). This is the same information as specified in the Name entry under the MetaShader > Renderer section in a SPDL file. The returned object is typically used for adding extra information to a shader renderer such as the version of a hardware shader (see siHWShaderVersionID).

Note:
If the symbol name hasn't been set then an empty string is returned.
Returns:
the symbol name.
See also:
Shader::GetSymbolName
Since:
9.0 (2011)
CStatus PutSymbolName ( const CString in_symbolname)

Sets the symbol name of the shader code to execute. The symbol name is the name of the procedure to execute (for example, "material-phong_cg" is the symbol name for the Softimage Phong shader's Cg renderer). This is the same information as specified in the Name entry under the MetaShader > Renderer section in a SPDL file.

Parameters:
in_symbolnamethe symbol name.
Returns:
Success/failure
See also:
Shader::GetSymbolName
Since:
9.0 (2011)

The documentation for this class was generated from the following file: