FCDTexture Class Reference
[COLLADA Effect Classes [ColladaFX]]

A COLLADA texture. More...

#include <FCDTexture.h>

Inheritance diagram for FCDTexture:

FCDEntity FCDObjectWithId FCDObject FUObject List of all members.

Public Member Functions

 FCDTexture (FCDocument *document)
 Constructor: do not use directly.
virtual ~FCDTexture ()
 Destructor: do not use directly.
virtual Type GetType () const
 Retrieves the type of the entity class.
FUDaeTextureChannel::Channel GetTextureChannel () const
 Retrieves which texture channel to use for this texture.
FCDImageGetImage ()
 Retrieves the image information for this texture.
const FCDImageGetImage () const
 See above.
void SetImage (FCDImage *_image)
 Sets the image to be used with this texture.
FCDEffectParameterIntGetSet ()
 Retrieves the texture coordinate set to use with this texture.
const FCDEffectParameterIntGetSet () const
 See above.
FUDaeBlendMode::Mode GetBlendMode () const
 Retrieves the blend mode to use if this texture is not the first one within its channel's bucket.
void SetBlendMode (FUDaeBlendMode::Mode mode)
 Sets the blend mode to use if this texture is not the first one within its channel's bucket.
const string & GetSubId () const
void SetSubId (const string &_subId)
float & GetMultiplier ()
 Retrieves the generic multiplier to apply on the texture.
const float & GetMultiplier () const
 See above.
void SetMultiplier (float _multiplier)
 Sets the generic multiplier.
bool HasPlacement2D () const
 Retrieves whether the texturing information includes the ColladaMaya-specific 2D placement parameters.
void ClearPlacement2D ()
 Removes the ColladaMaya-specific 2D placement parameters and resets them.
float & GetWrapU ()
 Retrieves whether to wrap the U texture coordinates.
const float & GetWrapU () const
 See above.
void SetWrapU (bool _wrapU)
 Sets whether to wrap the U texture coordinates.
float & GetWrapV ()
 Retrieves whether to wrap the V texture coordinates.
const float & GetWrapV () const
 See above.
void SetWrapV (bool _wrapV)
 Sets whether to wrap the V texture coordinates.
float & GetMirrorU ()
 Retrieves whether to mirror the U texture coordinates.
const float & GetMirrorU () const
 See above.
void SetMirrorU (bool _mirrorU)
 Sets whether to mirror the U texture coordinates.
float & GetMirrorV ()
 Retrieves whether to mirror the V texture coordinates.
const float & GetMirrorV () const
 See above.
void SetMirrorV (bool _mirrorV)
 Sets whether to mirror the V texture coordinates.
float & GetStagger ()
 Retrieves whether to stagger the texture.
const float & GetStagger () const
 See above.
void SetStagger (bool _stagger)
 Sets whether to stagger the texture.
float & GetFast ()
 Retrieves the 'fast' flag.
const float & GetFast () const
 See above.
void SetFast (bool _fast)
 Sets the 'fast' flag.
float & GetCoverageU ()
 Retrieves the scale factor of the texture frame, in the U coordinates.
const float & GetCoverageU () const
 See above.
void SetCoverageU (float _coverageU)
 Sets the scale factor of the texture frame, in the U coordinates.
float & GetCoverageV ()
 Retrieves the scale factor of the texture frame, in the V coordinates.
const float & GetCoverageV () const
 See above.
void SetCoverageV (float _coverageV)
 Sets the scale factor of the texture frame, in the V coordinates.
float & GetTranslateFrameU ()
 Retrieves the translation of the texture frame, in the U coordinate.
const float & GetTranslateFrameU () const
 See above.
void SetTranslateFrameU (float _translateFrameU)
 Sets the translation of the texture frame, in the U coordinate.
float & GetTranslateFrameV ()
 Retrieves the translation of the texture frame, in the V coordinate.
const float & GetTranslateFrameV () const
 See above.
void SetTranslateFrameV (float _translateFrameV)
 Sets the translation of the texture frame, in the V coordinate.
float & GetRotateFrame ()
 Retrieves the angle of rotation of the texture frame.
const float & GetRotateFrame () const
 See above.
void SetRotateFrame (float _rotateFrame)
 Sets the angle of rotation of the texture frame.
float & GetRepeatU ()
 Retrieves the scale factor applied on the U coordinates of the rendered polygons.
const float & GetRepeatU () const
 See above.
void SetRepeatU (float _repeatU)
 Sets the scale factor applied on the U coordinates of the rendered polygons.
