[Insight-developers] In consistent Function return value for GetNumberOfComponents

Luis Ibanez luis.ibanez at kitware.com
Thu May 5 21:34:26 EDT 2005


Hi Hans,

That sounds like a good idea to me.
Thanks for volunteering to fix it.


      Luis



-------------------
Hans Johnson wrote:
> Hello All,
> 
> It seems that the function GetNumberOfComponents is inconsistently defined.
> I each case that I have looked at, it appears that this function should
> return an unsigned int.
> 
> I would be happy to make these consistent if I get approval.
> 
> Thanks,
> Hans
> 
> 
> grep -r "static.*GetNumberOfComponents" *
> Code/Common/itkRGBAPixel.h:  static int GetNumberOfComponents(){ return 4;}
> Code/Common/itkRGBPixel.h:  static int GetNumberOfComponents(){ return 3;}
> Code/Common/itkSymmetricSecondRankTensor.h:  static unsigned int
> GetNumberOfComponents()
> Code/Common/itkVector.h:  static int GetNumberOfComponents(){ return
> NVectorDimension;}
> Code/Common/tags:GetNumberOfComponents  itkRGBAPixel.h  /^  static int
> GetNumberOfComponents(){ return 4;}$/;"  f       class:itk::RGBAPixel
> Code/Common/tags:GetNumberOfComponents  itkRGBPixel.h   /^  static int
> GetNumberOfComponents(){ return 3;}$/;"  f       class:itk::RGBPixel
> Code/Common/tags:GetNumberOfComponents  itkVector.h     /^  static int
> GetNumberOfComponents(){ return NVectorDimension;}$/;"   f
> class:itk::Vector
> Code/IO/itkDefaultConvertPixelTraits.h:  static unsigned int
> GetNumberOfComponents()
> Code/IO/itkDefaultConvertPixelTraits.h:  static unsigned int
> GetNumberOfComponents()                            \
> Code/IO/itkDefaultConvertPixelTraits.h:  static unsigned int
> GetNumberOfComponents()                            \
> Code/IO/itkDefaultConvertPixelTraits.h:  static unsigned int
> GetNumberOfComponents()                            \
> Code/IO/tags:GetNumberOfComponents      itkDefaultConvertPixelTraits.h  /^
> static unsigned int GetNumberOfComponents() $/;"    f
> class:itk::DefaultConvertPixelTraits
> 
> 
> _______________________________________________
> Insight-developers mailing list
> Insight-developers at itk.org
> http://www.itk.org/mailman/listinfo/insight-developers
> 
> 





More information about the Insight-developers mailing list