18 #ifndef __itkLabelObjectLineComparator_h
19 #define __itkLabelObjectLineComparator_h
39 template<
class TLabelObjectLine >
43 bool operator()(TLabelObjectLine
const & l1, TLabelObjectLine
const & l2)
const
45 const typename TLabelObjectLine::IndexType & idx1 = l1.GetIndex();
46 const typename TLabelObjectLine::IndexType & idx2 = l2.GetIndex();
48 for (
int i = TLabelObjectLine::ImageDimension - 1; i >= 0; i-- )
50 if ( idx1[i] < idx2[i] )
54 else if ( idx1[i] > idx2[i] )
59 return l1.GetLength() < l2.GetLength();