[Insight-users] Runtime typed ImageFileReader ...
Luis Ibanez
luis.ibanez@kitware.com
Fri, 28 Mar 2003 18:14:25 -0500
Hi Marc,
A) About the plugin mechanism:
Yes, the factory allows to load libraries at run time
(at the startup of the application, to be precise).
This has not been extensively tested, so you may
find surprises if you try it right now. But, in any
case its functionality has been anticipated and if
something is not working there we will have to fix it.
The idea is that you can write your readers (and even
other classes) in shared libraries. This allows you
to easily write extension for the toolkit.
B) About DICOM writer:
There are no immediate plans for writing DICOM.
This is a challenging task that many people is
facing in the medical image community. (not only
among ITK users).
Regards
Luis
---------------------
Marc Traina wrote:
> Thanks Luis,
>
> Your precise explanations was very helpful.
>
> 1) In fact I have use the "ImageIOFactory::CreateImageIO(...)" static
> method to get an "ImageIOBase" and pre-read the image information before
> the declaration of the reader and the writer.
>
> itk::ImageIOBase::Pointer ioBase =
> itk::ImageIOFactory::CreateImageIO(inputFilename,
> itk::ImageIOFactory::ReadMode);
> if (ioBase.IsNotNull()) {
> ioBase->SetFileName(inputFilename);
> ioBase->ReadImageInformation();
> .../...
> .../...ioBase->GetNumberOfDimensions(); .../...
> .../...ioBase->GetPixelType(); .../...
> }
>
>
> 2) I have found a very interesting plug-in mechanism already implemented
> in the ObjectFactoryBase. I have understand that this mechanism loads
> dynamic libraries found in the "ITK_AUTOLOAD_PATH" environment variable
> and register the inside factories.
> a) Does a precise documentation exist on how to write a pluggable
> library for that mechanism ?
> b) Does this mechanism is supported by ITK ? In other words, can I base
> my application architecture on this mechanism ?
>
> 3) Does the Insight Consortium plan to develop a DICOM writer ?
> And when ??? ;-)
>
>
> NB : ITK and its associated products are really a model of design. Good
> job !
>
>