$darkmode
VCG Library
Public Types | Public Member Functions | Static Public Member Functions | List of all members
vcg::tri::UpdateSelection< ComputeMeshType > Class Template Reference

Management, updating and conditional computation of selections (per-vertex, per-edge, and per-face). More...

#include <vcg/complex/algorithms/update/selection.h>

Public Types

typedef ComputeMeshType MeshType
 
typedef MeshType::ScalarType ScalarType
 
typedef MeshType::VertexType VertexType
 
typedef MeshType::VertexPointer VertexPointer
 
typedef MeshType::VertexIterator VertexIterator
 
typedef MeshType::EdgeIterator EdgeIterator
 
typedef MeshType::EdgeType EdgeType
 
typedef MeshType::FaceType FaceType
 
typedef MeshType::FacePointer FacePointer
 
typedef MeshType::FaceIterator FaceIterator
 
typedef MeshType::TetraType TetraType
 
typedef MeshType::TetraPointer TetraPointer
 
typedef MeshType::TetraIterator TetraIterator
 
typedef vcg::Box3< ScalarType > Box3Type
 

Public Member Functions

void VertexNonManifoldEdges (MeshType &m, bool preserveSelection=false)
 

Static Public Member Functions

static size_t VertexAll (MeshType &m)
 This function select all the vertices.
 
static size_t EdgeAll (MeshType &m)
 This function select all the edges.
 
static size_t FaceAll (MeshType &m)
 This function select all the faces.
 
static size_t TetraAll (MeshType &m)
 This function select all the tetras.
 
static size_t VertexClear (MeshType &m)
 This function clear the selection flag for all the vertices.
 
static size_t EdgeClear (MeshType &m)
 This function clears the selection flag for all the edges.
 
static size_t FaceClear (MeshType &m)
 This function clears the selection flag for all the faces.
 
static size_t TetraClear (MeshType &m)
 This function clears the selection flag for all the tetras.
 
static void Clear (MeshType &m)
 This function clears the selection flag for all the elements of a mesh (vertices, edges, and faces).
 
static size_t FaceCount (const MeshType &m)
 This function returns the number of selected faces.
 
static size_t EdgeCount (const MeshType &m)
 This function returns the number of selected edges.
 
static size_t VertexCount (const MeshType &m)
 This function returns the number of selected vertices.
 
static size_t TetraCount (const MeshType &m)
 This function returns the number of selected tetras.
 
static size_t FaceInvert (MeshType &m)
 This function inverts the selection flag for all the faces.
 
static size_t EdgeInvert (MeshType &m)
 This function inverts the selection flag for all the edges.
 
static size_t VertexInvert (MeshType &m)
 This function inverts the selection flag for all the vertices.
 
static size_t TetraInvert (MeshType &m)
 This function inverts the selection flag for all the tetras.
 
static size_t VertexFromFaceLoose (MeshType &m, bool preserveSelection=false)
 Select all the vertices that are touched by at least a single selected faces.
 
static size_t VertexFromEdgeLoose (MeshType &m, bool preserveSelection=false)
 Select all the vertices that are touched by at least a single selected edge.
 
static size_t VertexFromFaceStrict (MeshType &m, bool preserveSelection=false)
 Select ONLY the vertices that are touched ONLY by selected faces. More...
 
static size_t FaceFromVertexStrict (MeshType &m, bool preserveSelection=false)
 Select ONLY the faces with ALL the vertices selected.
 
static size_t FaceFromVertexLoose (MeshType &m, bool preserveSelection=false)
 Select all the faces with at least one selected vertex.
 
static size_t FaceDilate (MeshType &m)
 This function dilate the face selection by simply first selecting all the vertices touched by the faces and then all the faces touched by these vertices Note: it destroys the vertex selection.

 
static size_t FaceErode (MeshType &m)
 This function erode the face selection by simply first selecting only the vertices completely surrounded by face and then the only faces with all the selected vertices Note: it destroys the vertex selection.

 
static size_t VertexFromBorderFlag (MeshType &m, bool preserveSelection=false)
 This function select the vertices with the border flag set.
 
static size_t FaceFromBorderFlag (MeshType &m, bool preserveSelection=false)
 This function select the faces that have an edge with the border flag set.
 
static size_t FaceOutOfRangeEdge (MeshType &m, ScalarType MinEdgeThr, ScalarType MaxEdgeThr=(std::numeric_limits< ScalarType >::max)(), bool preserveSelection=false)
 This function select the faces that have an edge outside the given range. You can skip the second parameter to choose all the edges smaller than a given lenght.
 
static size_t FaceConnectedFF (MeshType &m)
 This function expand current selection to cover the whole connected component.
 
static size_t FaceFromQualityRange (MeshType &m, float minq, float maxq, bool preserveSelection=false)
 Select the faces whose quality is in the specified closed interval.
 
static size_t VertexFromQualityRange (MeshType &m, float minq, float maxq, bool preserveSelection=false)
 Select the vertices whose quality is in the specified closed interval.
 
static size_t VertexInBox (MeshType &m, const Box3Type &bb, bool preserveSelection=false)
 Select the vertices contained in the specified Box.
 
static size_t VertexCornerBorder (MeshType &m, ScalarType angleRad, bool preserveSelection=false)
 Select the border vertices that form a corner along the border with an angle that is below a certain threshold (e.g. with 90 will select all the acute angles) It assumes that the Per-Vertex border Flag has been set.
 

Detailed Description

template<class ComputeMeshType>
class vcg::tri::UpdateSelection< ComputeMeshType >

Management, updating and conditional computation of selections (per-vertex, per-edge, and per-face).

This class is used to compute or update the selected bit flag that can be stored in the vertex, edge or face component of a mesh.

Member Function Documentation

◆ VertexFromFaceStrict()

template<class ComputeMeshType >
static size_t vcg::tri::UpdateSelection< ComputeMeshType >::VertexFromFaceStrict ( MeshType &  m,
bool  preserveSelection = false 
)
inlinestatic

Select ONLY the vertices that are touched ONLY by selected faces.

In other words this function will select all the vertices having all the faces incident on them selected.


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