float & GetRepeatV ()
 Retrieves the scale factor applied on the V coordinates of the rendered polygons.
const float & GetRepeatV () const
 See above.
void SetRepeatV (float _repeatV)
 Sets the scale factor applied on the V coordinates of the rendered polygons.
float & GetOffsetU ()
 Retrieves the translation offset applied on the U coordinates of the rendered polygons.
const float & GetOffsetU () const
 See above.
void SetOffsetU (float _offsetU)
 Sets the translation offset applied on the U coordinates of the rendered polygons.
float & GetOffsetV ()
 Retrieves the translation offset applied on the V coordinates of the rendered polygons.
const float & GetOffsetV () const
 See above.
void SetOffsetV (float _offsetV)
 Sets the translation offset applied on the V coordinates of the rendered polygons.
float & GetRotateUV ()
 Retrieves the rotation angle applied on the texture coordinates of the rendered polygons.
const float & GetRotateUV () const
 See above.
void SetRotateUV (float _rotateUV)
 Sets the rotation angle applied on the texture coordinates of the rendered polygons.
float & GetNoiseU ()
 Retrieves the maxmimum amount of noise to add to each of the U coordinates of the rendered polygons.
const float & GetNoiseU () const
 See above.
void SetNoiseU (float _noiseU)
 Sets the maximum amount of noise to add to each of the U coordinates of the rendered polygons.
float & GetNoiseV ()
 Retrieves the maxmimum amount of noise to add to each of the V coordinates of the rendered polygons.
const float & GetNoiseV () const
 See above.
void SetNoiseV (float _noiseV)
 Sets the maximum amount of noise to add to each of the V coordinates of the rendered polygons.
bool HasProjection3D () const
 Retrieves whether the texturing information includes the ColladaMaya-specific 3D projection parameters.
void ClearProjection3D ()
 Removes the ColladaMaya-specific 3D projection parameters and resets them.
FMMatrix44GetProjectionMatrix ()
 Retrieves the texture projection matrix.
const FMMatrix44GetProjectionMatrix () const
 See above.
void SetProjectionMatrix (const FMMatrix44 &matrix)
 Sets the texture projection matrix.
const fstring & GetProjectionType () const
 Retrieves the type of projection to use on the 3D texture coordinates.
void SetProjectionType (const fstring &type)
 Sets the type of projection to use on the 3D texture coordinates.
FCDEffectParameterFindParameterBySemantic (const string &semantic)
 Retrieves an effect parameter.
void FindParametersBySemantic (const string &semantic, FCDEffectParameterList &parameters)
 Retrieves a subset of the local effect parameter list.
void FindParametersByReference (const string &reference, FCDEffectParameterList &parameters)
 Retrieves a subset of the local effect parameter list.
FCDTextureClone ()
 [INTERNAL] Clones the texture.
FUStatus LoadFromTextureXML (xmlNode *textureNode)
 [INTERNAL] Reads in the texture from a given COLLADA XML tree node.
virtual FUStatus LoadFromXML (xmlNode *textureNode)
 [INTERNAL] Reads in the texture from a given COLLADA XML tree node.
virtual xmlNode * WriteToXML (xmlNode *parentNode)
 [INTERNAL] Writes out the texture to the given COLLADA XML tree node.

Detailed Description

A COLLADA texture.

Textures are used by the COMMON profile materials. For COLLADA 1.3 backward compatibility, the textures may also be entities contained within the material library. The ColladaFX profiles use the FCDEffectParameterSampler and the FCDEffectParameterSurface classes, instead, to hold the texturing information.

Textures hold the information necessary to place an image onto polygon sets. This information includes: which texture coordinate set to use, which image contains the texels, the blend mode, the components of the texture matrix, etc.

Most of the texturing information does not belong to COLLADA and is specific to either Maya or 3dsMax.


Constructor & Destructor Documentation

FCDTexture::FCDTexture FCDocument document  ) 
 

Constructor: do not use directly.

Instead, use the FCDEffectStandard::AddTexture function.

Parameters:
document The COLLADA document that owns this texture.

virtual FCDTexture::~FCDTexture  )  [virtual]
 

Destructor: do not use directly.

Instead, use the FCDEffectStandard::ReleaseTexture function.


Member Function Documentation

FCDTexture* FCDTexture::Clone  ) 
 

[INTERNAL] Clones the texture.

Does not clone the image: both texture objects will point to the same image object.

