Protected Member Functions

FbxImplementation Class Reference

This reference page is linked to from the following overview topics: Using hardware shaders to create materials.


Search for all occurrences

Detailed Description

This object represents the shading node implementation.

It defines basic information about the shader and the binding table(FbxBindingTable). For example, you can create a new FbxImplementation like this:

 FbxImplementation* lImpl = FbxImplementation::Create( &pMyScene, "MyImplementation" );
 pMyObject.AddImplementation( lImpl );
 pMyObject.SetDefaultImplementation( lImpl );
 lImpl->RenderAPI = FBXSDK_RENDERING_API_DIRECTX; //FBXSDK_RENDERING_API_DIRECTX, FBXSDK_RENDERING_API_OPENGL, FBXSDK_RENDERING_API_MENTALRAY or FBXSDK_RENDERING_API_PREVIEW
 lImpl->RenderAPIVersion = "9.0"; //API Version

 lImpl->Language = FBXSDK_SHADING_LANGUAGE_HLSL; //FBXSDK_SHADING_LANGUAGE_HLSL, FBXSDK_SHADING_LANGUAGE_GLSL, FBXSDK_SHADING_LANGUAGE_CGFX or FBXSDK_SHADING_LANGUAGE_MRSL
 lImpl->LanguageVersion = "1.0";  //Language Version

After the new FbxImplementation is created, you can access FbxBindingTable like this:

 FbxBindingTable* lTable = lImpl->GetTableByTargetName("root");

Also, you can access the exist FbxImplementation in FbxObject by this:

 const FbxImplementation* lImpl = GetImplementation( pMyObject, FBXSDK_IMPLEMENTATION_CGFX ); // FBXSDK_IMPLEMENTATION_PREVIEW, FBXSDK_IMPLEMENTATION_MENTALRAY, FBXSDK_IMPLEMENTATION_CGFX, FBXSDK_IMPLEMENTATION_HLSL, FBXSDK_IMPLEMENTATION_OGS or FBXSDK_IMPLEMENTATION_NONE
See also:
FbxImplementationFilter
Examples:

ExportShader/main.cxx, and ImportScene/DisplayMaterial.cxx.

Definition at line 53 of file fbximplementation.h.

#include <fbximplementation.h>

Inheritance diagram for FbxImplementation:
Inheritance graph
[legend]

List of all members.

Protected Member Functions

  FbxImplementation (FbxManager &pManager, char const *pName)
virtual bool  ConstructProperties (bool pForceSet)

Target Name.

FbxString  RenderName

Shader Language and API descriptions.

FbxPropertyT< FbxString Language
  Shader Language.
FbxPropertyT< FbxString LanguageVersion
  Shader Language version.
FbxPropertyT< FbxString RenderAPI
  Render API.
FbxPropertyT< FbxString RenderAPIVersion
  Render API version.

Binding description

FbxPropertyT< FbxString RootBindingName
  Name of root binding table.
FbxProperty  GetConstants () const
  Property to store the shader parameters(constants) values in this implementation.
FbxBindingTable AddNewTable (char const *pTargetName, char const *pTargetType)
  Add a new binding table to the table list.
FbxBindingTable const *  GetRootTable () const
  Retrieves a handle on the root binding table.
FbxBindingTable GetRootTable ()
  Retrieves a handle on the root binding table.
int  GetTableCount () const
  Gets the number of binding tables.
FbxBindingTable const *  GetTable (int pIndex) const
  Retrieves a handle on the (pIndex)th binding table.
FbxBindingTable GetTable (int pIndex)
  Retrieves a handle on the (pIndex)th binding table.
FbxBindingTable const *  GetTableByTargetName (char const *pName) const
  Returns the binding table that has the given target name.
FbxBindingTable GetTableByTargetName (char const *pName)
  Returns the binding table that has the given target name.
FbxBindingTable const *  GetTableByTargetType (char const *pTargetName) const
  Returns the binding table that has the given target type.
FbxBindingTable GetTableByTargetType (char const *pTargetName)
  Returns the binding table that has the given target type.
FbxBindingOperator AddNewBindingOperator (char const *pTargetName, char const *pFunctionName)
  Add a new binding operator to the operator list.
int  GetBindingOperatorCount () const
  Gets the number of binding operators.
FbxBindingOperator const *  GetOperatorByTargetName (char const *pTargetName) const
  Returns the binding operator that has the given name.

Static values

static const char *  sLanguage
  Shader Language name.
static const char *  sLanguageVersion
  Shader Language version.
static const char *  sRenderAPI
  Shader render API.
static const char *  sRenderAPIVersion
  Shader render API version.
static const char *  sRootBindingName
  Name of root binding table.
static const char *  sConstants
  Name of property to store the shader parameters(constants) values in this implementation.
static const char *  sDefaultType
  default value for implementation type.
static const char *  sDefaultLanguage
  default value for shader language.
static const char *  sDefaultLanguageVersion
  default value for shader language version.
static const char *  sDefaultRenderAPI
  default value for shader render API.
static const char *  sDefaultRenderAPIVersion
  default value for shader render API version.
static const char *  sDefaultRootBindingName
  default value for root binding table name.

Constructor & Destructor Documentation

FbxImplementation ( FbxManager pManager,
char const *  pName 
) [protected]

