Rhino C++ API  7.21
Public Member Functions | Public Attributes | List of all members
ON_DepthImageTriangleMesh Class Reference

#include <opennurbs_plus_idimage.h>

Public Member Functions

 ON_DepthImageTriangleMesh ()
 
 ~ON_DepthImageTriangleMesh ()
 
void Destroy ()
 
void GetRenderVertex (unsigned int vertex_index, struct RENDER_VERTEX *render_vertex) const
 
bool GetTriangleLocation (unsigned int triangle_index, ON_3dPoint location[3]) const
 
void GetTriangleRenderVertices (unsigned int triangle_index, struct RENDER_VERTEX render_vertex[3]) const
 
bool GetVertexLocation (unsigned int vertex_index, ON_3dPoint *location) const
 
bool Grow (size_t vertex_capacity, size_t triangle_capacity)
 
ON_DepthImage::VISIBILITY ProjectMesh (const class ON_DepthImage &image)
 
bool Set (const class ON_Mesh *mesh, bool bAsReference)
 
bool Set (ON_BoundingBox bbox, double expansion_distance)
 
bool TriangleIsVisible (unsigned int triangle_index) const
 
unsigned int TriangleStatus (unsigned int triangle_index) const
 
void Unset ()
 

Public Attributes

unsigned int m_and_triangle_status
 
unsigned int m_and_vertex_status
 
ON_DepthImage::VISIBILITY m_mesh_visibility
 
unsigned int m_or_triangle_status
 
unsigned int m_or_vertex_status
 
const unsigned int * m_T
 
size_t m_T_count
 triangles (specified as three vertex indices) More...
 
size_t m_T_stride
 
unsigned int * m_triangle_status
 
const double * m_V
 vertex locations More...
 
size_t m_V_count
 vertices More...
 
size_t m_V_stride
 
unsigned int * m_vertex_status
 

Constructor & Destructor Documentation

◆ ON_DepthImageTriangleMesh()

ON_DepthImageTriangleMesh::ON_DepthImageTriangleMesh ( )

◆ ~ON_DepthImageTriangleMesh()

ON_DepthImageTriangleMesh::~ON_DepthImageTriangleMesh ( )

Member Function Documentation

◆ Destroy()

void ON_DepthImageTriangleMesh::Destroy ( )

◆ GetRenderVertex()

void ON_DepthImageTriangleMesh::GetRenderVertex ( unsigned int  vertex_index,
struct RENDER_VERTEX *  render_vertex 
) const

◆ GetTriangleLocation()

bool ON_DepthImageTriangleMesh::GetTriangleLocation ( unsigned int  triangle_index,
ON_3dPoint  location[3] 
) const

◆ GetTriangleRenderVertices()

void ON_DepthImageTriangleMesh::GetTriangleRenderVertices ( unsigned int  triangle_index,
struct RENDER_VERTEX  render_vertex[3] 
) const

◆ GetVertexLocation()

bool ON_DepthImageTriangleMesh::GetVertexLocation ( unsigned int  vertex_index,
ON_3dPoint location 
) const

◆ Grow()

bool ON_DepthImageTriangleMesh::Grow ( size_t  vertex_capacity,
size_t  triangle_capacity 
)

◆ ProjectMesh()

ON_DepthImage::VISIBILITY ON_DepthImageTriangleMesh::ProjectMesh ( const class ON_DepthImage image)

Returns: true if some portion of the mesh may be visible. false if no portion of the mesh is visible.

◆ Set() [1/2]

bool ON_DepthImageTriangleMesh::Set ( const class ON_Mesh mesh,
bool  bAsReference 
)

Parameters: mesh - [in] bAsReference [ in] true: When possible, this triangle mesh will reference mesh vertex and face information. In this case, the caller must insure mesh stays in scope and is not modified while this triangle mesh is in use. false: mesh vertex and face information is copied and this triangle mesh is independent from mesh.

◆ Set() [2/2]

bool ON_DepthImageTriangleMesh::Set ( ON_BoundingBox  bbox,
double  expansion_distance 
)

Parameters: bbox - [in] expansion_distance - [in] Before creating the triangle mesh, expand the bounding box by adding this distance to each of the bbox.m_max coordinates and subtracting this distance from each of the bbox.m_min coordinates.

◆ TriangleIsVisible()

bool ON_DepthImageTriangleMesh::TriangleIsVisible ( unsigned int  triangle_index) const

Returns: True if the triangle is visible. "Visible" means

  • The triangle is valid.
  • Either false = m_bSkipBackfaces or the triangle is front facing.
  • A bitwise and of the corner vertex clipflags is zero.
  • No corner vertex is invalid.

◆ TriangleStatus()

unsigned int ON_DepthImageTriangleMesh::TriangleStatus ( unsigned int  triangle_index) const

◆ Unset()

void ON_DepthImageTriangleMesh::Unset ( )

Member Data Documentation

◆ m_and_triangle_status

unsigned int ON_DepthImageTriangleMesh::m_and_triangle_status

◆ m_and_vertex_status

unsigned int ON_DepthImageTriangleMesh::m_and_vertex_status

m_mesh_vertex_status is a bitwise or of every m_vertex_status[] value that belongs to a triangle that may be visisble.

◆ m_mesh_visibility

ON_DepthImage::VISIBILITY ON_DepthImageTriangleMesh::m_mesh_visibility

◆ m_or_triangle_status

unsigned int ON_DepthImageTriangleMesh::m_or_triangle_status

◆ m_or_vertex_status

unsigned int ON_DepthImageTriangleMesh::m_or_vertex_status

◆ m_T

const unsigned int* ON_DepthImageTriangleMesh::m_T

◆ m_T_count

size_t ON_DepthImageTriangleMesh::m_T_count

triangles (specified as three vertex indices)

◆ m_T_stride

size_t ON_DepthImageTriangleMesh::m_T_stride

◆ m_triangle_status

unsigned int* ON_DepthImageTriangleMesh::m_triangle_status

m_triangle_capacity | (0xFF00 & (triangle CLIP_STATUS bits))

◆ m_V

const double* ON_DepthImageTriangleMesh::m_V

vertex locations

◆ m_V_count

size_t ON_DepthImageTriangleMesh::m_V_count

vertices

◆ m_V_stride

size_t ON_DepthImageTriangleMesh::m_V_stride

◆ m_vertex_status

unsigned int* ON_DepthImageTriangleMesh::m_vertex_status

[m_vertex_capacity] & 0xFF = CLIP_STATUS, & 0xFF00 = VERTEX_STATUS & 0xFFFF0000 = custom clipping region status