Returns:
The cloned texture. This pointer will never be NULL.

FCDEffectParameter* FCDTexture::FindParameterBySemantic const string &  semantic  ) 
 

Retrieves an effect parameter.

Looks for the effect parameter with the correct semantic, in order to bind or override its value. This function compares the local effect parameters with the given semantic.

Parameters:
semantic The effect parameter semantic to match.
Returns:
The effect parameter that matches the semantic. This pointer may be NULL if no effect parameter matches the given semantic.

void FCDTexture::FindParametersByReference const string &  reference,
FCDEffectParameterList parameters
 

Retrieves a subset of the local effect parameter list.

Look for the local effect parameter with the correct reference.

Parameters:
reference The effect parameter reference to match.
parameters The list of parameters to fill in. This list is not cleared.

void FCDTexture::FindParametersBySemantic const string &  semantic,
FCDEffectParameterList parameters
 

Retrieves a subset of the local effect parameter list.

Look for local effect parameters with the correct semantic. This function searches through the effect profile and the level of abstractions below.

Parameters:
semantic The effect parameter semantic to match.
parameters The list of parameters to fill in. This list is not cleared.

FUDaeBlendMode::Mode FCDTexture::GetBlendMode  )  const [inline]
 

Retrieves the blend mode to use if this texture is not the first one within its channel's bucket.

Returns:
The blend mode.

float& FCDTexture::GetCoverageU  )  [inline]
 

Retrieves the scale factor of the texture frame, in the U coordinates.

This parameter is specific to ColladaMaya. This value is animatable. For more information on this parameter, check the Maya documentation.

Returns:
The scale factor.

float& FCDTexture::GetCoverageV  )  [inline]
 

Retrieves the scale factor of the texture frame, in the V coordinates.

This parameter is specific to ColladaMaya. This value is animatable. For more information on this parameter, check the Maya documentation.

Returns:
The scale factor.

float& FCDTexture::GetFast  )  [inline]
 

Retrieves the 'fast' flag.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean. This parameter has no meaning outside of Maya.

Returns:
The 'fast' flag.

FCDImage* FCDTexture::GetImage  )  [inline]
 

Retrieves the image information for this texture.

Returns:
The image. This pointer will be NULL if this texture is not yet tied to a valid image.

float& FCDTexture::GetMirrorU  )  [inline]
 

Retrieves whether to mirror the U texture coordinates.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean.

Returns:
Whether to mirror the U texture coordinate.

float& FCDTexture::GetMirrorV  )  [inline]
 

Retrieves whether to mirror the V texture coordinates.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean.

Returns:
Whether to mirror the V texture coordinate.

float& FCDTexture::GetMultiplier  )  [inline]
 

Retrieves the generic multiplier to apply on the texture.

This parameter is specific to ColladaMax. The meaning of this parameter depends on the channel that the texture belongs to. This value is animatable.

Returns:
The generic multiplier.

float& FCDTexture::GetNoiseU  )  [inline]
 

Retrieves the maxmimum amount of noise to add to each of the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The maxmimum amount of noise.

float& FCDTexture::GetNoiseV  )  [inline]
 

Retrieves the maxmimum amount of noise to add to each of the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The maxmimum amount of noise.

float& FCDTexture::GetOffsetU  )  [inline]
 

Retrieves the translation offset applied on the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The translation offset.

float& FCDTexture::GetOffsetV  )  [inline]
 

Retrieves the translation offset applied on the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The translation offset.

FMMatrix44& FCDTexture::GetProjectionMatrix  )  [inline]
 

Retrieves the texture projection matrix.

This matrix transforms the 3D texture coordinates into valid 2D texture coordinates. This parameter is specific to ColladaMaya.

Returns:
The texture projection matrix.

const fstring& FCDTexture::GetProjectionType  )  const [inline]
 

Retrieves the type of projection to use on the 3D texture coordinates.

This parameter is specific to ColladaMaya.

Returns:
The type string.

float& FCDTexture::GetRepeatU  )  [inline]
 

Retrieves the scale factor applied on the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The scale factor.

float& FCDTexture::GetRepeatV  )  [inline]
 

Retrieves the scale factor applied on the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The scale factor.

float& FCDTexture::GetRotateFrame  )  [inline]
 

Retrieves the angle of rotation of the texture frame.

This parameter is specific to ColladaMaya. This value is animatable. For more information on this parameter, check the Maya documentation.

Returns:
The angle of rotation (in degrees).

