[Insight-users] Reading DICOM-RT with vtkGDCMPolyDataReader as supposed by Charles Wang
Lodron, Gerald
Gerald.Lodron at joanneum.at
Tue Oct 6 02:45:42 EDT 2009
Hi,
I tested the gdcmscene code but i only get a white window.
Any ideas?
-----Ursprüngliche Nachricht-----
Von: Charles Wang [mailto:cywang926 at gmail.com]
Gesendet: Montag, 05. Oktober 2009 18:05
An: Lodron, Gerald
Cc: Insight users (insight-users at itk.org)
Betreff: Re: [Insight-users] Reading DICOM-RT with vtkGDCMPolyDataReader as supposed by Charles Wang
Hi Gerald,
You can try the gdcmscene.cxx in
gdcm-2.0.12\Utilities\VTK\Examples\CXX to see if it can read and
display all the OARs and target volumes (PTV, CTV) in your DICOM-RT
structure set file correctly. After that, using scan-line conversion
by rasterizing these slice-based contours into binary/label image
volume would be another big issue to solved.
Charles Wang
2009/10/5 Lodron, Gerald <Gerald.Lodron at joanneum.at>:
> First of all: Thanks for the fast reply.
>
> I changed those settings and recompiled, but the changes did not effect the
> result. I debugged it and I never come to the continue statement listed in
> the change log of your link.
>
> During the debugging I found following out:
>
> The vtkGDCMPolyDataReader correctly reads more than one point from the file
> (line 367-369) but the update must fail. Maybe it is in the ptId variable on
> line 370? This variable is 0 every loop I run. Or is the error in the npts
> variable of the for loop on line 364 because this variable is 1 all time,
> the only real loop I go throug is those on line 272. Should i send you my
> dicom file?
>
> Best regards,
>
>
>
>
> ________________________________
> Von: insight-users-bounces at itk.org [mailto:insight-users-bounces at itk.org] Im
> Auftrag von Lodron, Gerald
> Gesendet: Montag, 05. Oktober 2009 14:45
> An: Insight users (insight-users at itk.org)
> Betreff: [Insight-users] Reading DICOM-RT with vtkGDCMPolyDataReader as
> supposed by Charles Wang
>
> Hello ITK users group,
>
> I am trying to read (and display) DICOM RT Structure Sets. On
> http://www.insight-journal.org/browse/publication/316 I found a nice hint in
> the review section of Charles Wang. I tried to implement it with the
> following code:
>
>
> vtkGDCMPolyDataReader * PolyReader = vtkGDCMPolyDataReader::New();
>
> PolyReader->SetFileName( argv[1] );
>
> PolyReader->Update();
>
> //PolyReader->Print(std::cerr);
>
> vtkPolyData * polyData = PolyReader->GetOutput();
>
>
>
> But when I look at the object polyData I only see strange results:
>
>
>
> int a = polyData->GetNumberOfCells();//1
>
> int b = polyData->GetNumberOfLines();//0
>
> int c = polyData->GetNumberOfPieces();//1
>
> int d = polyData->GetNumberOfPoints();//1
>
> int e = polyData->GetNumberOfPolys();//1
>
> int f = polyData->GetNumberOfStrips();//0
>
> int g = polyData->GetNumberOfVerts();//0
>
>
>
> For sure, also the displaying of those object fails. So I think that the
> reader stops after the first point reading, does anybody (maybe Charles
> Wang) know how to read those RT Structure Sets without modifying the
> PolyReader object and without writing a new parser? Would be very great,
> special thanks to all helpers!
>
> Best regards,
>
> Gerald Lodron
> _____________________________________
> 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 ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>
>
More information about the Insight-users
mailing list