CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
OdGiProgressiveMesh Class Referenceabstract

#include <GiProgressiveMesh.h>

Inheritance diagram for OdGiProgressiveMesh:
OdRxObject

Public Types

enum  ProgressiveMeshStreamVersion { kVersion1 , kVersion2 , kVersionActual = kVersion2 }
 
enum  ProgressiveMeshAutoSelectLOD { kCustom = 0 , kSqrInterpolation = 1 , kSqrtInterpolation = 2 }
 

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdGiProgressiveMesh)
 
virtual bool obtainShell (OdVector< OdGePoint3d > &pts, OdVector< OdInt32 > &faces) const =0
 
virtual OdUInt32 obtainVertexData (OdGiProgressiveMeshVertexData &data, OdUInt32 flags) const =0
 
virtual OdUInt32 obtainFaceData (OdGiProgressiveMeshFaceData &data, OdUInt32 flags) const =0
 
virtual OdUInt32 obtainEdgeData (OdGiProgressiveMeshEdgeData &data, OdUInt32 flags) const =0
 
virtual OdUInt32 numLODs () const =0
 
virtual OdUInt32 currentLOD () const =0
 
virtual bool setLOD (OdUInt32)=0
 
virtual OdUInt32 selectLOD (ProgressiveMeshAutoSelectLOD lod, const OdGiViewport *pView, const OdGeMatrix3d *pModelToWorldTransform=NULL)=0
 
virtual OdGiProgressiveMeshAutoLODSelectOptionsautoSelectLODOptions ()=0
 
virtual const OdGiProgressiveMeshAutoLODSelectOptionsautoSelectLODOptions () const =0
 
virtual void setAutoSelectLODOptions (const OdGiProgressiveMeshAutoLODSelectOptions &options)=0
 
virtual void setCustomLODAutoSelectCallback (OdGiProgressiveMeshAutoLODSelectCallback *pCallback)=0
 
virtual OdGiProgressiveMeshAutoLODSelectCallbackgetCustomLODAutoSelectCallback () const =0
 
virtual OdUInt32 numFaces () const =0
 
virtual OdUInt32 numVertices () const =0
 
virtual const OdGeExtents3dextents () const =0
 
virtual bool write (OdStreamBuf *pBuff, const OdGiProgressiveMeshObjectIdConverter *pConverter=NULL, ProgressiveMeshStreamVersion version=kVersionActual) const =0
 
virtual bool isInPartialMode () const =0
 
virtual void endPartialMode ()=0
 
virtual OdUInt64 getObjectSize () const =0
 
- Public Member Functions inherited from OdRxObject
 ODRX_HEAP_OPERATORS ()
 
 OdRxObject ()
 
virtual ~OdRxObject ()
 
virtual OdRxObjectqueryX (const OdRxClass *pClass) const
 
virtual OdRxObjectx (const OdRxClass *pClass) const
 
virtual OdRxClassisA () const
 
virtual void addRef ()=0
 
virtual void release ()=0
 
virtual long numRefs () const
 
bool isKindOf (const OdRxClass *pClass) const
 
virtual OdRxObjectPtr clone () const
 
virtual void copyFrom (const OdRxObject *pSource)
 
virtual OdRx::Ordering comparedTo (const OdRxObject *pOther) const
 
virtual bool isEqualTo (const OdRxObject *pOther) const
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 

Detailed Description

This class represents interface of Progressive Mesh

See also
<link gi_geometry_progressive_mesh_usage, Usage of the Progressive Meshes in the OdGi Library>

Definition at line 279 of file GiProgressiveMesh.h.

Member Enumeration Documentation

◆ ProgressiveMeshAutoSelectLOD

Enumerates level of details auto selection type

Enumerator
kCustom 
kSqrInterpolation 
kSqrtInterpolation 

Definition at line 294 of file GiProgressiveMesh.h.

◆ ProgressiveMeshStreamVersion

Defines Progressive Mesh stream version

Enumerator
kVersion1 
kVersion2 
kVersionActual 

Definition at line 285 of file GiProgressiveMesh.h.

Member Function Documentation

◆ autoSelectLODOptions() [1/2]

virtual const OdGiProgressiveMeshAutoLODSelectOptions & OdGiProgressiveMesh::autoSelectLODOptions ( ) const
pure virtual

Retrives LOD auto select options

Returns
Returns LOD auto select options

◆ autoSelectLODOptions() [2/2]

virtual OdGiProgressiveMeshAutoLODSelectOptions & OdGiProgressiveMesh::autoSelectLODOptions ( )
pure virtual

Retrives LOD auto select options

Returns
Returns LOD auto select options

◆ currentLOD()

virtual OdUInt32 OdGiProgressiveMesh::currentLOD ( ) const
pure virtual

Retunrs current level of details

Remarks
0 is a minimum level of details, numLODs() is a maximum level of details

◆ endPartialMode()

virtual void OdGiProgressiveMesh::endPartialMode ( )
pure virtual

Loads all unloaded progresive mesh data and ends partial mode.

◆ extents()

virtual const OdGeExtents3d & OdGiProgressiveMesh::extents ( ) const
pure virtual

Returns extents of fully-detailed progressive mesh

◆ getCustomLODAutoSelectCallback()

virtual OdGiProgressiveMeshAutoLODSelectCallback * OdGiProgressiveMesh::getCustomLODAutoSelectCallback ( ) const
pure virtual

