[vtkusers] (no subject)
    David Doria 
    daviddoria at gmail.com
       
    Mon Nov 28 17:30:52 EST 2011
    
    
  
On Mon, Nov 28, 2011 at 5:18 PM, Dan Barker <djb_ro at hotmail.co.uk> wrote:
> Dear All,
> I have a vtkImageData object which has several scalar components set as
>    voxels->SetNumberOfScalarComponents(4);
> and set as
>    voxels->SetScalarComponentFromDouble(i,j,k,comp,0.0);
> I wish to run vtkMarchingCubes algorithm on each scalar component
> individually. How do I access this? When I had just one component I could
> simply do
>     vtkMarchingCubes *surface = vtkMarchingCubes::New();
>     surface->SetInput(voxels);
>     // etc ...
> And marching cubes would run correctly and return a very nice looking
> surface. But now I cannot see a way to tell vtkMarchingCubes which component
> to use.
> Any help with this would be most appreciated.
> Regards,
> Dan
You may be looking for vtkImageExtractComponents:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Images/ExtractComponents
David
    
    
More information about the vtkusers
mailing list