Member Function Documentation

FbxProperty GetConstants ( ) const

Property to store the shader parameters(constants) values in this implementation.

FbxBindingTable* AddNewTable ( char const *  pTargetName,
char const *  pTargetType 
)

Add a new binding table to the table list.

Parameters:
pTargetName The target name for the binding table.
pTargetType The target type for the binding table.
Returns:
the new binding table.
Examples:
ExportShader/main.cxx.
FbxBindingTable const* GetRootTable ( ) const

Retrieves a handle on the root binding table.

Returns:
A const pointer to the root table or NULL if it does not exist.
FbxBindingTable* GetRootTable ( )

Retrieves a handle on the root binding table.

Returns:
A pointer to the root table or NULL if it does not exist.
int GetTableCount ( ) const

Gets the number of binding tables.

Returns:
the number of binding tables.
FbxBindingTable const* GetTable ( int  pIndex ) const

Retrieves a handle on the (pIndex)th binding table.

Parameters:
pIndex The index of the table to retrieve. Valid values are [ 0, GetTableCount() ).
Returns:
A const pointer to the pIndex-th table or NULL if pIndex is out of range.
FbxBindingTable* GetTable ( int  pIndex )

Retrieves a handle on the (pIndex)th binding table.

Parameters:
pIndex The index of the table to retrieve. Valid values are [ 0, GetTableCount() ).
Returns:
A const pointer to the pIndex-th table or NULL if pIndex is out of range.
FbxBindingTable const* GetTableByTargetName ( char const *  pName ) const

Returns the binding table that has the given target name.

Parameters:
pName The target name of the table to look for.
Returns:
A const pointer to the binding table with the given target name, or NULL if there is no such binding table.
FbxBindingTable* GetTableByTargetName ( char const *  pName )

Returns the binding table that has the given target name.

Parameters:
pName The target name of the table to look for.
Returns:
A pointer to the binding table with the given target name, or NULL if there is no such binding table.
FbxBindingTable const* GetTableByTargetType ( char const *  pTargetName ) const

Returns the binding table that has the given target type.

Parameters:
pTargetType The target type to look for.
Returns:
A const pointer to the binding table with the given target type, or NULL if there is no such binding table.
FbxBindingTable* GetTableByTargetType ( char const *  pTargetName )

Returns the binding table that has the given target type.

Parameters:
pTargetType The target type to look for.
Returns:
A pointer to the binding table with the given target type, or NULL if there is no such binding table.
FbxBindingOperator* AddNewBindingOperator ( char const *  pTargetName,
char const *  pFunctionName 
)

Add a new binding operator to the operator list.

Parameters:
pTargetName The target name for the binding operator.
pFunctionName The function name for the binding operator.
Returns:
The new operator.
int GetBindingOperatorCount ( ) const

Gets the number of binding operators.

Returns:
the number of binding operators.
FbxBindingOperator const* GetOperatorByTargetName ( char const *  pTargetName ) const

Returns the binding operator that has the given name.

Parameters:
pTargetName The target name of the binding operator to look for.
Returns:
A const pointer to the binding operator with the given name, or NULL if there is no such binding table.
virtual bool ConstructProperties ( bool  pForceSet ) [protected, virtual]

Member Data Documentation

Definition at line 62 of file fbximplementation.h.

Shader Language version.

Examples:
ExportShader/main.cxx.

Definition at line 76 of file fbximplementation.h.

Render API version.

Examples:
ExportShader/main.cxx.

Definition at line 84 of file fbximplementation.h.

Name of root binding table.

Examples:
ExportShader/main.cxx.

Definition at line 94 of file fbximplementation.h.

const char* sLanguage [static]

Shader Language name.

See also:
Language

Definition at line 187 of file fbximplementation.h.

const char* sLanguageVersion [static]

Shader Language version.

See also:
LanguageVersion

Definition at line 192 of file fbximplementation.h.

const char* sRenderAPI [static]

Shader render API.

See also:
RenderAPI

Definition at line 197 of file fbximplementation.h.

const char* sRenderAPIVersion [static]

Shader render API version.

See also:
RenderAPIVersion

Definition at line 202 of file fbximplementation.h.

const char* sRootBindingName [static]

Name of root binding table.

See also:
RootBindingName

Definition at line 207 of file fbximplementation.h.

const char* sConstants [static]

Name of property to store the shader parameters(constants) values in this implementation.

See also:
GetConstants

Definition at line 212 of file fbximplementation.h.

const char* sDefaultType [static]

default value for implementation type.

Definition at line 215 of file fbximplementation.h.

const char* sDefaultLanguage [static]

default value for shader language.

Definition at line 218 of file fbximplementation.h.

const char* sDefaultLanguageVersion [static]

default value for shader language version.

Definition at line 221 of file fbximplementation.h.

const char* sDefaultRenderAPI [static]

default value for shader render API.

Definition at line 224 of file fbximplementation.h.

const char* sDefaultRenderAPIVersion [static]

default value for shader render API version.

Definition at line 227 of file fbximplementation.h.

const char* sDefaultRootBindingName [static]

default value for root binding table name.

Definition at line 230 of file fbximplementation.h.


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

FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation
FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation FbxImplementation