MeVisLab Toolbox Reference
|
VesselNode is derived from GraphNode, hence it can be stored as node item in a class Graph object. More...
#include <mlVesselNode.h>
Public Member Functions | |
~VesselNode () override | |
Destructor. | |
void | copyProperties (const VesselNode *other) |
Copy all properties (topology information is left unchanged) | |
bool | operator== (const VesselNode &other) const |
bool | operator!= (const VesselNode &other) const |
Graph geometry | |
STATIC_GRAPH_PROPERTY (Vector3, pos, Pos) | |
void | setVectorPos (const ImageVector &position) |
Position in world. | |
ImageVector | getVectorPos () const |
Position in world. | |
double | distance (const Vector3 &position) const |
Get the euclidean distance between _worldPos and pos. | |
void | transform (const Matrix4 &m) |
Apply a 4x4 homogeneous transformation matrix to the node position. | |
void | convertToVoxel (Matrix4 *mat) |
Convert nodes' coordinates. | |
void | convertToWorld (Matrix4 *mat) |
Convert nodes' coordinates. | |
Persistence | |
Attaches the object state as children of the given parent node. | |
void | addStateToTree (TreeNode *parent) const override |
ML_SET_ADDSTATE_VERSION (2) | |
Set current addStateToTree() version number: | |
void | readStateFromTree (TreeNode *parent) override |
Reads the object state from the children of the given parent node. | |
Public Member Functions inherited from BaseGraphItem | |
MLint | getRootId () const |
Get root id. | |
void | setRootId (MLint rootId) |
Sets the root id. Usually called by calling setRootIdToAllChildren on the graph itself. | |
Graph * | getGraph (void) |
const Graph * | getGraph (void) const |
MLint | getId (void) const |
Get unique id of the object. | |
Public Member Functions inherited from PropertyContainer | |
PropertyContainer (const ManagerPointer &manager) | |
PropertyContainer (const PropertyContainer &other) | |
~PropertyContainer () override | |
bool | operator== (const PropertyContainer &other) const |
Check for equality (managers and values). | |
bool | operator!= (const PropertyContainer &other) const |
Check for inequality (managers and values). | |
void | copyProperties (const PropertyContainer &other) |
Copy all properties from the given container to this object. | |
const PropertyManager * | getPropertyManager () const |
Get read-only access to the associated property manager. | |
PropertyManager * | getPropertyManager () |
Get access to the associated property manager. | |
PropertyMap | getPropertyMap () const |
Get a map of the contained properties, can be useful for comparison. | |
size_t | numberOfProperties () const |
Return the number of properties currently available. | |
const PropertyValue & | property (size_t index) const |
Get the property with index index as PropertyValue. | |
template<typename T > | |
T & | property (size_t index) |
Get the property with index index with type T. Throws boost::bad_get exception if the currently stored property has a different type. | |
template<typename T > | |
const T & | property (size_t index) const |
Get the property with index index with type T, const version. Throws boost::bad_get exception if the currently stored property has a different type. | |
const PropertyValue & | property (const std::string &name) const |
Get the property with name name . | |
template<typename T > | |
T & | property (const std::string &name) |
template<typename T > | |
const T & | property (const std::string &name) const |
virtual void | reset () |
Set all properties to default values. | |
ML_ABSTRACT_CLASS_HEADER (PropertyContainer) | |
void | addStateToTree (TreeNode *parent) const override |
ML_SET_ADDSTATE_VERSION (1) | |
Set current addStateToTree() version number: | |
void | readStateFromTree (TreeNode *parent) override |
Reads the object state from the children of the given parent node. | |
Friends | |
class | Graph |
class | VesselEdge |
class | LoadTreeData |
Properties | |
typedef MLdouble(VesselNode::* | NodeGetFkt) () const |
object bound function pointer: position of function relative to (individual) object base | |
typedef void(VesselNode::* | NodeSetFkt) (const MLdouble &) |
function to set double parameter value | |
STATIC_GRAPH_PROPERTY (MLint, label, Label) | |
STATIC_GRAPH_PROPERTY (MLdouble, minDistance, MinDistance) | |
STATIC_GRAPH_PROPERTY (MLdouble, maxPathLength, MaxPathLength) | |
STATIC_GRAPH_PROPERTY (MLdouble, weight, Weight) | |
Weight of the node. | |
Graph topology | |
Erase/add edge pointer in the local edge array | |
bool | isRoot () const |
bool | isEnd () const |
bool | isBranch () const |
int | nodeType () const |
size_t | getEdgeNum () const |
Get number of edges dependent on the node. | |
VesselEdge * | getDepEdge (size_t i) |
Get the pointer of edge with index i. | |
const VesselEdge * | getDepEdge (size_t i) const |
Get the pointer of edge with index i. | |
std::vector< VesselEdge * > * | edges () |
Get pointer to edge array. | |
VesselNode * | getDepNode (size_t i) |
Get dependent node via edge with index i. | |
const VesselNode * | getDepNode (size_t i) const |
Get dependent node via edge with index i. | |
bool | isPred (size_t i) const |
Is the dependent edge with index i preceding? | |
bool | isSucc (size_t i) const |
Is the dependent edge with index i succeeding? | |
bool | isCycle (size_t i) const |
Is the dependent edge with index i a cycle? | |
bool | closeCycle () |
TODO: Unclear what this does. | |
VesselNode * | getPredNode () |
Get the one and only predecessor node (return NULL for rootnode) | |
const VesselNode * | getPredNode () const |
Get the one and only predecessor node (return NULL for rootnode) | |
VesselEdge * | getPredEdge () |
Get the one and only predecessor edge (return NULL for rootnode) | |
const VesselEdge * | getPredEdge () const |
Get the one and only predecessor edge (return NULL for rootnode) | |
Additional Inherited Members | |
Public Types inherited from PropertyContainer | |
typedef PropertyManager::Pointer | ManagerPointer |
typedef PropertyManager::ConstPointer | ConstManagerPointer |
typedef PropertyManager::PropertyMap | PropertyMap |
Protected Member Functions inherited from BaseGraphItem | |
BaseGraphItem (Graph &graph, MLint id, const ManagerPointer &manager) | |
Constructor. | |
BaseGraphItem (const BaseGraphItem &item) | |
Copy constructor (creates an unconnected object, only copies properties), deprecated. | |
BaseGraphItem & | operator= (const BaseGraphItem &item) |
Assignment operator, deprecated. Use copyProperties() instead. | |
void | copyProperties (const BaseGraphItem *other) |
Copy all properties (topology information is left unchanged) | |
bool | operator== (const BaseGraphItem &other) const |
Compare properties (ignores topology information) | |
bool | operator!= (const BaseGraphItem &other) const |
void | addStateToTree (TreeNode *parent) const override |
ML_SET_ADDSTATE_VERSION (2) | |
Set current addStateToTree() version number: | |
void | readStateFromTree (TreeNode *parent) override |
Reads the object state from the children of the given parent node. | |
Protected Attributes inherited from BaseGraphItem | |
Graph * | _graph |
Reference to the owner Graph object. | |
Protected Attributes inherited from PropertyContainer | |
std::vector< PropertyValue > | _values |
ManagerPointer | _manager |
VesselNode is derived from GraphNode, hence it can be stored as node item in a class Graph object.
class VesselNode
Definition at line 28 of file mlVesselNode.h.
object bound function pointer: position of function relative to (individual) object base
function to get double parameter value
Definition at line 118 of file mlVesselNode.h.
function to set double parameter value
Definition at line 119 of file mlVesselNode.h.
|
inlineoverride |
|
override |
bool VesselNode::closeCycle | ( | ) |
TODO: Unclear what this does.
void VesselNode::convertToVoxel | ( | Matrix4 * | mat | ) |
Convert nodes' coordinates.
void VesselNode::convertToWorld | ( | Matrix4 * | mat | ) |
Convert nodes' coordinates.
void VesselNode::copyProperties | ( | const VesselNode * | other | ) |
Copy all properties (topology information is left unchanged)
Get the euclidean distance between _worldPos
and pos.
Used for node selection in a scene.
Definition at line 95 of file mlVesselNode.h.
|
inline |
Get pointer to edge array.
Definition at line 59 of file mlVesselNode.h.
|
inline |
Get the pointer of edge with index i.
Definition at line 55 of file mlVesselNode.h.
References mlrange_cast().
|
inline |
Get the pointer of edge with index i.
Definition at line 57 of file mlVesselNode.h.
References mlrange_cast().
VesselNode * VesselNode::getDepNode | ( | size_t | i | ) |
Get dependent node via edge with index i.
const VesselNode * VesselNode::getDepNode | ( | size_t | i | ) | const |
Get dependent node via edge with index i.
|
inline |
Get number of edges dependent on the node.
Definition at line 53 of file mlVesselNode.h.
VesselEdge * VesselNode::getPredEdge | ( | ) |
Get the one and only predecessor edge (return NULL for rootnode)
const VesselEdge * VesselNode::getPredEdge | ( | ) | const |
Get the one and only predecessor edge (return NULL for rootnode)
VesselNode * VesselNode::getPredNode | ( | ) |
Get the one and only predecessor node (return NULL for rootnode)
const VesselNode * VesselNode::getPredNode | ( | ) | const |
Get the one and only predecessor node (return NULL for rootnode)
|
inline |
Position in world.
Definition at line 91 of file mlVesselNode.h.
bool VesselNode::isBranch | ( | ) | const |
Is the dependent edge with index i a cycle?
Definition at line 70 of file mlVesselNode.h.
References mlrange_cast().
bool VesselNode::isEnd | ( | ) | const |
Is the dependent edge with index i preceding?
Definition at line 66 of file mlVesselNode.h.
References mlrange_cast().
bool VesselNode::isRoot | ( | ) | const |
Is the dependent edge with index i succeeding?
Definition at line 68 of file mlVesselNode.h.
References mlrange_cast().
VesselNode::ML_SET_ADDSTATE_VERSION | ( | 2 | ) |
Set current addStateToTree() version number:
int VesselNode::nodeType | ( | ) | const |
|
inline |
Definition at line 42 of file mlVesselNode.h.
References mlrange_cast().
bool VesselNode::operator== | ( | const VesselNode & | other | ) | const |
|
override |
Reads the object state from the children of the given parent node.
Position in world.
Definition at line 89 of file mlVesselNode.h.
VesselNode::STATIC_GRAPH_PROPERTY | ( | MLdouble | , |
maxPathLength | , | ||
MaxPathLength | ) |
VesselNode::STATIC_GRAPH_PROPERTY | ( | MLdouble | , |
minDistance | , | ||
MinDistance | ) |
Weight of the node.
May be used to direct the graph by attaching edges to the root-node in a weighted order. Default is 1.0.
VesselNode::STATIC_GRAPH_PROPERTY | ( | Vector3 | , |
pos | , | ||
Pos | ) |
Apply a 4x4 homogeneous transformation matrix to the node position.
Definition at line 30 of file mlVesselNode.h.
Definition at line 32 of file mlVesselNode.h.
|
friend |
Definition at line 31 of file mlVesselNode.h.