MeVisLabToolboxReference
ml::VesselEdge Class Reference

Class VesselEdge. More...

#include <mlVesselEdge.h>

Inheritance diagram for ml::VesselEdge:
ml::BaseGraphItem ml::PropertyContainer ml::Base

List of all members.

Public Member Functions

 VesselEdge (const VesselEdge &other)
 Copy constructor (creates an unconnected object, only copies properties), deprecated.
 ~VesselEdge ()
 Destructor.
VesselEdgeoperator= (const VesselEdge &other)
 Assignment operator, deprecated. Use copyProperties() instead.
void copyProperties (const VesselEdge *other)
 Copy all properties (topology information is left unchanged)
bool operator== (const VesselEdge &other) const
bool operator!= (const VesselEdge &other) const
Graph topology
VesselNodepredNode ()
 Get the predecessor node of this edge.
const VesselNodepredNode () const
VesselNodesuccNode ()
 Get the successor node of this edge.
const VesselNodesuccNode () const
void setPred (VesselNode *node)
 Connect edge-head to node node.
void setSucc (VesselNode *node)
 Connect edge-tail to node node.
bool isPred (const VesselNode *node) const
 Is the graphNode the preceding node of the edge?
bool isSucc (const VesselNode *node) const
 Is the graphNode the succeeding node of the edge?
void switchDirection ()
 Change direction of the edge by exchanging pred. and succ. node.
void setCycle ()
 Store dependent ids.
void unsetCycle ()
bool isCycle () const
Graph geometry
double distance (Vector3 vp) const
 Get the euclidean distance between the edge and vp.
std::pair< MLdouble, size_t > getDistanceAndNearestSkeletonIndex (const Vector3 &pos) const
Vector3 extent () const
 Get the edge's extent.
SubImageBoxd getBoundingBox () const
 Bounding box of the edge.
void transform (const Matrix4 &m)
 Apply a 4x4 homogeneous transformation matrix to all skeleton positions.
void convertToVoxel (Matrix4 *mat)
 convert all skeleton coordinates
void convertToWorld (Matrix4 *mat)
Persistence
virtual void addStateToTree (TreeNode *parent) const
 Attaches the object state as children of the given parent node.
 ML_SET_ADDSTATE_VERSION (3)
 Set current addStateToTree() version number:
virtual void readStateFromTree (TreeNode *parent)
 Reads the object state from the children of the given parent node.
Skeletons
SkeletoncreateSkeleton (const Vector3 &pos=Vector3(0), float minDistance=0.0f, float maxDistance=0.0f)
SkeletoncreateSkeleton (const ImageVector &pos, float minDistance=0.0f, float maxDistance=0.0f)
SkeletoncreateSkeleton (const Skeleton *skeletonTemplate)
void removeLeadingSkeletons (size_t count)
void removeTrailingSkeletons (size_t count)
void removeSkeleton (size_t index)
size_t numSkeletons (void) const
Skeletonskeleton (size_t index)
const Skeletonskeleton (size_t index) const
void skeletonsAscending (std::vector< Skeleton * > &skeletons)
 Return copy of skeletons' addresses in ascending order (graph hierarchy)
void skeletonsAscending (std::vector< const Skeleton * > &skeletons) const
 Return copy of skeletons' addresses in ascending order (graph hierarchy)
void skeletonsDescending (std::vector< Skeleton * > &skeletons)
 Return copy of skeletons' addresses in descending order (graph hierarchy)
void skeletonsDescending (std::vector< const Skeleton * > &skeletons) const
 Return copy of skeletons' addresses in descending order (graph hierarchy)
void orderSkeletonsAscending ()
void skeletonsAscending (std::vector< Skeleton > &skeletons) const
 Return copy of skeletons in ascending order (graph hierarchy from pred -> succ)
void skeletonsDescending (std::vector< Skeleton > &skeletons) const
 Return copy of skeletons in descending order (graph hierarchy from succ -> pred)
bool skeletonsAreAscending () const
 Returns if the skeletons are ordered ascending.
void clearSkeletons ()
 Encapsulate std::vector access.
