MeVisLab Toolbox Reference
mlGraphUtilities.h
Go to the documentation of this file.
1 /*************************************************************************************
2 **
3 ** Copyright 2012, MeVis Medical Solutions AG
4 **
5 ** The user may use this file in accordance with the license agreement provided with
6 ** the Software or, alternatively, in accordance with the terms contained in a
7 ** written agreement between the user and MeVis Medical Solutions AG.
8 **
9 ** For further information use the contact form at https://www.mevislab.de/contact
10 **
11 **************************************************************************************/
12 
13 #ifndef ML_GRAPH_UTILITIES_H
14 #define ML_GRAPH_UTILITIES_H
15 
16 
20 
21 
22 #include "MLGraphUtilitiesSystem.h"
23 
24 // Include vessel graph class.
25 #include "mlGraphComponents.h"
26 
28 
31 MLGRAPHUTILITIES_EXPORT const VESSELGRAPH_NAMESPACE::VesselEdge* getConnectingEdge(const VESSELGRAPH_NAMESPACE::VesselNode& nodeA, const VESSELGRAPH_NAMESPACE::VesselNode& nodeB);
32 
35 MLGRAPHUTILITIES_EXPORT VESSELGRAPH_NAMESPACE::VesselEdge* getConnectingEdge(VESSELGRAPH_NAMESPACE::VesselNode& nodeA, VESSELGRAPH_NAMESPACE::VesselNode& nodeB);
36 
39 MLGRAPHUTILITIES_EXPORT void removeValency2Nodes(VESSELGRAPH_NAMESPACE::Graph& graph);
40 
42 MLGRAPHUTILITIES_EXPORT void resampleEdges(VESSELGRAPH_NAMESPACE::Graph& graph, double resolution);
43 
44 #ifndef MLGRAPHUTILITIES_USE_MPIF
45 
48 MLGRAPHUTILITIES_EXPORT std::vector<VESSELGRAPH_NAMESPACE::VesselNode*> findShortestPath(VESSELGRAPH_NAMESPACE::Graph* graph, VESSELGRAPH_NAMESPACE::VesselNode* startNode, VESSELGRAPH_NAMESPACE::VesselNode* endNode);
49 
53 MLGRAPHUTILITIES_EXPORT std::vector<VESSELGRAPH_NAMESPACE::Skeleton*> findShortestPath(VESSELGRAPH_NAMESPACE::Graph* graph, const Vector3 &startPos, const Vector3 &endPos);
54 
55 #endif
56 
60 MLGRAPHUTILITIES_EXPORT void createLineSkeletonsOnEdge(VESSELGRAPH_NAMESPACE::VesselEdge& edge);
61 
62 #ifndef VESSELGRAPH_USE_MPIF
63 
65 MLGRAPHUTILITIES_EXPORT void createVesselVoxels(VESSELGRAPH_NAMESPACE::VesselEdge& edge);
66 
67 MLGRAPHUTILITIES_EXPORT VESSELGRAPH_NAMESPACE::VesselNode* getNearestNode(Graph* graph, const Vector3& position);
68 
71 MLGRAPHUTILITIES_EXPORT VESSELGRAPH_NAMESPACE::Skeleton* getSmartSnapSkeleton(VESSELGRAPH_NAMESPACE::VesselEdge* selectedEdge,
72  VESSELGRAPH_NAMESPACE::Skeleton* selectedSkeleton,
73  size_t maxDistanceInSkeletons);
74 
75 #endif
76 
78 
79 #endif
#define MLGRAPHUTILITIES_EXPORT
Definiert systemspezifische Macros, die f"ur diese DLL gelten sollen.
#define MLGRAPHUTILITIES_START_NAMESPACE
#define MLGRAPHUTILITIES_END_NAMESPACE
Defines the basic Graph class which holds sets of nodes, edges and roots to model tubular structures ...
Definition: mlGraph.h:64
MLGRAPHUTILITIES_EXPORT VESSELGRAPH_NAMESPACE::VesselNode * getNearestNode(Graph *graph, const Vector3 &position)
MLGRAPHUTILITIES_EXPORT void removeValency2Nodes(VESSELGRAPH_NAMESPACE::Graph &graph)
Removes all nodes which are connected to exactly two different edges by merging those two edges.
MLGRAPHUTILITIES_EXPORT void createLineSkeletonsOnEdge(VESSELGRAPH_NAMESPACE::VesselEdge &edge)
Creates skeletons between the two nodes of a vessel edge, using Bresenham3D in voxel resolution.
MLGRAPHUTILITIES_EXPORT void resampleEdges(VESSELGRAPH_NAMESPACE::Graph &graph, double resolution)
Create skeletons with a given resolution for all edges.
MLGRAPHUTILITIES_EXPORT std::vector< VESSELGRAPH_NAMESPACE::VesselNode * > findShortestPath(VESSELGRAPH_NAMESPACE::Graph *graph, VESSELGRAPH_NAMESPACE::VesselNode *startNode, VESSELGRAPH_NAMESPACE::VesselNode *endNode)
Finds the shortest path in graph between startNode and endNode; since the graph is internally handled...
MLGRAPHUTILITIES_START_NAMESPACE MLGRAPHUTILITIES_EXPORT const VESSELGRAPH_NAMESPACE::VesselEdge * getConnectingEdge(const VESSELGRAPH_NAMESPACE::VesselNode &nodeA, const VESSELGRAPH_NAMESPACE::VesselNode &nodeB)
Collection of utility functions for VesselGraphs.
MLGRAPHUTILITIES_EXPORT void createVesselVoxels(VESSELGRAPH_NAMESPACE::VesselEdge &edge)
Creates vessel voxels for all skeletons of the given edge if the edge is a cone frustum or a cylinder...
MLGRAPHUTILITIES_EXPORT VESSELGRAPH_NAMESPACE::Skeleton * getSmartSnapSkeleton(VESSELGRAPH_NAMESPACE::VesselEdge *selectedEdge, VESSELGRAPH_NAMESPACE::Skeleton *selectedSkeleton, size_t maxDistanceInSkeletons)
Searches upwards in the tree for a skeleton within the given distance that either has a different lab...
Tvec3< MLdouble > Vector3
A vector with 3 components of type double.
Definition: mlVector3.h:300