#include <c4d_variationshaderdata.h>
Public Types | |
typedef NodeData | SUPER |
![]() | |
typedef PrivateChunk | SUPER |
Private Member Functions | |
virtual Bool | Init () |
virtual void | Free () |
Allocation/Free | |
static VariationShaderData * | Alloc () |
static void | Free (VariationShaderData *&v) |
Read/Write | |
virtual Bool | Read (HyperFile *hf, Int32 id, Int32 level) |
Bool | Write (HyperFile *hf) |
Add / Remove textures | |
Bool | AddTextureLayer (TextureLayer layerData) |
TextureLayer | GetTextureLayer (Int32 textureId) |
Bool | RemoveTextureLayer (Int32 textureId) |
Bool | RemoveAllTextures () |
Int32 | GetTextureCount () |
Bool | GetActive (Int32 textureId) |
Bool | SetActive (Int32 textureId, Bool active) |
Float | GetPropability (Int32 textureId) |
Bool | SetPropability (Int32 textureId, Float probability) |
Bool | Distribute (DISTRIBUTION dis) |
Additional Inherited Members | |
![]() | |
virtual Bool | Execute () |
virtual Int32 | GetDiskType () const |
virtual Bool | CopyToX (PrivateChunk *dst, COPYFLAGS flags, AliasTrans *trans) |
virtual Bool | TranslateDescID (GeListNode *node, const DescID &id, DescID &res_id, GeListNode *&res_at) |
![]() | |
virtual Bool | HandleSubChunk (HyperFile *hf, Int32 id, Int32 level) |
Node data class for Cinema 4D's Variation shader.
|
virtual |
Reimplemented from NodeData.
|
privatevirtual |
Called when an instance of a derived node data class needs to be initialized.
Reimplemented from NodeData.
|
privatevirtual |
Reimplemented from NodeData.
|
static |
Allocates a VariationShaderData. Destroy the allocated VariationShaderData with Free().
|
static |
Destructs VariationShaderData allocated with Alloc().
[in,out] | v | The VariationShaderData to destruct. If the pointer is nullptr nothing happens. The pointer is assigned nullptr afterwards. |
Reads the variation shader data from a hyper file.
[in] | hf | The hyper file to read from. The caller owns the pointed hyper file. |
[in] | id | The ID of the node to read. |
[in] | level | The disklevel of the node to read. |
Reimplemented from NodeData.
Writes the variation shader to a hyper file.
[in] | hf | The hyper file to write to. The caller owns the pointed hyper file. |
Reimplemented from PrivateChunk.
Bool AddTextureLayer | ( | TextureLayer | layerData | ) |
Adds a new texture layer.
[in] | layerData | The data to be used for the new texture layer. |
TextureLayer GetTextureLayer | ( | Int32 | textureId | ) |
Gets the data of the texture layer.
[in] | textureId | The ID to get the data for. |
Removes a texture layer.
[in] | textureId | The ID of the texture layer to remove. |
Bool RemoveAllTextures | ( | ) |
Removes all texture layers from the shader list except the first one.
Int32 GetTextureCount | ( | ) |
Returns the amount of textures the shader list contains.
Returns the activation state of the texture layer.
[in] | textureId | The ID of the layer to get the state for. |
Enables or disables a texture layer.
[in] | textureId | The ID of the texture to set the state for. |
[in] | active | true to enable or or false to disable the layer. |
Returns the probability of the texture layer.
[in] | textureId | The ID of the layer to get the probability for. |
Sets the probability for the texture layer.
[in] | textureId | The ID of the texture to set the probability for. |
[in] | probability | The new probability value of the layer. |
Bool Distribute | ( | DISTRIBUTION | dis | ) |
Distributes the probability values for all textures in the shader list.
[in] | dis | The type of distribution: DISTRIBUTION |