FiberVISH 0.2
Fish - The Fiber Bundle API for the Vish Visualization Shell
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Fiber::Edges Class Reference

Identify the edges on a skeleton within a Grid. More...

#include <Edges.hpp>

Inheritance diagram for Fiber::Edges:
Fiber::LineSetWithEdges Fiber::MDHistory Fiber::TriangularSurfaceWithEdges

Public Types

typedef EdgeCell32 EdgeCell_t
 
typedef TriangleCell32 TriangleCell_t
 
typedef TypedArray< Eagle::PhysicalSpace::pointCoordsArray_t
 
typedef MemArray< 1, Eagle::PhysicalSpace::pointCoordsMemArray_t
 
typedef MultiArray< 1, Eagle::PhysicalSpace::pointCoordsMultiArray_m_t
 
typedef MemArray< 1, EdgeCell_tEdgesArray_t
 
typedef MemArray< 1, TriangleCell_tTriArray_t
 
typedef MemArray< 1, std::vector< index_t > > IndexSetArray_t
 
typedef MemArray< 1, Eagle::tvector3 > TangentialVector_t
 
typedef std::vector< index_tEdgesPerVertex_t
 Edges per vertex: variable length!
 
typedef MemArray< 1, EdgesPerVertex_tEdgesPerVertexMemArray_t
 

Public Member Functions

 Edges (const RefPtr< Grid > &G)
 Retrieve a Edge information from a Grid object.
 
 ~Edges ()
 Destructor, cleans up references.
 

Static Public Member Functions

static SkeletonID EdgeSkeletonID ()
 Return the skeleton ID that refers to the Edges property of a cw-complex.
 
static SkeletonID ID ()
 Return a skeleton ID that is characteristic for Grid objects that carry Edge information.
 
static RefPtr< SkeletongetEdgeSkeleton (const RefPtr< Grid > &G, bool CreateIfNotFound)
 Return the Skeleton that holds all the information that is given on Edges of a Grid object.
 
static RefPtr< RepresentationgetVerticesPerEdge (const RefPtr< Grid > &G, bool CreateIfNotFound)
 Find the information how edges are represented as Vertices, which is two vertices are given per Edge ID.
 
static RefPtr< FieldgetVerticesPerEdgeField (const RefPtr< Grid > &G)
 Return the Positions field of the edges given as vertices.
 
static RefPtr< EdgesArray_tgetVerticesPerEdgeArray (const RefPtr< Grid > &G)
 Return the data array that holds the edges as vertices.
 
static bool addVerticesPerEdgeField (const RefPtr< Grid > &G, const RefPtr< Field > &theField)
 Add a new Field describing the Edge information to a certain Grid object.
 
static bool addVerticesPerEdgeArray (const RefPtr< Grid > &G, const RefPtr< EdgesArray_t > &Data)
 Add a new array of edges to the Edge information of a certain Grid object.
 
static bool addVerticesPerEdgeArray (const RefPtr< Grid > &G, const RefPtr< MemCore::TypedChunk< EdgeCell_t > > &EdgeData)
 
static RefPtr< RepresentationgetEdgesPerVertex (const RefPtr< Grid > &G, bool CreateIfNotFound)
 Find the information how vertices are related to edges, which can be varying, the element type of the Positions field is thus dependent on the type of mesh.
 
static RefPtr< FieldgetEdgesPerVertexField (const RefPtr< Grid > &G, bool CreateIfNotFound)
 
static RefPtr< EdgesArray_tgetEdgesPerVertexArray (const RefPtr< Grid > &G)
 
static bool addEdgesPerVertex (const RefPtr< Grid > &G, const RefPtr< Field > &theField)
 
static RefPtr< EdgesPerVertexMemArray_tcreateEdgesPerVertex (const RefPtr< Grid > &G, bool storeThem)
 Get all edges of each vertex;.
 

Public Attributes

RefPtr< SkeletonEdgeSkeleton
 
RefPtr< RepresentationVerticesPerEdge
 
RefPtr< FieldVerticesPerEdgeField
 
RefPtr< EdgesArray_tVerticesPerEdgeArray
 

Detailed Description

Identify the edges on a skeleton within a Grid.

The Grid must carry Vertices in Cartesian coordinates and a (1,1) Skeleton which is a set of Edges.

