vmtk / vmtk

the Vascular Modeling Toolkit
vmtk.org
Other
342 stars 164 forks source link

how to output Voronoi diagram when extracting centerline #328

Closed junqiangchen closed 3 years ago

junqiangchen commented 5 years ago

hello, i have builded the project of extracting centerline with vtkvmtkPolyDataCenterlines class,just like the http://www.vmtk.org/tutorials/Centerlines.html result,but i want output the Voronoi diagram,so i write code like this: vtkSmartPointer centerlinesFilter = vtkSmartPointer::New(); centerlinesFilter->SetInputData(m_cappedSurface); centerlinesFilter->SetSourceSeedIds(m_sourceIds); centerlinesFilter->SetTargetSeedIds(m_targetIds); centerlinesFilter->SetAppendEndPointsToCenterlines(m_appendEndPointsFlag); centerlinesFilter->SetGenerateVoronoiDiagram(m_appendEndPointsFlag); centerlinesFilter->SetRadiusArrayName("Radius"); centerlinesFilter->SetEdgeArrayName("Edge"); centerlinesFilter->SetEdgePCoordArrayName("PCoord"); centerlinesFilter->Update(); but this is not output the Voronoi diagram,can anyone tell me how to do it in C++? thank you

NeuZhangQiang commented 4 years ago

You can try:

centerlinesFilter->GetVoronoiDiagram();