CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Attributes | List of all members
OdGiMapper Class Reference

#include <GiMaterial.h>

Public Types

enum  Projection {
  kInheritProjection = 0 , kPlanar = 1 , kBox = 2 , kCylinder = 3 ,
  kSphere = 4 , kDgnParametric = 0x32 , kDgnPlanar = 0x33 , kDgnCylinder = 0x34 ,
  kDgnCylinderCapped = 0x35 , kDgnSphere = 0x36
}
 
enum  Tiling {
  kInheritTiling = 0 , kTile = 1 , kCrop = 2 , kClamp = 3 ,
  kMirror = 4
}
 
enum  AutoTransform { kInheritAutoTransform = 0x0 , kNone = 0x1 , kObject = 0x2 , kModel = 0x4 }
 

Public Member Functions

 OdGiMapper ()
 
 OdGiMapper (const OdGiMapper &mapper)
 
OdGiMapperoperator= (const OdGiMapper &mapper)
 
bool operator== (const OdGiMapper &mapper) const
 
bool operator!= (const OdGiMapper &mapper) const
 
void setProjection (Projection projection)
 
void setUTiling (Tiling tiling)
 
void setVTiling (Tiling tiling)
 
void setAutoTransform (AutoTransform autoTransform)
 
OdGeMatrix3dtransform ()
 
Projection projection () const
 
Tiling uTiling () const
 
Tiling vTiling () const
 
AutoTransform autoTransform () const
 
const OdGeMatrix3dtransform () const
 
void setTransform (const OdGeMatrix3d &tm)
 

Static Public Attributes

static ODGI_EXPORT_STATIC const OdGiMapper kIdentity
 

Detailed Description

This class implements mappers.

Remarks
Mappers determine how an OdGiMaterialMap is mapped to an object surface.
See also
<link tv_working_with_attributes_materials_mapping, Work with Mapping Properties>

<group OdGi_Classes>

Definition at line 1514 of file GiMaterial.h.

Member Enumeration Documentation

◆ AutoTransform

Specifies the automatic transform mode.

Enumerator
kInheritAutoTransform 

Inherits automatic transform mode from the current material's mapper.

kNone 

No automatic transform.

kObject 

Adjusts the mapper transform to align with and fit the current object.

kModel 

Multiplies the mapper transform by the current block transform.

Definition at line 1564 of file GiMaterial.h.

◆ Projection

Specifies the mapping projection.

Enumerator
kInheritProjection 

Inherits projection from the current material's mapper.

kPlanar 

Maps directly to XY coordinates.

kBox 

Maps to planes perpendicular to major axes.

kCylinder 

Maps to cylinders aligned with the Z-axis.

kSphere 

Maps to spheres aligned with the Z-axis.

kDgnParametric 

Maps directly to surface coordinates. For .dgn materials.

kDgnPlanar 

Maps directly to surface coordinates. For .dgn materials.

kDgnCylinder 

Maps to cylinders aligned with the Z-axis. For .dgn materials.

kDgnCylinderCapped 

Maps to cylinders aligned with the Z-axis. If normal to surface is the same as Z-axis, then uses planar mapping. For .dgn materials.

kDgnSphere 

Maps to spheres aligned with the Z-axis. For .dgn materials.

Definition at line 1520 of file GiMaterial.h.

◆ Tiling

Specifies the mapper's tiling method.

Enumerator
kInheritTiling 

Inherits tiling from the current material's mapper.

kTile 

Repeats map along image axes.

kCrop 

Crops map < 0.0 or > 1.0 on image axes.

kClamp 

Clamps (stretches) map between 0.0 and 1.0 on image axes.

kMirror 

Mirrors the material map at every integer boundary.

Definition at line 1547 of file GiMaterial.h.

Constructor & Destructor Documentation

◆ OdGiMapper() [1/2]

OdGiMapper::OdGiMapper ( )
inline

Default constructor for the OdGiMapper class. Sets the mapping projection to kPlanar, u- and v-tiling to kTile and automatic transform method to kNone.

Definition at line 1582 of file GiMaterial.h.

◆ OdGiMapper() [2/2]

OdGiMapper::OdGiMapper ( const OdGiMapper mapper)
inline

Copy constructor for the OdGiMapper class. Copies projection, of the specified mapper.

Parameters
mapper[in] Mapper to be copied.

Definition at line 2138 of file GiMaterial.h.

Member Function Documentation

◆ autoTransform()

OdGiMapper::AutoTransform OdGiMapper::autoTransform ( ) const
inline

Retrieves the type of automatic transform for this Mapper object.

Returns
a value from the AutoTransform enumeration which can be one of the following:

Value Description kInheritAutoTransform 0x0 Inherits automatic transform from the current material's mapper. kNone 0x1 No automatic transform. kObject 0x2 Adjusts the mapper transform to align with and fit the current object. kModel 0x4 Multiplies the mapper transform by the current block transform.

Definition at line 2220 of file GiMaterial.h.

◆ operator!=()

bool OdGiMapper::operator!= ( const OdGiMapper mapper) const
inline

Inequality operator for the OdGiMapper class. The objects are not equal if at least one of the following conditions fails: projection methods are equal. u- and v-tiling methods are equal automatic transform methods are equal transform matrices are equal

Parameters
mapper[in] Mapper to be compared.
Returns
true if the specified mapper is equal to this mapper, false otherwise.

Definition at line 2172 of file GiMaterial.h.

◆ operator=()

OdGiMapper & OdGiMapper::operator= ( const OdGiMapper mapper)
inline

Assignment operator for the OdGiMapper class.

Parameters
mapper[in] Mapper to be assigned.
Returns
a reference to this mapper.

Definition at line 2148 of file GiMaterial.h.

◆ operator==()