SkeletonfrontSkeleton ()
SkeletonbackSkeleton ()
const SkeletonfrontSkeleton () const
const SkeletonbackSkeleton () const
Skeletonskeleton (Vector3 pos, int itemType)
 Get the skeleton with minimal distance to pos.
const Skeletonskeleton (Vector3 pos, int itemType) const
 Get the skeleton with minimal distance to pos.
size_t getVoxelNum () const
 Get number of edge voxels.
void smooth (unsigned int numSmoothingPasses, float positionSmoothingFactor, float radiusSmoothingFactor, float smoothingLimit=0.0f)
 Smooths the skeletons' positions and radii.

Friends

class EdgeAnalyser
class Graph
class LoadTreeData

Default Measurements

typedef double(VesselEdge::* EdgeGetFkt )(void) const
 object bound function pointer: position of function relative to (individual) object base
typedef void(VesselEdge::* EdgeSetFkt )(double)
 function to set float parameter value
 STATIC_GRAPH_PROPERTY (MLdouble, averageMinDistance, AverageMinDistance)
 STATIC_GRAPH_PROPERTY (MLdouble, length, Length)
 STATIC_GRAPH_PROPERTY (MLdouble, STLength, STLength)
 STATIC_GRAPH_PROPERTY (MLdouble, volume, Volume)
 STATIC_GRAPH_PROPERTY (MLdouble, STVolume, STVolume)
 STATIC_GRAPH_PROPERTY (Vector3, STBarycenter, STBarycenter)
 STATIC_GRAPH_PROPERTY (MLint, hierarchy, Hierarchy)
 STATIC_GRAPH_PROPERTY (MLint, label, Label)
 STATIC_GRAPH_PROPERTY (MLdouble, weight, Weight)
void setSTLabel (int nLabel)
 Set label of edge and the attached subtree defined by edge directions.
void setSTLabel (Graph *pGraph)
 Set labelof edge and the attached subtree defined by edge directions according to labels of pGraph.
bool markST (int a_label, float r, float g, float b, float a, Vector3 pos, int snap)
 Set label and rgb color of edge and the attached subtree defined by edge directions.
bool markEdge (int a_label, float r, float g, float b, float a, Vector3 pos, int snap)

Detailed Description

Class VesselEdge.

Definition at line 30 of file mlVesselEdge.h.


Member Typedef Documentation

typedef double(VesselEdge::* ml::VesselEdge::EdgeGetFkt)(void) const

object bound function pointer: position of function relative to (individual) object base

function to get float parameter value

Definition at line 133 of file mlVesselEdge.h.

typedef void(VesselEdge::* ml::VesselEdge::EdgeSetFkt)(double)

function to set float parameter value

Definition at line 134 of file mlVesselEdge.h.


Constructor & Destructor Documentation

ml::VesselEdge::VesselEdge ( const VesselEdge other)

Copy constructor (creates an unconnected object, only copies properties), deprecated.

ml::VesselEdge::~VesselEdge ( )

Destructor.


Member Function Documentation

virtual void ml::VesselEdge::addStateToTree ( TreeNode parent) const [virtual]

Attaches the object state as children of the given parent node.

Reimplemented from ml::BaseGraphItem.

Skeleton* ml::VesselEdge::backSkeleton ( ) [inline]

Definition at line 191 of file mlVesselEdge.h.

const Skeleton* ml::VesselEdge::backSkeleton ( ) const [inline]

Definition at line 193 of file mlVesselEdge.h.

void ml::VesselEdge::clearSkeletons ( )

Encapsulate std::vector access.

void ml::VesselEdge::convertToVoxel ( Matrix4 mat)

convert all skeleton coordinates

void ml::VesselEdge::convertToWorld ( Matrix4 mat)
void ml::VesselEdge::copyProperties ( const VesselEdge other)

Copy all properties (topology information is left unchanged)

Skeleton* ml::VesselEdge::createSkeleton ( const Vector3 pos = Vector3(0),
float  minDistance = 0.0f,
float  maxDistance = 0.0f 
)
Skeleton* ml::VesselEdge::createSkeleton ( const ImageVector pos,
float  minDistance = 0.0f,
float  maxDistance = 0.0f 
) [inline]

Definition at line 153 of file mlVesselEdge.h.

