[vtkusers] Re: help on vtkDicomImage Reader and python
Mathieu Malaterre
mathieu.malaterre at gmail.com
Wed Sep 12 11:13:13 EDT 2007
Hi Raffaele,
For this kind of question, may I suggest you get a book about python.
When you are not sure what an object in python support simply type:
>> dir(reader)
>> dir(reader.GetOutput())
You'll see that offset,slope... are DICOM property thus belong to the
reader. While reader.GetOutput() is of type vtkImageData and has no
such properties.
Please next time send your questions to the vtkusers ml.
HTH
-Mathieu
On 9/12/07, raffaele ponzini <raffaele.ponzini at gmail.com> wrote:
> Dear Mr. Malaterre,
>
> the test.py reads correctly the dicom file but after I'm not able using this
> syntax:
> reader.GetOutput().Get......()
> to use all the member function to get informations opn pixel size, offset,
> slope and all the other infromatiuon that can be retrivied using public
> member function.
> I'm trying to use this function in order to red MR phase contrast images and
> I need to get the single pixel value in order to build a python array of
> float values that represent the velocity value at each pixel.
>
> Can You please explain me where I'm doing wrong?
>
> thank you,
>
> r.
--
Mathieu
More information about the vtkusers
mailing list