The positions field of the Edges is an array of EdgeCell elements that refer to the vertices of each Edge index.

Examples
Sphere.cpp.

Constructor & Destructor Documentation

◆ Edges()

Fiber::Edges::Edges ( const RefPtr< Grid > &  G)

Retrieve a Edge information from a Grid object.

CONSTRUCTOR.

References getEdgeSkeleton(), getVerticesPerEdge(), getVerticesPerEdgeArray(), and getVerticesPerEdgeField().

Member Function Documentation

◆ addVerticesPerEdgeArray()

bool Fiber::Edges::addVerticesPerEdgeArray ( const RefPtr< Grid > &  G,
const RefPtr< EdgesArray_t > &  Data 
)
static

Add a new array of edges to the Edge information of a certain Grid object.

The same array can be retrieved from a Grid object via the getEdgesAsVerticesArray(const RefPtr<Grid>&G); call.

Note
The edge array will be kept in memory as long as the associate Grid object lives.

References getVerticesPerEdge().

Referenced by Fiber::TriangularSurfaceWithEdges::create().

◆ addVerticesPerEdgeField()

bool Fiber::Edges::addVerticesPerEdgeField ( const RefPtr< Grid > &  G,
const RefPtr< Field > &  theField 
)
static

Add a new Field describing the Edge information to a certain Grid object.

The Field may or may not store data yet, and may be fragmented (not supported by all functions). This is the reverse function to getVerticesPerEdgeField(const RefPtr<Grid>&G);

References getVerticesPerEdge().

◆ createEdgesPerVertex()

RefPtr< Edges::EdgesPerVertexMemArray_t > Fiber::Edges::createEdgesPerVertex ( const RefPtr< Grid > &  G,
bool  storeThem 
)
static

◆ EdgeSkeletonID()

static SkeletonID Fiber::Edges::EdgeSkeletonID ( )
inlinestatic

Return the skeleton ID that refers to the Edges property of a cw-complex.

This will be the (1,1) skeleton, with lines being of dimensionality one and index depth one (referring to vertices).

Referenced by getEdgeSkeleton().

◆ getEdgesPerVertex()

RefPtr< Representation > Fiber::Edges::getEdgesPerVertex ( const RefPtr< Grid > &  G,
bool  CreateIfNotFound 
)
static

Find the information how vertices are related to edges, which can be varying, the element type of the Positions field is thus dependent on the type of mesh.

  1. For a set of lines, there will only be two edges adjacent to each vertex, the array type in the Positions will be EdgesArray_t .
  2. For a triangular surface there will be three edges adjacent to each vertex, the array type in the Positions TriArray_t .
  3. For an arbitrary polygonal mesh, there may be a varying number of edges for each vertex, the array type in the Positions will then be IndexSetArray_t , which is most inefficient on all operations and should be avoided.

This information is reverse to getEdgesAsVertices() and can be computed from the edges given as vertices.

References getEdgeSkeleton().

◆ getVerticesPerEdge()

RefPtr< Representation > Fiber::Edges::getVerticesPerEdge ( const RefPtr< Grid > &  G,
bool  CreateIfNotFound 
)
static

Find the information how edges are represented as Vertices, which is two vertices are given per Edge ID.

The number of edges will be the same as for all entries in the getEdgeSkeleton().

The Positions field here will tell, given an Edge ID, what are the vertex ID's here. The data type will be available as EdgeCell_t.

References getEdgeSkeleton().

Referenced by addVerticesPerEdgeArray(), addVerticesPerEdgeField(), Edges(), and getVerticesPerEdgeField().

◆ getVerticesPerEdgeArray()

RefPtr< Edges::EdgesArray_t > Fiber::Edges::getVerticesPerEdgeArray ( const RefPtr< Grid > &  G)
static

Return the data array that holds the edges as vertices.

This function assumes an unfragmented field.

References getVerticesPerEdgeField().

Referenced by Fiber::TriangularSurfaceWithEdges::create(), createEdgesPerVertex(), and Edges().

◆ ID()

static SkeletonID Fiber::Edges::ID ( )
inlinestatic

Return a skeleton ID that is characteristic for Grid objects that carry Edge information.

In this case it will be the (1,1) skeleton, being of dimensionality one and index depth one (referring to vertices).