Rhino C++ API  7.22
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
ON_MappingTag Class Reference

#include <opennurbs_mesh.h>

Public Member Functions

 ON_MappingTag ()
 
 ON_MappingTag (const ON_TextureMapping &mapping, const ON_Xform *xform)
 
int Compare (const ON_MappingTag &other, bool bCompareId=true, bool bCompareCRC=true, bool bCompareXform=true) const
 
void Default ()
 
void Dump (ON_TextLog &) const
 
const ON_SHA1_Hash Hash () const
 
bool IsDefaultSurfaceParameterMapping () const
 
bool IsSet () const
 
bool Read (ON_BinaryArchive &)
 
void Set (const ON_TextureMapping &mapping)
 
void SetDefaultSurfaceParameterMappingTag ()
 
const ON_Xform Transform () const
 
void Transform (const ON_Xform &xform)
 
bool TransformIsIdentity () const
 
bool Write (ON_BinaryArchive &) const
 

Static Public Member Functions

static int CompareAll (const ON_MappingTag &lhs, const ON_MappingTag &rhs)
 
static int CompareAllFromPointer (const ON_MappingTag *lhs, const ON_MappingTag *rhs)
 
static bool TransformTreatedIsIdentity (const ON_Xform *xform)
 

Public Attributes

ON__UINT32 m_mapping_crc = 0
 ON_TextureMapping::MappingCRC() (from decades ago - a sha1 would be better when SDK can break) More...
 
ON_UUID m_mapping_id = ON_nil_uuid
 ON_TextureMapping::m_mapping_id. More...
 
ON_TextureMapping::TYPE m_mapping_type = ON_TextureMapping::TYPE::no_mapping
 ON_TextureMapping::m_type. More...
 
ON_Xform m_mesh_xform = ON_Xform::IdentityTransformation
 

Static Public Attributes

static const ON_MappingTag SurfaceParameterMapping
 
static const ON_MappingTag Unset
 

Constructor & Destructor Documentation

◆ ON_MappingTag() [1/2]

ON_MappingTag::ON_MappingTag ( )

◆ ON_MappingTag() [2/2]

ON_MappingTag::ON_MappingTag ( const ON_TextureMapping mapping,
const ON_Xform xform 
)

Member Function Documentation

◆ Compare()

int ON_MappingTag::Compare ( const ON_MappingTag other,
bool  bCompareId = true,
bool  bCompareCRC = true,
bool  bCompareXform = true 
) const

◆ CompareAll()

static int ON_MappingTag::CompareAll ( const ON_MappingTag lhs,
const ON_MappingTag rhs 
)
static

◆ CompareAllFromPointer()

static int ON_MappingTag::CompareAllFromPointer ( const ON_MappingTag lhs,
const ON_MappingTag rhs 
)
static

◆ Default()

void ON_MappingTag::Default ( )

◆ Dump()

void ON_MappingTag::Dump ( ON_TextLog ) const

◆ Hash()

const ON_SHA1_Hash ON_MappingTag::Hash ( ) const

Returns: A sha1 hash the identifies the mapping tag.

◆ IsDefaultSurfaceParameterMapping()

bool ON_MappingTag::IsDefaultSurfaceParameterMapping ( ) const

Returns: True if the mapping tag is for a mapping with type ON_TextureMapping::srfp_mapping with m_uvw = identity.

◆ IsSet()

bool ON_MappingTag::IsSet ( ) const

Returns: True if the mapping tag is set.

◆ Read()

bool ON_MappingTag::Read ( ON_BinaryArchive )

◆ Set()

void ON_MappingTag::Set ( const ON_TextureMapping mapping)

◆ SetDefaultSurfaceParameterMappingTag()

void ON_MappingTag::SetDefaultSurfaceParameterMappingTag ( )

Description: Sets the tag to the value the meshes have that come out of ON_Brep::CreateMesh().

◆ Transform() [1/2]

const ON_Xform ON_MappingTag::Transform ( ) const

Returns: World space transformation to apply to the object when using this mapping.

◆ Transform() [2/2]

void ON_MappingTag::Transform ( const ON_Xform xform)

◆ TransformIsIdentity()

bool ON_MappingTag::TransformIsIdentity ( ) const

Returns: True if Transform() will return the identity transformation.

◆ TransformTreatedIsIdentity()

static bool ON_MappingTag::TransformTreatedIsIdentity ( const ON_Xform xform)
static

Returns: True if ON_MappingTag will consider xform to be the identity transformation.

◆ Write()

bool ON_MappingTag::Write ( ON_BinaryArchive ) const

Member Data Documentation

◆ m_mapping_crc

ON__UINT32 ON_MappingTag::m_mapping_crc = 0

ON_TextureMapping::MappingCRC() (from decades ago - a sha1 would be better when SDK can break)

◆ m_mapping_id

ON_UUID ON_MappingTag::m_mapping_id = ON_nil_uuid

ON_TextureMapping::m_mapping_id.

Identifies the mapping used to create the texture coordinates and records transformations applied to the mesh after the texture coordinates were calculated. If the texture mapping does not change when the mesh is transformed, then set m_mesh_xform to zero so that compares will work right.

◆ m_mapping_type

◆ m_mesh_xform

ON_Xform ON_MappingTag::m_mesh_xform = ON_Xform::IdentityTransformation

◆ SurfaceParameterMapping

const ON_MappingTag ON_MappingTag::SurfaceParameterMapping
static

◆ Unset

const ON_MappingTag ON_MappingTag::Unset
static