[prev in list] [next in list] [prev in thread] [next in thread] 

List:       insight-users
Subject:    [Insight-users] Re: ImageSeriesReader and ImageSeriesWriter
From:       Todd Jensen <todd.jensen () ieee ! org>
Date:       2007-09-30 21:07:36
Message-ID: 213759.2756.qm () web82003 ! mail ! mud ! yahoo ! com
[Download RAW message or body]

> For example, if I have 30 dicom slices from 1 serie I read the serie, 
> then process it and the result... 30 dicom slices in 30 different series.
> 
> Using a series writer i can generate the unique output serie with all 
> the slices, but don't know how to modify each individual slice.

Sounds like you may need to change the default IO setting to not regenerating unique \
UIDs for the series and study.  Try:

    typedef itk::GDCMImageIO ImageIOType;
    ImageIOType::Pointer dicomIO = ImageIOType::New();
        
    // Don't allow UIDs to be regenerated at this point.
    //
    dicomIO->SetKeepOriginalUID( true );  // assumes you have changed meta data to \
the UID you wish to use.  
    typedef itk::ImageFileWriter< ImageType2D>  WriterType;
    WriterType::Pointer dcmWriter = WriterType::New();
    dcmWriter->SetImageIO( dicomIO );

Todd Jensen


[Attachment #3 (text/html)]

<html><head><style type="text/css"><!-- DIV {margin:0px;} \
--></style></head><body><div \
style="font-family:arial,helvetica,sans-serif;font-size:10pt"><div \
style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"><br><div \
style="font-family: times new roman,new york,times,serif; font-size: \
12pt;"><div><br>&gt; For example, if I have 30 dicom slices from 1 serie I read the \
serie, <br>&gt; then process it and the result... 30 dicom slices in 30 different \
series.<br>&gt; <br>&gt; Using a series writer i can generate the unique output serie \
with all <br>&gt; the slices, but don't know how to modify each individual \
slice.<br><br>Sounds like you may need to change the default IO setting to not \
regenerating unique UIDs for the series and study.&nbsp; \
Try:<br><br>&nbsp;&nbsp;&nbsp; typedef itk::GDCMImageIO \
ImageIOType;<br>&nbsp;&nbsp;&nbsp; ImageIOType::Pointer dicomIO = \
ImageIOType::New();<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;  \
// Don't allow UIDs to be regenerated at this point.<br>&nbsp;&nbsp;&nbsp; \
//<br>&nbsp;&nbsp;&nbsp; dicomIO-&gt;SetKeepOriginalUID( true );&nbsp; // assumes you \
have changed meta data to the UID you wish to use.<br>&nbsp;&nbsp;&nbsp; \
&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; typedef itk::ImageFileWriter&lt; \
ImageType2D&gt;&nbsp; WriterType;<br>&nbsp;&nbsp;&nbsp; WriterType::Pointer dcmWriter \
= WriterType::New();<br>&nbsp;&nbsp;&nbsp; dcmWriter-&gt;SetImageIO( dicomIO \
);<br><br>Todd Jensen<br><br></div></div><br></div></div></body></html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic