Simplygon C++ API  8.3.35800.0
SimplygonSDK::ITangentCalculator Class Referenceabstract

#include <SimplygonSDK.h>

Inheritance diagram for SimplygonSDK::ITangentCalculator:
SimplygonSDK::IObject

Public Member Functions

virtual void CalculateTangents (IGeometryData *geom)=0
 
virtual void CalculateTangents (ISceneNode *node)=0
 
virtual const char * GetClass ()
 
virtual rid GetTangentCalculatorType ()=0
 
virtual bool IsA (const char *type) const
 
virtual void SetTangentCalculatorType (rid type)=0
 
virtual void SetTexCoordsSetId (rid value)=0
 
- Public Member Functions inherited from SimplygonSDK::IObject
virtual rid AddObserver (robserver *Observer, rid EventId)=0
 
virtual void AddRef ()=0
 
virtual rstring GetName ()=0
 
virtual void * GetUserComponentArea (rid userid)=0
 
virtual void PrintInfo ()=0
 
virtual void Release ()=0
 
virtual void RemoveObserver (rid ObserverId)=0
 
virtual void SetName (const char *Name)=0
 

Static Public Member Functions

static bool IsClassA (const char *type)
 
static ITangentCalculatorSafeCast (IObject *ptr)
 
- Static Public Member Functions inherited from SimplygonSDK::IObject
static bool IsClassA (const char *type)
 
static IObjectSafeCast (IObject *ptr)
 

Detailed Description

IGeometryTangentCalculator calculates tangent vectors for geometry data objects. One corner field of texture coordinates must exist, as well as normals. The Tangents are placed into two corner fields called "Tangents" and "Bitangents". If any of these fields already exists, it is replaced by the new field.

Definition at line 10621 of file SimplygonSDK.h.

Member Function Documentation

◆ CalculateTangents() [1/2]

virtual void SimplygonSDK::ITangentCalculator::CalculateTangents ( IGeometryData geom)
pure virtual

Calculates the tangents of a geometry data object.

Parameters
geomthe geometry object receives new fields, as described in the class description.

◆ CalculateTangents() [2/2]

virtual void SimplygonSDK::ITangentCalculator::CalculateTangents ( ISceneNode node)
pure virtual

Calculates the tangents of a tree of scene nodes (only the geometry nodes of course).

Parameters
nodeis the scene node that will have itselfs and its childrens tangents calculated

◆ GetClass()

virtual const char* SimplygonSDK::ITangentCalculator::GetClass ( )
virtual

GetClass returns the name of the class of the object.

Returns
the name of the actual class of the object, as a const char string

Reimplemented from SimplygonSDK::IObject.

◆ GetTangentCalculatorType()

virtual rid SimplygonSDK::ITangentCalculator::GetTangentCalculatorType ( )
pure virtual

Gets the tangent calculator type, types listed in SimplygonSDK::TangentSpaceMethod

Returns
the current tangent calculator type

◆ IsA()

virtual bool SimplygonSDK::ITangentCalculator::IsA ( const char *  type) const
virtual

The IsA function returns true if the object is a or is a descendant of the class named as the type parameter

Parameters
typeis the name of the class to check if the object is, or is a descendant of
Returns
true if the object is of the specified class, false if not

Reimplemented from SimplygonSDK::IObject.

◆ IsClassA()

static bool SimplygonSDK::ITangentCalculator::IsClassA ( const char *  type)
inlinestatic

The IsClassA function returns true if ITangentCalculator is a or is a descendant of the class named as the type parameter

Parameters
typeis the name of the class to check if the class is, or is a descendant of
Returns
true if the class is of the specified class, false if not

Definition at line 10642 of file SimplygonSDK.h.

◆ SafeCast()

static ITangentCalculator* SimplygonSDK::ITangentCalculator::SafeCast ( IObject ptr)
inlinestatic

SafeCast makes sure the pointer is of a class that can be cast into a ITangentCalculator pointer, and if this is possible, returns the cast pointer.

Parameters
ptris the pointer to be cast into a ITangentCalculator pointer
Returns
a pointer to the ITangentCalculator object, if the cast can be made, and a NULL pointer otherwise

Definition at line 10655 of file SimplygonSDK.h.

◆ SetTangentCalculatorType()

virtual void SimplygonSDK::ITangentCalculator::SetTangentCalculatorType ( rid  type)
pure virtual

Sets the tangent calculator type, types listed in SimplygonSDK::TangentSpaceMethod

Parameters
typethe desired tangent calculator type Value cannot be less than SG_TANGENTSPACEMETHOD_ORTHONORMAL. Value cannot be greater than SG_TANGENTSPACEMETHOD_ORTHONORMAL_LEFTHANDED.

◆ SetTexCoordsSetId()

virtual void SimplygonSDK::ITangentCalculator::SetTexCoordsSetId ( rid  value)
pure virtual

The TexCoords field id to use for the tangent calculation. If set to -1, all texture coordinates will get corresponding tangent fields.

Parameters
valuethe TexCoords set id

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