[vtkusers] scalars type not correct

Dominik Szczerba dominik at itis.ethz.ch
Wed Jul 8 03:38:05 EDT 2009


I have a calculator taking char and returning float. It works all right.
But when I pass its output to the gausian smoother it outputs char data,
not float. The only way to get it right seems to call:

vtkSmartPointer<vtkStructuredPoints> image2 =
(vtkStructuredPoints*)calculator->GetOutput();
	image2->SetScalarTypeToFloat();
ismooth->SetInput(image2);

I don't like it because I can then not use SetInputConnection from the
calculator, which has undesired consequences elsewhere. Is it normal?

-- Dominik




More information about the vtkusers mailing list