float& FCDTexture::GetRotateUV  )  [inline]
 

Retrieves the rotation angle applied on the texture coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Returns:
The rotation angle (in degrees).

FCDEffectParameterInt* FCDTexture::GetSet  )  [inline]
 

Retrieves the texture coordinate set to use with this texture.

This information is duplicated from the material instance abstraction level.

Returns:
The effect parameter containing the set.

float& FCDTexture::GetStagger  )  [inline]
 

Retrieves whether to stagger the texture.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean.

Returns:
Whether to stagger the texture.

const string& FCDTexture::GetSubId  )  const [inline]
 

Deprecated:
Retrieves the sub-id of the texture.
Returns:
The sub-id.

FUDaeTextureChannel::Channel FCDTexture::GetTextureChannel  )  const [inline]
 

Retrieves which texture channel to use for this texture.

As it is directly tied in with which buckets holds this texture, you cannot modify this value. Instead, create a new texture in the correct bucket of the FCDEffectStandard object.

Returns:
The texture channel.

float& FCDTexture::GetTranslateFrameU  )  [inline]
 

Retrieves the translation of the texture frame, in the U coordinate.

This parameter is specific to ColladaMaya. This value is animatable. For more information on this parameter, check the Maya documentation.

Returns:
The translation offset.

float& FCDTexture::GetTranslateFrameV  )  [inline]
 

Retrieves the translation of the texture frame, in the V coordinate.

This parameter is specific to ColladaMaya. This value is animatable. For more information on this parameter, check the Maya documentation.

Returns:
The translation offset.

virtual Type FCDTexture::GetType  )  const [inline, virtual]
 

Retrieves the type of the entity class.

This function is part of the FCDEntity interface and is used for COLLADA 1.3 backward compatibility.

Returns:
The entity class type: TEXTURE.

Reimplemented from FCDEntity.

float& FCDTexture::GetWrapU  )  [inline]
 

Retrieves whether to wrap the U texture coordinates.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean.

Returns:
Whether to wrap the U texture coordinates.

float& FCDTexture::GetWrapV  )  [inline]
 

Retrieves whether to wrap the V texture coordinates.

This parameter is specific to ColladaMaya. This value is a float because it is animatable: it should be interpreted as a boolean.

Returns:
Whether to wrap the V texture coordinates.

bool FCDTexture::HasPlacement2D  )  const [inline]
 

Retrieves whether the texturing information includes the ColladaMaya-specific 2D placement parameters.

Returns:
Whether the ColladaMaya-specific 2D placement parameters are valid.

bool FCDTexture::HasProjection3D  )  const [inline]
 

Retrieves whether the texturing information includes the ColladaMaya-specific 3D projection parameters.

Returns:
Whether the ColladaMaya-specific 3D projection parameters are valid.

FUStatus FCDTexture::LoadFromTextureXML xmlNode *  textureNode  ) 
 

[INTERNAL] Reads in the texture from a given COLLADA XML tree node.

Parameters:
textureNode The COLLADA XML tree node.
Returns:
The status of the import. If the status is not successful, it may be dangerous to extract information from the texture.

virtual FUStatus FCDTexture::LoadFromXML xmlNode *  textureNode  )  [virtual]
 

[INTERNAL] Reads in the texture from a given COLLADA XML tree node.

This function is useful only for COLLADA 1.3 backward compatibility.

Parameters:
textureNode The COLLADA XML tree node.
Returns:
The status of the import. If the status is not successful, it may be dangerous to extract information from the texture.

Reimplemented from FCDEntity.

void FCDTexture::SetBlendMode FUDaeBlendMode::Mode  mode  )  [inline]
 

Sets the blend mode to use if this texture is not the first one within its channel's bucket.

Parameters:
mode The blend mode.

void FCDTexture::SetCoverageU float  _coverageU  )  [inline]
 

Sets the scale factor of the texture frame, in the U coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_coverageU The scale factor.

void FCDTexture::SetCoverageV float  _coverageV  )  [inline]
 

Sets the scale factor of the texture frame, in the V coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_coverageV The scale factor.

void FCDTexture::SetFast bool  _fast  )  [inline]
 

Sets the 'fast' flag.

This parameter is specific to ColladaMaya and has no meaning outside of Maya.

Parameters:
_fast The 'fast' flag.

void FCDTexture::SetImage FCDImage _image  )  [inline]
 

Sets the image to be used with this texture.

Parameters:
_image An image.

void FCDTexture::SetMirrorU bool  _mirrorU  )  [inline]
 

