Hi,
As i do not know how to use gdcmviewer and I can share my dataset. Take it from here.
http://jumbofiles.com/user/albaeibar/32500/Dataset
I think the images are 8bits, but not sure about it.
Thanks,
Alba
-----Original Message-----
From: Mathieu Malaterre [mailto:mathieu.malaterre@...]
Sent: miércoles, 16 de marzo de 2011 12:12
To: Garin, Alba
Cc: gdcm-developers@...
Subject: Re: vtkImageViewer2
Alba,
this looks like there is some truncation in the pixel data. Are you
dealing with 16bits images ? It should be working nicely however. If
you cannot share your dataset, you can use gdcmviewer on your side
with your data. Let's assume you want to use gdcmviewer from an mhd
file, you would do:
$ gdcm2vtk input.mhd output.dcm
$ gdcmviewer output.dcm
gdcmviewer will use vtkImageColorViewer. If you can reproduce the
issue, I 'm interested in your dataset.
HTH
On Wed, Mar 16, 2011 at 9:16 AM, Garin, Alba <agarin@...> wrote:
>
> Good morning,
>
> I am sorry that i did not ask in a proper way. I am newbie in this stuff.
> I am doing a program to read a diffusion weighted nrrd file, read it, get the tensors with itk (itk::DiffusionTensor3DReconstructionImageFilter), and getting the main direction of each vector I create a RGB image. I use a itkToVtkImageFilter to convert it to vtkImageData. This image data is the input of a vtkImageColorViewer, and I visualize it with vtk and qt. I visualize 3 ortogonal views (axial, coronal and sagital) and I can move through the slices and almost all the slices are properly visualized.
>
> The problem is when in some slices are some parts that there are big regions of one predominant color; in this case, only the boundaries of this region are colored in that predominant color, and the whole region in another color. So, the visualized color is not the correct. It looks like the color get highly saturated.
> I do not configure anything in the viewer related to the colors, coz the vtkImageColorViewer with the vtkImageMapToWindowLevelColors2 handles everything for me. I mean I set the input of the viewer and render it, nothing else.
>
> In this link you can see the difference.
> http://alba-stuff.blogspot.com/2011/03/error.html
>
> In this image appears my visualization on the left side and what should be displayed in the right hand side obtained from the rgb itk image (be aware that the Left is on the Right and the anterior is flipped for the posterior). The problem is after converting the itk rgb image, because the reference image (the one for the right) is this itk image.
>
> Hope I explained it better...
>
> Thanks,
>
> Alba
>
> -----Original Message-----
> From: Mathieu Malaterre [mailto:mathieu.malaterre@...]
> Sent: martes, 15 de marzo de 2011 10:22
> To: Garin, Alba
> Cc: gdcm-developers
> Subject: Re: vtkImageViewer2
>
> Alba,
>
> Could you please read the following section from the FAQ:
>
> http://sourceforge.net/apps/mediawiki/gdcm/index.php?title=General_questions#How_should_I_ask_questions_on_the_mailing_lists.3F
>
> This would be really helpful for all of us, if you could describe
> your issue more acuratle. I do not have access to your data, I do not
> have access to your screen, I do not know what you are tying to do. So
> you are basically asking me to repair a black box, I cannot even
> see...
>
> regards
>
> On Fri, Mar 11, 2011 at 9:05 AM, Garin, Alba <agarin@...> wrote:
>> Hi,
>>
>> Maybe you don't get the post I put in the mailing list. Thanks,
>> Alba
>>
>> "Hi again,
>>
>>
>>
>> Thanks a lot for your advice to use vtkImageColorViewer. I am already using it, it seems to display correctly the rgb image, but i have few questions:
>>
>>
>>
>> - there are some regions, whereone color is predominant, that it appears in other color. I mean it looks like It is only painted in red the edges of the region instead of all the region. In the attached image it appears my visualization on the left side and what should be displayed in the right hand side (be aware that the Left is on the Right and the anterior is flipped for the posterior).
>>
>>
>>
>> - it uses vtkImageMapToWindowLevelColors2, so it takes only the first component of the image through a look up table.
>>
>> does the vtkImageColorViewer handle this any different way for rgb images? coz otherwise it is doing it uncorrectly.
>>
>>
>>
>> thanks,
>>
>> Alba"
>>
>> -----Original Message-----
>> From: Mathieu Malaterre [mailto:mathieu.malaterre@...]
>> Sent: jueves, 10 de marzo de 2011 16:36
>> To: Garin, Alba
>> Cc: gdcm-developers
>> Subject: Re: vtkImageViewer2
>>
>> Please CC the GDCM ML, thanks.
>>
>> What is the actual error you are seeing ? We have dashbaord that run
>> on a nightly basis building GDCM against VTK.
>>
>> Thanks
>>
>> On Thu, Mar 3, 2011 at 10:51 AM, Garin, Alba <agarin@...> wrote:
>>> Mathieu,
>>>
>>>
>>>
>>> Thanks for your quick answer. I tried to use the vtkImageColorViewer, but as
>>> I need to use the gdcm with vtk, not only with itk, I had lot of trouble
>>> when building the sources of gdcm, vtk and itk. Do you use gdcm with vtk and
>>> itk. Do you have any problem? Could you help me?
>>>
>>> Thanks in advance,
>>>
>>>
>>>
>>> Alba
>>>
>>>
>>>
>>> From: Mathieu Malaterre [mailto:mathieu.malaterre@...]
>>> Sent: lunes, 28 de febrero de 2011 19:15
>>> To: Garin, Alba
>>> Cc: gdcm-developers
>>> Subject: Re: vtkImageViewer2
>>>
>>>
>>>
>>> Alba,
>>>
>>>
>>>
>>> This class has been integrated to GDCM:
>>>
>>>
>>>
>>> http://gdcm.sourceforge.net/html/classvtkImageColorViewer.html
>>>
>>> Seems to be working fine so far.
>>>
>>>
>>>
>>> HTH
>>>
>>>
>>>
>>> On Mon, Feb 28, 2011 at 5:24 PM, Garin, Alba <agarin@...> wrote:
>>>
>>> Good afternoon,
>>>
>>>
>>>
>>> Sorry for disturbing you with the email but i saw you had a similar problem
>>> years ago
>>> http://www.vtk.org/pipermail/vtk-developers/2007-August/004687.html
>>>
>>> . I am trying to visualize a rgb vimage stored in a vtkImageData with the
>>> vtkImageViewer2 class but I cannot get a good image. The thing is first I
>>> obtained a grayscale image and now even I obtained in colours it is
>>> incorrect cause it appears as it only uses the first component of the pixel.
>>>
>>>
>>>
>>> Could you help me? Did u managed to visualize the 3 components of the rgb
>>> correctly?
>>>
>>>
>>
>>
>>
>> --
>> Mathieu
>>
>
>
>
> --
> Mathieu
>
--
Mathieu
|