AW: AW: [Insight-users] Show 3d image data by vtk, cont'
Luis Ibanez
luis . ibanez at kitware . com
Tue, 30 Sep 2003 18:10:10 -0400
Hi Jiang,
A better starting point for visualizing you dataset with VTK
could be to use the vtkImageViewer2 class:
http://www . vtk . org/doc/nightly/html/classvtkImageViewer2 . html
Regards,
Luis
-------------------
jiang wrote:
> Hello Luis,
> Thank you for your suggestions. Now I try to answer part of your questions.
>
> -----Ursprungliche Nachricht-----
> Von: Luis Ibanez [mailto:luis . ibanez at kitware . com]
> Gesendet: Dienstag, 30. September 2003 17:19
> An: jiang
> Cc: ITK
> Betreff: Re: AW: [Insight-users] Show 3d image data by vtk, cont'
>
>
>
> Hi Jiang,
>
> A) Could you please describe the VTK pipeline
> that you are using for visualizing this data ?
> ##ITK to VTK and VTK pipeline
> /*Create a pipeline ITK-->VTK*/
> vtkImageImport* importer = vtkImageImport::New();
> ... ...//I have sent this part before. It is same as the example
> itkImageToVTKImageFilter
>
> structPts= vtkStructuredPoints::New();
> vtkImageToStructuredPoints* its=vtkImageToStructuredPoints::New();
> its->SetInput(importer->GetOutput());
> structPts=its->GetOutput();
> vtkDataSetMapper* mapper=vtkDataSetMapper::New();
> mapper->SetInput(structPts);
>
> vtkActor* actor=vtkActor::New();
> actor->SetMapper(mapper);//coneMapper
>
> renderer->AddActor(actor);
> renderer->SetBackground(1,1,1);
> renWin->Render();
> ##
> B) Did you verified that the data was read
> correctly into memory ?
>
> (for example, you could save the volume
> in another file format just after reading
> it from the DICOM series, and then use
> the ImageViewer application in
> InsightApplications)
> ##I consider the reading procedure should be correct. Because I copy the
> first image of the series of DICOM files into QImage, and show it in the
> screen. It is correct image. So I didn't try to write and test again.
> ##
>
> C) Did you verified that the data was converted
> correctly from ITK to VTK ?
>
> (again, you could use a vtk writer in order
> to save the vktImageData in a file and open
> it with some standard viewer). You could
> use VolView for this purpose, now that there
> is a free version available for download.
> ##I'm not sure if it is correct. I will try it as you said.
>
> D) Please take a look at the application from
> the ISIS center that was described in the
> previous email. You may find some useful
> hints on how to use the toolkits together.
> ##I will try it. Thank you.
>
>
> Regards,
>
>
> Luis
>
>
>
>
> ----------------
> jiang wrote:
>
>>Hi Luis,
>>As you said, I use the library VtkQt that developed by M. Koenig to
>
> combine
>
>>VTK and QT. It works fine. However my problem is not solved. When the data
>>is transfered from ITK to VTK, and rendered by VTK, there is only one blue
>>block with some black points, not the images I readed. And there are only
>>two images in the series, but the block is very thick, much more than the
>>depth of two images.
>>Does anybody do the similar work as me? Please tell me how can I solve
>
> this
>
>>problem?
>>
>>Thanks a lot!
>>
>>Chunyan Jiang
>>
>
>
>
>