[Insight-users] itkVectorConfidenceConnectedImageFilter Problem

Luis Ibanez luis.ibanez at kitware.com
Mon, 05 Jan 2004 16:21:37 -0500


Hi Robert,

Yes, in order to use the VectorConfidenceConnectedImageFilter with
a specific Vector type, there should be an entry for this Vector type
in the NumericTraits file.

Generic entries for Vectors have not been created simply because the
number of possible combinations is too large and there is always the
possiblity of an user creating a new combination.

The solution is pretty simple though. You just need to create two files in
 your application that will be equivalent to the NumericTraitsRGBPixel
files.

Let's call them

      itkNumericTraitsVectorPixel.h
      itkNumericTraitsVectorPixel.cxx

You make sure to include the first one in the file where you are trying
to instantiate the VectorConfidenceConnectedImageFilter, and make sure
that you add the .cxx to the list of source files in the CMakeLists.txt 
file.

Inside the .h and .cxx files you add the traits of the particular Vector 
type
that you are trying to use as pixel type.


Please let us know if you have further questions,


   Thanks


       Luis


--------------------------------
Robert L. Van Uitert wrote:

>Hi,
>	I'm trying to use the itkVectorConfidenceConnectedImageFilter
>with an input pixel type of Vector, rather than the RGBPixel
>type as is used in the Software Guide example.  I am getting compilation
>errors because NumericTraits<Vector<type,dimension> > is not defined for
>any Vector type or dimension.  I noticed that NumericTraits<type> is
>defined in NumericTraits.h for all types and NumericTraits<RGBPixel<type>
>  
>
>>is defined in NumericTraitsRGBPixel.h, but only for type = unsigned
>>    
>>
>char.  Should there be a NumericTraitsVector defined for the appropriate
>types and dimensions and more types defined in the NumericTraitsRGBPixel.h
>or is it inappropriate to use the itkVectorConfidenceConnectedImageFilter
>with non-RGBPixel<unsigned char> types?
>
>Thank you,
>
>Robert Van Uitert
>_______________________________________________
>Insight-users mailing list
>Insight-users at itk.org
>http://www.itk.org/mailman/listinfo/insight-users
>
>  
>