Visual Computing Library  devel
Loading...
Searching...
No Matches
vcl::CompId Struct Reference

The CompId struct enumerates the components that can compose a element or a mesh. More...

#include <vclib/mesh/components/base/base.h>

Public Types

enum  Enum {
  BIT_FLAGS = 0 , POSITION , NORMAL , COLOR ,
  QUALITY , MARK , PRINCIPAL_CURVATURE , TEX_COORD ,
  VERTEX_REFERENCES , ADJACENT_EDGES , ADJACENT_FACES , ADJACENT_VERTICES ,
  WEDGE_COLORS , WEDGE_TEX_COORDS , BOUNDING_BOX , NAME ,
  TEXTURE_IMAGES , TEXTURE_PATHS , TRANSFORM_MATRIX , CUSTOM_COMPONENTS ,
  COMPONENTS_NUMBER
}
 

Detailed Description

The CompId struct enumerates the components that can compose a element or a mesh.

The components are identified by an unsigned integer value, that can be used to access the component of the element or mesh through a template parameter, without having to know the actual type of the component.

For example, you can access the position component of an element with the following code:

auto& p = e.template component<CompId::POSITION>();
A class representing a box in N-dimensional space.
Definition box.h:46

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