bool OdGiMapper::operator== ( const OdGiMapper mapper) const
inline

Equality operator for the OdGiMapper class. The objects are equal if: projection methods are equal. u- and v-tiling methods are equal automatic transform methods are equal transform matrices are equal

Parameters
mapper[in] Mapper to be compared.
Returns
true if the specified mapper is equal to this mapper, false otherwise.

Definition at line 2162 of file GiMaterial.h.

◆ projection()

OdGiMapper::Projection OdGiMapper::projection ( ) const
inline

Retrieves the type of projection for this Mapper object.

Returns
a value from the Projection enumeration which can be one of the following:

Value Description kInheritProjection 0 Inherits projection from the current material's mapper. kPlanar 1 Maps directly to XY coordinates. kBox 2 Maps to planes perpendicular to major axes. kCylinder 3 Maps to cylinders aligned with the Z-axis. kSphere 4 Maps to spheres aligned with the Z-axis.

Definition at line 2202 of file GiMaterial.h.

◆ setAutoTransform()

void OdGiMapper::setAutoTransform ( AutoTransform  autoTransform)
inline

Sets the type of automatic transform for this Mapper object.

Parameters
autoTransform[in] Automatic transform type.
Remarks
autoTransform must be one of the following:

Value Description kInheritAutoTransform 0x0 Inherits automatic transform from the current material's mapper. kNone 0x1 No automatic transform. kObject 0x2 Adjusts the mapper transform to align with and fit the current object. kModel 0x4 Multiplies the mapper transform by the current block transform.

Definition at line 2196 of file GiMaterial.h.

◆ setProjection()

void OdGiMapper::setProjection ( Projection  projection)
inline

Sets the type of projection for this Mapper object.

Parameters
projection[in] Projection type.
Remarks
projection must be one of the following:

Value Description kInheritProjection 0 Inherits projection from the current material's mapper. kPlanar 1 Maps directly to XY coordinates. kBox 2 Maps to planes perpendicular to major axes. kCylinder 3 Maps to cylinders aligned with the Z-axis. kSphere 4 Maps to spheres aligned with the Z-axis.

Definition at line 2178 of file GiMaterial.h.

◆ setTransform()

void OdGiMapper::setTransform ( const OdGeMatrix3d tm)
inline

Applies the transformation matrix for this Mapper object.

Parameters
tm[in] Transformation matrix.

Definition at line 2238 of file GiMaterial.h.

◆ setUTiling()

void OdGiMapper::setUTiling ( Tiling  tiling)
inline

Sets the type of X-axis tiling for this Mapper object.

Parameters
tiling[in] Tiling type.
Remarks
tiling must be one of the following:

Value Description kInheritTiling 0 Inherits tiling from the current material's mapper. kTile 1 Repeats map along image axes. kCrop 2 Crops map < 0.0 or > 1.0 on image axes. kClamp 3 Clamps (stretches) map between 0.0 and 1.0 on image axes. kMirror 4 Mirrors the material map at every integer boundary.

Definition at line 2184 of file GiMaterial.h.

◆ setVTiling()

void OdGiMapper::setVTiling ( Tiling  tiling)
inline

Sets the type of Y-axis tiling for this Mapper object.

Parameters
tiling[in] Tiling type.
Remarks
tiling must be one of the following:

Value Description kInheritTiling 0 Inherits tiling from the current material's mapper. kTile 1 Repeats map along image axes. kCrop 2 Crops map < 0.0 or > 1.0 on image axes. kClamp 3 Clamps (stretches) map between 0.0 and 1.0 on image axes. kMirror 4 Mirrors the material map at every integer boundary.

Definition at line 2190 of file GiMaterial.h.

◆ transform() [1/2]

OdGeMatrix3d & OdGiMapper::transform ( )
inline

Retrieves the transformation matrix for this Mapper object.

Returns
a reference to OdGeMatrix3d that represents the transformation matrix of this mapper.
Remarks
The transform matrix defines mapping of an OdGiMaterialMap image when applied to the surface of an object.

Definition at line 2232 of file GiMaterial.h.

◆ transform() [2/2]

const OdGeMatrix3d & OdGiMapper::transform ( ) const
inline

Retrieves the transformation matrix for this Mapper object.

Returns
reference to the OdGeMatrix3d that represents transform matrix for this mapper.

Definition at line 2226 of file GiMaterial.h.

◆ uTiling()

OdGiMapper::Tiling OdGiMapper::uTiling ( ) const
inline

Retrieves the type of X-axis tiling for this Mapper object.

Returns
a value from the Tiling enumeration which can be one of the following:

Value Description kInheritTiling 0 Inherits tiling from the current material's mapper. kTile 1 Repeats map along image axes. kCrop 2 Crops map < 0.0 or > 1.0 on image axes. kClamp 3 Clamps (stretches) map between 0.0 and 1.0 on image axes. kMirror 4 Mirrors the material map at every integer boundary.

Definition at line 2208 of file GiMaterial.h.

◆ vTiling()

OdGiMapper::Tiling OdGiMapper::vTiling ( ) const
inline

Retrieves the type of Y-axis tiling for this Mapper object.

Returns
a value from the Tiling enumeration which can be one of the following:

Value Description kInheritTiling 0 Inherits tiling from the current material's mapper. kTile 1 Repeats map along image axes. kCrop 2 Crops map < 0.0 or > 1.0 on image axes. kClamp 3 Clamps (stretches) map between 0.0 and 1.0 on image axes. kMirror 4 Mirrors the material map at every integer boundary.

Definition at line 2214 of file GiMaterial.h.

Member Data Documentation

◆ kIdentity

ODGI_EXPORT_STATIC const OdGiMapper OdGiMapper::kIdentity
static

Definition at line 1576 of file GiMaterial.h.


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