Retrives LOD auto select callback for ProgressiveMeshAutoSelectLOD::kCustom

Returns
Returns LOD auto select callback

◆ getObjectSize()

virtual OdUInt64 OdGiProgressiveMesh::getObjectSize ( ) const
pure virtual

Calculates RAM usage for this OdGiProgressiveMesh object.

Returns
Returns memory usage for this OdGiProgressiveMesh object.

◆ isInPartialMode()

virtual bool OdGiProgressiveMesh::isInPartialMode ( ) const
pure virtual

Checks whether progressive mesh is in partial mode or not.

Returns
Returns true if and only if progressive mesh is in partial mode; otherwise returns false.

◆ numFaces()

virtual OdUInt32 OdGiProgressiveMesh::numFaces ( ) const
pure virtual

Returns number of faces of progressive mesh on current level of details

◆ numLODs()

virtual OdUInt32 OdGiProgressiveMesh::numLODs ( ) const
pure virtual

Retunrs maximum level of details

◆ numVertices()

virtual OdUInt32 OdGiProgressiveMesh::numVertices ( ) const
pure virtual

Returns number of vertices of progressive mesh on current level of details

◆ obtainEdgeData()

virtual OdUInt32 OdGiProgressiveMesh::obtainEdgeData ( OdGiProgressiveMeshEdgeData data,
OdUInt32  flags 
) const
pure virtual

Obtains edge data of progressive mesh on current level of details

Parameters
data[out] OdGiProgressiveMeshEdgeData instance to store results
flags[in] Set of OdGiProgressiveMeshEdgeData::EdgeDataFlags bits that specifies required edge data fields
Returns
Returns set of OdGiProgressiveMeshEdgeData::EdgeDataFlags bits that specifies obtained edge data fields

◆ obtainFaceData()

virtual OdUInt32 OdGiProgressiveMesh::obtainFaceData ( OdGiProgressiveMeshFaceData data,
OdUInt32  flags 
) const
pure virtual

Obtains face data of progressive mesh on current level of details

Parameters
data[out] OdGiProgressiveMeshFaceData instance to store results
flags[in] Set of OdGiProgressiveMeshFaceData::FaceDataFlags bits that specifies required face data fields
Returns
Returns set of OdGiProgressiveMeshFaceData::FaceDataFlags bits that specifies obtained face data fields

◆ obtainShell()

virtual bool OdGiProgressiveMesh::obtainShell ( OdVector< OdGePoint3d > &  pts,
OdVector< OdInt32 > &  faces 
) const
pure virtual

Obtains geometry representation of progressive mesh on current level of details

Parameters
pts[out] OdVector for points
faces[out] OdVector for faces
Returns
Returns true if and only if geometry representation successfully obtained

◆ obtainVertexData()

virtual OdUInt32 OdGiProgressiveMesh::obtainVertexData ( OdGiProgressiveMeshVertexData data,
OdUInt32  flags 
) const
pure virtual

Obtains vertex data of progressive mesh on current level of details

Parameters
data[out] OdGiProgressiveMeshVertexData instance to store results
flags[in] Set of OdGiProgressiveMeshVertexData::VertexDataFlags bits that specifies required vertex data fields
Returns
Returns set of OdGiProgressiveMeshVertexData::VertexDataFlags bits that specifies obtained vertex data fields

◆ ODRX_DECLARE_MEMBERS()

OdGiProgressiveMesh::ODRX_DECLARE_MEMBERS ( OdGiProgressiveMesh  )

◆ selectLOD()

virtual OdUInt32 OdGiProgressiveMesh::selectLOD ( ProgressiveMeshAutoSelectLOD  lod,
const OdGiViewport pView,
const OdGeMatrix3d pModelToWorldTransform = NULL 
)
pure virtual

Selects most appropriate level of details for specified view

Parameters
pView[in] Pointer to the view
pModelToWorldTransform[in] Pointer to the "model to world" transformation matrix, may be NULL
Returns
Returns appropriate LOD value or OdUInt32(-1) if LOD selection fails
Remarks
This method do perform LOD switching, so return value may be used for monitoring purposes

◆ setAutoSelectLODOptions()

virtual void OdGiProgressiveMesh::setAutoSelectLODOptions ( const OdGiProgressiveMeshAutoLODSelectOptions options)
pure virtual

Specifies LOD auto select options

Parameters
options[in] LOD auto select options

◆ setCustomLODAutoSelectCallback()

virtual void OdGiProgressiveMesh::setCustomLODAutoSelectCallback ( OdGiProgressiveMeshAutoLODSelectCallback pCallback)
pure virtual

Specifies LOD auto select callback for ProgressiveMeshAutoSelectLOD::kCustom

Parameters
pCallback[in] LOD auto select callback

◆ setLOD()

virtual bool OdGiProgressiveMesh::setLOD ( OdUInt32  )
pure virtual

Switchs progressive mesh to the specified level of details

◆ write()

virtual bool OdGiProgressiveMesh::write ( OdStreamBuf pBuff,
const OdGiProgressiveMeshObjectIdConverter pConverter = NULL,
ProgressiveMeshStreamVersion  version = kVersionActual 
) const
pure virtual

Writes progressive mesh into the stream

Remarks
OdGiProgressiveMeshObjectIdConverter is required for writing DbStubs to the stream (materials). Converter may be NULL. In this case Data Flags with OdDbStub fileld will be reseted for writing. So, for example, face materials will be lost.

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