[ITK-users] White Background on rotated image
Matias Montroull
matimontg at gmail.com
Fri Nov 14 08:28:21 EST 2014
I'm having hard times following the code in the example. RIght now I have
been able to rotate a dcm file one at a time, now I would like to input a
directory and output another directory with the rotated images, I would
need some guidance for this task.
Can I just set the input as directory instead of a file for example?
On Thu, Nov 13, 2014 at 3:26 PM, Matias Montroull <matimontg at gmail.com>
wrote:
> Thanks Matt, I'll give it a try
>
> On Thu, Nov 13, 2014 at 2:37 PM, Matt McCormick <
> matt.mccormick at kitware.com> wrote:
>
>> Hi Matias,
>>
>> This example may have a hint on how to write a series [1].
>>
>> HTH,
>> Matt
>>
>> [1]
>> http://itk.org/Doxygen/html/IO_2ImageReadDicomSeriesWrite_8cxx-example.html
>>
>> On Thu, Nov 13, 2014 at 12:18 PM, Matias Montroull <matimontg at gmail.com>
>> wrote:
>> > Now I have another question. This example is just for one file, is
>> there a
>> > way to do it for a directory containing a set of DICOM files?
>> >
>> > On Thu, Nov 13, 2014 at 2:16 PM, Matias Montroull <matimontg at gmail.com>
>> > wrote:
>> >>
>> >> never mind, it was my bad. The InputPixelType was unsigned char and
>> should
>> >> have been unsigned short
>> >>
>> >> On Thu, Nov 13, 2014 at 2:14 PM, Matias Montroull <matimontg at gmail.com
>> >
>> >> wrote:
>> >>>
>> >>> Bradley, as soon as I enter this line of code:
>> >>>
>> >>> typedef itk::GDCMImageIO ImageIOType;
>> >>> ImageIOType::Pointer gdcmImageIO = ImageIOType::New();
>> >>> writer->SetImageIO(gdcmImageIO);
>> >>>
>> >>> I get a bad image as result.. any ideas what could it be?
>> >>>
>> >>> On Thu, Nov 13, 2014 at 11:36 AM, Bradley Lowekamp
>> >>> <blowekamp at mail.nih.gov> wrote:
>> >>>>
>> >>>> Hello again,
>> >>>>
>> >>>> This is a non-trivial task where caution in needed to determine which
>> >>>> tags should be copied. But here is a basic example here:
>> >>>> http://itk.org/Wiki/ITK/Examples/DICOM/ResampleDICOM
>> >>>>
>> >>>> Brad
>> >>>>
>> >>>> On Nov 13, 2014, at 9:30 AM, Matias Montroull <matimontg at gmail.com>
>> >>>> wrote:
>> >>>>
>> >>>> I have one more question, it seems the writer method removes lot of
>> tags
>> >>>> from the image, is there an option to keep the original tags such as
>> patient
>> >>>> name, model, manufacture etc?
>> >>>>
>> >>>> On Thu, Nov 13, 2014 at 11:27 AM, Matias Montroull <
>> matimontg at gmail.com>
>> >>>> wrote:
>> >>>>>
>> >>>>> Bradley, I must say you're the man! that did the trick, thanks a
>> lot!
>> >>>>>
>> >>>>> On Thu, Nov 13, 2014 at 10:59 AM, Bradley Lowekamp
>> >>>>> <blowekamp at mail.nih.gov> wrote:
>> >>>>>>
>> >>>>>> Hello,
>> >>>>>>
>> >>>>>> Check out the ImageToImageFilter::SetDefaultPixelValue method [1].
>> >>>>>>
>> >>>>>> Brad
>> >>>>>>
>> >>>>>> [1]
>> >>>>>>
>> http://www.itk.org/Doxygen/html/classitk_1_1ResampleImageFilter.html#a227397f3786a0ec4d3107cb73033b4be
>> >>>>>>
>> >>>>>> On Nov 13, 2014, at 8:56 AM, Matias Montroull <matimontg at gmail.com
>> >
>> >>>>>> wrote:
>> >>>>>>
>> >>>>>> Hi,
>> >>>>>>
>> >>>>>> I'm running this example:
>> >>>>>>
>> >>>>>>
>> http://www.itk.org/Doxygen/html/Filtering_2ResampleImageFilter3_8cxx-example.html
>> >>>>>>
>> >>>>>> and I'm getting this result which is fine but I need the white
>> >>>>>> sections left due to the rotation to be black. how can I achieve
>> this?
>> >>>>>>
>> >>>>>> <Capture.JPG>
>> >>>>>>
>> >>>>>> _____________________________________
>> >>>>>> Powered by www.kitware.com
>> >>>>>>
>> >>>>>> Visit other Kitware open-source projects at
>> >>>>>> http://www.kitware.com/opensource/opensource.html
>> >>>>>>
>> >>>>>> Kitware offers ITK Training Courses, for more information visit:
>> >>>>>> http://www.kitware.com/products/protraining.php
>> >>>>>>
>> >>>>>> 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://public.kitware.com/mailman/listinfo/insight-users
>> >>>>>>
>> >>>>>>
>> >>>>>
>> >>>>
>> >>>>
>> >>>
>> >>
>> >
>> >
>> > _____________________________________
>> > Powered by www.kitware.com
>> >
>> > Visit other Kitware open-source projects at
>> > http://www.kitware.com/opensource/opensource.html
>> >
>> > Kitware offers ITK Training Courses, for more information visit:
>> > http://www.kitware.com/products/protraining.php
>> >
>> > 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://public.kitware.com/mailman/listinfo/insight-users
>> >
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/insight-users/attachments/20141114/45ff0dbc/attachment-0001.html>
More information about the Insight-users
mailing list