[vtkusers] Help! Writing a filter to get vtkImageData from vtkUnstructuredGrid...
Ricardo Villegas
ricvilleg at gmail.com
Thu Jul 26 13:18:51 EDT 2012
Hello,
I'm writing a filter to obtain a 3D vtkImageData from a volume represented
as a vtkUnstructuredGrid.
The image data is being obtained by sampling the unstructured grid with
certain criteria and the help of a 3D widget.
I chose vtkImageAlgorithm as the base class for my filter, overriding the
FillInputPortInformation for setting the proper input data.
The application crashes when I connect the output of this filter to a
mapper or any other component for its visualization.
It seems something is wrong in the RequestInformation method because it
expects vtkImageData as an input. I overrode it; nothing changed.
Curiously, if I attach a vtkImageChangeInformation filter that acts an
intermediary between my filter and the next componente in the pipeline, it
works fine. However, I want my filter can work standalone without using a
vtkImageChangeInformation after it.
Could somebody give me a hint about what could wrong here? Which other
methods from vtkImageAlgorith should I change so that my filter works? Is
there a solution?
Thanks in advance,
Ricardo Villegas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120726/f498eb2d/attachment.htm>
More information about the vtkusers
mailing list