Sets whether to mirror the U texture coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_mirrorU Whether to mirror the U texture coordinates.

void FCDTexture::SetMirrorV bool  _mirrorV  )  [inline]
 

Sets whether to mirror the V texture coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_mirrorV Whether to mirror the V texture coordinates.

void FCDTexture::SetMultiplier float  _multiplier  )  [inline]
 

Sets the generic multiplier.

This parameter is specific to ColladaMax. The meaning of this parameter depends on the channel that the texture belongs to.

Parameters:
_multiplier The generic multiplier.

void FCDTexture::SetNoiseU float  _noiseU  )  [inline]
 

Sets the maximum amount of noise to add to each of the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_noiseU The maximum amount of noise.

void FCDTexture::SetNoiseV float  _noiseV  )  [inline]
 

Sets the maximum amount of noise to add to each of the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_noiseV The maximum amount of noise.

void FCDTexture::SetOffsetU float  _offsetU  )  [inline]
 

Sets the translation offset applied on the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_offsetU The translation offset.

void FCDTexture::SetOffsetV float  _offsetV  )  [inline]
 

Sets the translation offset applied on the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_offsetV The translation offset.

void FCDTexture::SetProjectionMatrix const FMMatrix44 matrix  )  [inline]
 

Sets the texture projection matrix.

This matrix transforms the 3D texture coordinates into valid 2D texture coordinates. This parameter is specific to ColladaMaya.

Parameters:
matrix The texture projection matrix.

void FCDTexture::SetProjectionType const fstring &  type  )  [inline]
 

Sets the type of projection to use on the 3D texture coordinates.

This paramter is specific to ColladaMaya.

Parameters:
type The type string.

void FCDTexture::SetRepeatU float  _repeatU  )  [inline]
 

Sets the scale factor applied on the U coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_repeatU The scale factor.

void FCDTexture::SetRepeatV float  _repeatV  )  [inline]
 

Sets the scale factor applied on the V coordinates of the rendered polygons.

This parameter is specific to ColladaMaya.

Parameters:
_repeatV The scale factor.

void FCDTexture::SetRotateFrame float  _rotateFrame  )  [inline]
 

Sets the angle of rotation of the texture frame.

This parameter is specific to ColladaMaya. For more information on this parameter, check the Maya documentation.

Parameters:
_rotateFrame The angle of rotation (in degrees).

void FCDTexture::SetRotateUV float  _rotateUV  )  [inline]
 

Sets the rotation angle applied on the texture coordinates of the rendered polygons.

This parameter is specific to ColladaMaya. This value is animatable.

Parameters:
_rotateUV The rotation angle (in degrees).

void FCDTexture::SetStagger bool  _stagger  )  [inline]
 

Sets whether to stagger the texture.

This parameter is specific to ColladaMaya.

Parameters:
_stagger Whether to stagger the texture.

void FCDTexture::SetSubId const string &  _subId  )  [inline]
 

Deprecated:
Sets the sub-id of the texture.
Parameters:
_subId The sub-id.

void FCDTexture::SetTranslateFrameU float  _translateFrameU  )  [inline]
 

Sets the translation of the texture frame, in the U coordinate.

This parameter is specific to ColladaMaya. For more information on this parameter, check the Maya documentation.

Parameters:
_translateFrameU The translation offset.

void FCDTexture::SetTranslateFrameV float  _translateFrameV  )  [inline]
 

Sets the translation of the texture frame, in the V coordinate.

This parameter is specific to ColladaMaya. For more information on this parameter, check the Maya documentation.

Parameters:
_translateFrameV The translation offset.

void FCDTexture::SetWrapU bool  _wrapU  )  [inline]
 

Sets whether to wrap the U texture coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_wrapU Whether to wrap the U texture coordinate.

void FCDTexture::SetWrapV bool  _wrapV  )  [inline]
 

Sets whether to wrap the V texture coordinates.

This parameter is specific to ColladaMaya.

Parameters:
_wrapV Whether to wrap the V texture coordinate.

virtual xmlNode* FCDTexture::WriteToXML xmlNode *  parentNode  )  [virtual]
 

[INTERNAL] Writes out the texture to the given COLLADA XML tree node.

Parameters:
parentNode The COLLADA XML parent node in which to insert the texture.
Returns:
The created element XML tree node.


The documentation for this class was generated from the following file:
Generated on Fri May 12 16:44:44 2006 for FCollada by  doxygen 1.4.6-NO