0
$\begingroup$

How can I create and save a 3D volume model from a volume image vtkImageData?

Some people recommend vtkImageDataGeometryFilter, so I tried the following:

vtkSmartPointer<vtkImageDataGeometryFilter> imageDataGeometryFilter =
    vtkSmartPointer<vtkImageDataGeometryFilter>::New();
imageDataGeometryFilter->SetInputData(imageData);
imageDataGeometryFilter->SetThresholdCells(true);
imageDataGeometryFilter->ThresholdValueOn();
imageDataGeometryFilter->SetThresholdValue(90);
imageDataGeometryFilter->Update();

Below is the visualization of imageDataGeometryFilter->GetOutput():

Generated vtkPolyData

First of all the threshold doesn't work. Moreover, it doesn't output a volume model, but just some unconnected vertices.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.