References createSkeleton().

Referenced by createSkeleton().

Skeleton* ml::VesselEdge::createSkeleton ( const Skeleton skeletonTemplate)
double ml::VesselEdge::distance ( Vector3  vp) const [inline]

Get the euclidean distance between the edge and vp.

Here: get the distance to the nearest skeleton voxel.

Definition at line 90 of file mlVesselEdge.h.

Vector3 ml::VesselEdge::extent ( ) const

Get the edge's extent.

Skeleton* ml::VesselEdge::frontSkeleton ( ) [inline]

Definition at line 190 of file mlVesselEdge.h.

const Skeleton* ml::VesselEdge::frontSkeleton ( ) const [inline]

Definition at line 192 of file mlVesselEdge.h.

SubImageBoxd ml::VesselEdge::getBoundingBox ( ) const

Bounding box of the edge.

std::pair<MLdouble, size_t> ml::VesselEdge::getDistanceAndNearestSkeletonIndex ( const Vector3 pos) const
size_t ml::VesselEdge::getVoxelNum ( ) const

Get number of edge voxels.

bool ml::VesselEdge::isCycle ( ) const [inline]

Definition at line 83 of file mlVesselEdge.h.

bool ml::VesselEdge::isPred ( const VesselNode node) const [inline]

Is the graphNode the preceding node of the edge?

Definition at line 70 of file mlVesselEdge.h.

bool ml::VesselEdge::isSucc ( const VesselNode node) const [inline]

Is the graphNode the succeeding node of the edge?

Definition at line 72 of file mlVesselEdge.h.

bool ml::VesselEdge::markEdge ( int  a_label,
float  r,
float  g,
float  b,
float  a,
Vector3  pos,
int  snap 
)
bool ml::VesselEdge::markST ( int  a_label,
float  r,
float  g,
float  b,
float  a,
Vector3  pos,
int  snap 
)

Set label and rgb color of edge and the attached subtree defined by edge directions.

Start at skeleton of this edge which is nearest to pos, while for snap = Graph::Node/Graph:Edge the nearest node skeleton or the nearest edge skeleton is used, respectively.

ml::VesselEdge::ML_SET_ADDSTATE_VERSION ( )

Set current addStateToTree() version number:

size_t ml::VesselEdge::numSkeletons ( void  ) const [inline]

Definition at line 160 of file mlVesselEdge.h.

bool ml::VesselEdge::operator!= ( const VesselEdge other) const [inline]

Definition at line 51 of file mlVesselEdge.h.

VesselEdge& ml::VesselEdge::operator= ( const VesselEdge other)

Assignment operator, deprecated. Use copyProperties() instead.

bool ml::VesselEdge::operator== ( const VesselEdge other) const
void ml::VesselEdge::orderSkeletonsAscending ( )
VesselNode* ml::VesselEdge::predNode ( ) [inline]

Get the predecessor node of this edge.

Definition at line 56 of file mlVesselEdge.h.

const VesselNode* ml::VesselEdge::predNode ( ) const [inline]

Definition at line 57 of file mlVesselEdge.h.

virtual void ml::VesselEdge::readStateFromTree ( TreeNode parent) [virtual]

Reads the object state from the children of the given parent node.

Reimplemented from ml::BaseGraphItem.

void ml::VesselEdge::removeLeadingSkeletons ( size_t  count)
void ml::VesselEdge::removeSkeleton ( size_t  index)
void ml::VesselEdge::removeTrailingSkeletons ( size_t  count)
void ml::VesselEdge::setCycle ( ) [inline]

Store dependent ids.

Separate circles in the graph or connections between trees.

Definition at line 81 of file mlVesselEdge.h.

void ml::VesselEdge::setPred ( VesselNode node)

Connect edge-head to node node.

void ml::VesselEdge::setSTLabel ( int  nLabel)

Set label of edge and the attached subtree defined by edge directions.

void ml::VesselEdge::setSTLabel ( Graph pGraph)

Set labelof edge and the attached subtree defined by edge directions according to labels of pGraph.

void ml::VesselEdge::setSucc ( VesselNode node)

Connect edge-tail to node node.

