[Insight-developers] Re: itkTypeMacro
Stephen R. Aylward
aylward at unc.edu
Thu Jan 20 10:33:32 EST 2005
The following classes use the itkTypeMacro incorrectly (See Luis'
explanation at the end of this email).
Bill, should I wait until a greener dashboard before making these
changes, or should I do them today?
Stephen
> ./Code/Algorithms/itkSimplexMeshVolumeCalculator.h:
itkTypeMacro(Self, Object);
> ./Code/BasicFilters/itkMinimumMaximumImageCalculator.h:
itkTypeMacro(Self, Object);
> ./Code/BasicFilters/itkSpatialObjectToImageStatisticsCalculator.h:
itkTypeMacro(Self, Object);
> ./Code/Common/itkImageDuplicator.h: itkTypeMacro(Self, Object);
> ./Code/IO/itkPolygonGroupSpatialObjectXMLFile.h:
itkTypeMacro(Self,Superclass);
> ./Code/IO/itkSpatialObjectReader.h: itkTypeMacro(Self, Superclass);
> ./Code/IO/itkSpatialObjectWriter.h: itkTypeMacro(Self, Superclass);
> ./Code/SpatialObject/itkAffineGeometryFrame.h:
itkTypeMacro(Self,Superclass);
> ./Code/SpatialObject/itkSceneSpatialObject.h: itkTypeMacro(Self,
Superclass);
./Code/Common/itkNonUniformBSpline.h: itkTypeMacro( Self, Superclass );
./Code/Common/itkTreeNode.h: itkTypeMacro( Self, Superclass );
./Code/SpatialObject/itkArrowSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkCylinderSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkDTITubeSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkEllipseSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkGaussianSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkGroupSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkLandmarkSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkLineSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkPlaneSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkPointBasedSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkPolygonGroupSpatialObject.h: itkTypeMacro(
Self, Superclass );
./Code/SpatialObject/itkPolygonSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkSpatialObject.h: itkTypeMacro( Self, Superclass );
./Code/SpatialObject/itkSpatialObjectProperty.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkSpatialObjectTreeNode.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkSurfaceSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkTubeSpatialObject.h: itkTypeMacro( Self,
Superclass );
./Code/SpatialObject/itkVesselTubeSpatialObject.h: itkTypeMacro( Self,
Superclass );
Luis Ibanez wrote:
>
> Hi Stephen,
>
> Yeap, using "Self" in the Type Macro is not useful
> since the macro simply takes the string of its
> argument an this is what is returned in
>
> GetNameOfClass()
>
> The code in the macro is
>
>
>
> #define itkTypeMacro(thisClass,superclass) \
> virtual const char * GetNameOfClass() const \
> { return #thisClass; }
>
>
>
> so... when we put
>
>
> itkTypeMacro( Self, Superclass)
>
>
> the effect is that the method GetNameOfClass() will
> return "Self" as the name of the class.
>
>
> It will be good to fix the classes that we identify
> using itkTypeMacro(Self,Superclass)...
>
>
>
> Luis
>
>
>
> ---------------------------
> Stephen R. Aylward wrote:
>
>> Hi Luis,
>>
>> You raised an interesting point today....
>>
>> Is it true that we cannot use
>>
>> itkTypeMacro( Self, Superclass );
>>
>> ?????
>>
>> Is so, then there are changes to be made in several classes (including
>> the spatial object classes) in ITK!
>>
>> I can help make those changes...
>>
>> Thanks,
>> Stephen
>>
>
>
>
>
--
===========================================================
Dr. Stephen R. Aylward
Associate Professor of Radiology
Adjunct Associate Professor of Computer Science and Surgery
http://caddlab.rad.unc.edu
aylward at unc.edu
(919) 966-9695
More information about the Insight-developers
mailing list