Viskores  1.0
Public Types | Static Public Attributes | List of all members
viskores::CellTraits< CellTag > Struct Template Reference

Information about a cell based on its tag. More...

#include <CellTraits.h>

Public Types

using TopologicalDimensionsTag = viskores::CellTopologicalDimensionsTag< TOPOLOGICAL_DIMENSIONS >
 This tag is typedef'ed to viskores::CellTopologicalDimensionsTag<TOPOLOGICAL_DIMENSIONS>. More...
 
using IsSizeFixed = viskores::CellTraitsTagSizeFixed
 A tag specifying whether the number of points is fixed. More...
 

Static Public Attributes

static const viskores::IdComponent TOPOLOGICAL_DIMENSIONS = 3
 This defines the topological dimensions of the cell type. More...
 
static constexpr viskores::IdComponent NUM_POINTS = 3
 Number of points in the cell. More...
 

Detailed Description

template<class CellTag>
struct viskores::CellTraits< CellTag >

Information about a cell based on its tag.

The templated CellTraits struct provides the basic high level information about cells (like the number of vertices in the cell or its dimensionality).

Member Typedef Documentation

◆ IsSizeFixed

template<class CellTag >
using viskores::CellTraits< CellTag >::IsSizeFixed = viskores::CellTraitsTagSizeFixed

A tag specifying whether the number of points is fixed.

If set to viskores::CellTraitsTagSizeFixed, then NUM_POINTS is set. If set to viskores::CellTraitsTagSizeVariable, then the number of points is not known at compile time.

◆ TopologicalDimensionsTag

This tag is typedef'ed to viskores::CellTopologicalDimensionsTag<TOPOLOGICAL_DIMENSIONS>.

This provides a convenient way to overload a function based on topological dimensions (which is usually more efficient than conditionals).

Member Data Documentation

◆ NUM_POINTS

template<class CellTag >
constexpr viskores::IdComponent viskores::CellTraits< CellTag >::NUM_POINTS = 3
staticconstexpr

Number of points in the cell.

This is only defined for cell shapes of a fixed number of points (i.e., IsSizedFixed is set to viskores::CellTraitsTagSizeFixed).

◆ TOPOLOGICAL_DIMENSIONS

template<class CellTag >
const viskores::IdComponent viskores::CellTraits< CellTag >::TOPOLOGICAL_DIMENSIONS = 3
static

This defines the topological dimensions of the cell type.

3 for polyhedra, 2 for polygons, 1 for lines, 0 for points.


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