Skeleton* ml::VesselEdge::skeleton ( size_t  index) [inline]

Definition at line 161 of file mlVesselEdge.h.

const Skeleton* ml::VesselEdge::skeleton ( size_t  index) const [inline]

Definition at line 162 of file mlVesselEdge.h.

const Skeleton* ml::VesselEdge::skeleton ( Vector3  pos,
int  itemType 
) const

Get the skeleton with minimal distance to pos.

If itemType = Graph::node, the nearest end-skeleton (snap to node) is returned, if itemType = Graph::edge, it is the nearest edge skeleton.

Skeleton* ml::VesselEdge::skeleton ( Vector3  pos,
int  itemType 
) [inline]

Get the skeleton with minimal distance to pos.

If itemType = Graph::node, the nearest end-skeleton (snap to node) is returned, if itemType = Graph::edge, it is the nearest edge skeleton.

Definition at line 198 of file mlVesselEdge.h.

References skeleton().

Referenced by skeleton().

bool ml::VesselEdge::skeletonsAreAscending ( ) const

Returns if the skeletons are ordered ascending.

void ml::VesselEdge::skeletonsAscending ( std::vector< Skeleton * > &  skeletons)

Return copy of skeletons' addresses in ascending order (graph hierarchy)

void ml::VesselEdge::skeletonsAscending ( std::vector< const Skeleton * > &  skeletons) const

Return copy of skeletons' addresses in ascending order (graph hierarchy)

void ml::VesselEdge::skeletonsAscending ( std::vector< Skeleton > &  skeletons) const

Return copy of skeletons in ascending order (graph hierarchy from pred -> succ)

void ml::VesselEdge::skeletonsDescending ( std::vector< const Skeleton * > &  skeletons) const

Return copy of skeletons' addresses in descending order (graph hierarchy)

void ml::VesselEdge::skeletonsDescending ( std::vector< Skeleton > &  skeletons) const

Return copy of skeletons in descending order (graph hierarchy from succ -> pred)

void ml::VesselEdge::skeletonsDescending ( std::vector< Skeleton * > &  skeletons)

Return copy of skeletons' addresses in descending order (graph hierarchy)

void ml::VesselEdge::smooth ( unsigned int  numSmoothingPasses,
float  positionSmoothingFactor,
float  radiusSmoothingFactor,
float  smoothingLimit = 0.0f 
)

Smooths the skeletons' positions and radii.

No smoothing is done if a smoothing factor is 0 (or the number of smoothing passes = 0), smoothingLimit defines the maximal allowed displacement of skeletons (relative to minimal voxel extension), smoothingLimit = 0.0 means no limit.

ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
STLength  ,
STLength   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( Vector3  ,
STBarycenter  ,
STBarycenter   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
averageMinDistance  ,
AverageMinDistance   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
length  ,
Length   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
STVolume  ,
STVolume   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLint  ,
label  ,
Label   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLint  ,
hierarchy  ,
Hierarchy   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
volume  ,
Volume   
)
ml::VesselEdge::STATIC_GRAPH_PROPERTY ( MLdouble  ,
weight  ,
Weight   
)
VesselNode* ml::VesselEdge::succNode ( ) [inline]

Get the successor node of this edge.

Definition at line 60 of file mlVesselEdge.h.

const VesselNode* ml::VesselEdge::succNode ( ) const [inline]

Definition at line 61 of file mlVesselEdge.h.

void ml::VesselEdge::switchDirection ( )

Change direction of the edge by exchanging pred. and succ. node.

void ml::VesselEdge::transform ( const Matrix4 m)

Apply a 4x4 homogeneous transformation matrix to all skeleton positions.

void ml::VesselEdge::unsetCycle ( ) [inline]

Definition at line 82 of file mlVesselEdge.h.


Friends And Related Function Documentation

friend class EdgeAnalyser [friend]

Definition at line 32 of file mlVesselEdge.h.

friend class Graph [friend]

Reimplemented from ml::BaseGraphItem.

Definition at line 33 of file mlVesselEdge.h.

friend class LoadTreeData [friend]

Reimplemented from ml::BaseGraphItem.

Definition at line 34 of file mlVesselEdge.h.


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