[vtkusers] small question ... how to pass data from vtkPNGreader to a vtkImageData Object ?

Jérôme jerome.velut at gmail.com
Tue May 19 16:51:39 EDT 2009


Hi,

David,
I think that ParaView opens a 2D file in a 2D render by default. Just check
the "visibility" icon (eye) in the pipeline when your 3D render window is
active. It should work. if not, ask the ParaView mailing list ;)

Abdalrahman,
I really don't understand your question : vtkPNGReader is an vtkAlgorithm
with no input and a vtkImageData output. You can then plug your reader
output to any filter that takes vtkImageData as input ! What do you mean
exactly by "how to pass data" ? May your formulation be more precise ?

Regards,
Jérôme

2009/5/19 David Doria <daviddoria at gmail.com>

> On Tue, May 19, 2009 at 3:09 PM, abdalrahman eweiwi <
> abdalrahman.eweiwi at googlemail.com> wrote:
>
>>
>> hello guys
>>
>> small question ... how to pass data from vtkPNGreader to a vtkImageData
>> Object ?
>> --
>> Regards
>>
>> Abdalrahman Eweiwi
>> Msc in Media Informatics
>> RWTH-AACHEN
>> B-it
>
>
> You mean something like this?
>
>     vtkPNGReader* reader = vtkPNGReader::New();
>     reader->SetFileName("Test.png");
>     reader->Update();
>
>     vtkImageData* imagedata = reader->GetOutput();
>
>     vtkXMLImageDataWriter* writer = vtkXMLImageDataWriter::New();
>     writer->SetInput(imagedata);
>     writer->SetFileName("Test.vti");
>     writer->Update();
>
> What I don't understand is how to actually load this resulting file in
> Paraview. If I open it like I normally do vtp files, it opens in a separate
> window rather than in the normal "model space" where everything else opens.
> Anyone know how to open it as if it was a slice of a volume data set?
>
> Thanks,
>
> David
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090519/bdf22f6d/attachment.htm>


More information about the vtkusers mailing list