<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta name="robots" content="noindex"> <meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>ITK: itkRelabelComponentImageFilter.h Source File</title> <link href="DoxygenStyle.css" rel="stylesheet" type="text/css"> </head><body bgcolor="#ffffff"> <!-- Section customized for INSIGHT : Tue Jul 17 01:02:45 2001 --> <center> <a href="index.html" class="qindex">Main Page</a> <a href="modules.html" class="qindex">Groups</a> <a href="namespaces.html" class="qindex">Namespace List</a> <a href="hierarchy.html" class="qindex">Class Hierarchy</a> <a href="classes.html" class="qindex">Alphabetical List</a> <a href="annotated.html" class="qindex">Compound List</a> <a href="files.html" class="qindex">File List</a> <a href="namespacemembers.html" class="qindex">Namespace Members</a> <a href="functions.html" class="qindex">Compound Members</a> <a href="globals.html" class="qindex">File Members</a> <a href="pages.html" class="qindex">Concepts</a></center> <!-- Generated by Doxygen 1.5.9 --> <div class="navpath"><a class="el" href="dir_02e23d841c198393a6e961e9a0678fff.html">Code</a> » <a class="el" href="dir_00ffda33c24cbbf617b202f4f3bcb7e8.html">BasicFilters</a> </div> <div class="contents"> <h1>itkRelabelComponentImageFilter.h</h1><a href="itkRelabelComponentImageFilter_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*=========================================================================</span> <a name="l00002"></a>00002 <span class="comment"></span> <a name="l00003"></a>00003 <span class="comment"> Program: Insight Segmentation & Registration Toolkit</span> <a name="l00004"></a>00004 <span class="comment"> Module: $RCSfile: itkRelabelComponentImageFilter.h,v $</span> <a name="l00005"></a>00005 <span class="comment"> Language: C++</span> <a name="l00006"></a>00006 <span class="comment"> Date: $Date: 2008-10-17 16:30:52 $</span> <a name="l00007"></a>00007 <span class="comment"> Version: $Revision: 1.15 $</span> <a name="l00008"></a>00008 <span class="comment"></span> <a name="l00009"></a>00009 <span class="comment"> Copyright (c) Insight Software Consortium. All rights reserved.</span> <a name="l00010"></a>00010 <span class="comment"> See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.</span> <a name="l00011"></a>00011 <span class="comment"></span> <a name="l00012"></a>00012 <span class="comment"> This software is distributed WITHOUT ANY WARRANTY; without even </span> <a name="l00013"></a>00013 <span class="comment"> the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR </span> <a name="l00014"></a>00014 <span class="comment"> PURPOSE. See the above copyright notices for more information.</span> <a name="l00015"></a>00015 <span class="comment"></span> <a name="l00016"></a>00016 <span class="comment">=========================================================================*/</span> <a name="l00017"></a>00017 <span class="preprocessor">#ifndef __itkRelabelComponentImageFilter_h</span> <a name="l00018"></a>00018 <span class="preprocessor"></span><span class="preprocessor">#define __itkRelabelComponentImageFilter_h</span> <a name="l00019"></a>00019 <span class="preprocessor"></span> <a name="l00020"></a>00020 <span class="preprocessor">#include "<a class="code" href="itkInPlaceImageFilter_8h.html">itkInPlaceImageFilter.h</a>"</span> <a name="l00021"></a>00021 <span class="preprocessor">#include "<a class="code" href="itkImage_8h.html">itkImage.h</a>"</span> <a name="l00022"></a>00022 <span class="preprocessor">#include <vector></span> <a name="l00023"></a>00023 <a name="l00024"></a>00024 <span class="keyword">namespace </span>itk <a name="l00025"></a>00025 { <a name="l00026"></a>00026 <a name="l00073"></a>00073 <span class="keyword">template</span> <<span class="keyword">class</span> TInputImage, <span class="keyword">class</span> TOutputImage> <a name="l00074"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html">00074</a> <span class="keyword">class </span><a class="code" href="itkWin32Header_8h.html#7d4384322557205d75f0719c012dded6">ITK_EXPORT</a> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">RelabelComponentImageFilter</a> : <a name="l00075"></a>00075 <span class="keyword">public</span> <a class="code" href="classitk_1_1InPlaceImageFilter.html" title="Base class for filters that take an image as input and overwrite that image as the...">InPlaceImageFilter</a>< TInputImage, TOutputImage > <a name="l00076"></a>00076 { <a name="l00077"></a>00077 <span class="keyword">public</span>: <a name="l00081"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#0755997aeb1e9dda8ea00c03fdebcb10">00081</a> <span class="keyword">typedef</span> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">RelabelComponentImageFilter</a> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">Self</a>; <a name="l00082"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#febdca516596578d123500b6fb70da04">00082</a> <span class="keyword">typedef</span> <a class="code" href="classitk_1_1InPlaceImageFilter.html">InPlaceImageFilter< TInputImage, TOutputImage ></a> <a class="code" href="classitk_1_1InPlaceImageFilter.html">Superclass</a>; <a name="l00083"></a>00083 <a name="l00087"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#3aec62f464275821173da002fc4131b1">00087</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> Superclass::InputImagePointer InputImagePointer; <a name="l00088"></a>00088 <a name="l00093"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#ecfef20dd928b564401a138a7da7afe6">00093</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> TOutputImage::PixelType <a class="code" href="namespaceHardConnectedComponentImageFilter.html#73549c9066bb62470db248f27cde10d2">OutputPixelType</a>; <a name="l00094"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#5289e99b5caa260953054a1f40761ddf">00094</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> TOutputImage::InternalPixelType <a class="code" href="namespaceHardConnectedComponentImageFilter.html#05ddc2f0f1e5f6684417679cf537b4e2">OutputInternalPixelType</a>; <a name="l00095"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#2611e557e276d820a932f35cf74e838d">00095</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> TInputImage::PixelType <a class="code" href="namespaceHardConnectedComponentImageFilter.html#6e44b89d73d576fe68c175566a634ab8">InputPixelType</a>; <a name="l00096"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#9201642baf991859f3f56d7b3d344704">00096</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> TInputImage::InternalPixelType <a class="code" href="namespaceHardConnectedComponentImageFilter.html#a49b439ecaa370af8c4f2c64b0f845bd">InputInternalPixelType</a>; <a name="l00097"></a>00097 <a class="code" href="itkMacro_8h.html#1905cf6b2e88235996fa7ff73b2fb0eb">itkStaticConstMacro</a>(ImageDimension, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span>, <a name="l00098"></a>00098 TOutputImage::ImageDimension); <a name="l00099"></a>00099 <a class="code" href="itkMacro_8h.html#1905cf6b2e88235996fa7ff73b2fb0eb">itkStaticConstMacro</a>(InputImageDimension, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span>, <a name="l00100"></a>00100 TInputImage::ImageDimension); <a name="l00102"></a>00102 <a name="l00106"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#8ee1534fb0185946481c7caf71690a1a">00106</a> <span class="keyword">typedef</span> TInputImage <a class="code" href="namespaceHardConnectedComponentImageFilter.html#3742cbac150bee74daa9aab85ed80623">InputImageType</a>; <a name="l00107"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#872b3753927e30b3401eb04d2d77e8c2">00107</a> <span class="keyword">typedef</span> TOutputImage <a class="code" href="namespaceHardConnectedComponentImageFilter.html#386ea018cab3835dcdff2603f4d2280e">OutputImageType</a>; <a name="l00108"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#cd49996210cee4b3a1a39d2ed757db0b">00108</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#be32dc19e71d40322ad9828b9ab40853">TInputImage::IndexType</a> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#be32dc19e71d40322ad9828b9ab40853">IndexType</a>; <a name="l00109"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#174e28160db2bfce28145e71406a454a">00109</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#5bf82236e1e50e653de84c8ead448599">TInputImage::SizeType</a> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#5bf82236e1e50e653de84c8ead448599">SizeType</a>; <a name="l00110"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#c0c2ffc4b6a85b9256cb1a4c6c6699bb">00110</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#ed8c4a40607d317c666eb96ea265e126">TOutputImage::RegionType</a> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#ed8c4a40607d317c666eb96ea265e126">RegionType</a>; <a name="l00111"></a>00111 <a name="l00115"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#3dc658b1a704ccef67f819110f2707ea">00115</a> <span class="keyword">typedef</span> <a class="code" href="classitk_1_1SmartPointer.html">SmartPointer<Self></a> <a class="code" href="classitk_1_1SmartPointer.html">Pointer</a>; <a name="l00116"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#a30fab80449ce171b2b3e07d4f7dd24d">00116</a> <span class="keyword">typedef</span> <a class="code" href="classitk_1_1SmartPointer.html">SmartPointer<const Self></a> <a class="code" href="classitk_1_1SmartPointer.html">ConstPointer</a>; <a name="l00117"></a>00117 <a name="l00121"></a>00121 <a class="code" href="itkMacro_8h.html#574c1f86661d409dd32c742307a0e96a">itkTypeMacro</a>(<a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">RelabelComponentImageFilter</a>, <a class="code" href="classitk_1_1ImageToImageFilter.html" title="Base class for filters that take an image as input and produce an image as output...">ImageToImageFilter</a>); <a name="l00122"></a>00122 <a name="l00126"></a>00126 <a class="code" href="itkMacro_8h.html#0fdc15685afa271857c57e7cd482f30c">itkNewMacro</a>(<a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">Self</a>); <a name="l00127"></a>00127 <a name="l00130"></a>00130 <a class="code" href="itkMacro_8h.html#1600305bb01e39e87c472d8bf29bd1cf">itkGetMacro</a>(NumberOfObjects, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00131"></a>00131 <a name="l00137"></a>00137 <a class="code" href="itkMacro_8h.html#1600305bb01e39e87c472d8bf29bd1cf">itkGetMacro</a>(OriginalNumberOfObjects, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00138"></a>00138 <a name="l00141"></a>00141 <a class="code" href="itkMacro_8h.html#7ebdd33cc5e7d74720ced9099c034faa">itkSetMacro</a>(NumberOfObjectsToPrint, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00142"></a>00142 <a class="code" href="itkMacro_8h.html#7d989c13a1a213168db99ae0f84185d4">itkGetConstReferenceMacro</a>(NumberOfObjectsToPrint, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00144"></a>00144 <a name="l00151"></a>00151 <a class="code" href="itkMacro_8h.html#7ebdd33cc5e7d74720ced9099c034faa">itkSetMacro</a>(MinimumObjectSize, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00152"></a>00152 <a name="l00158"></a>00158 <a class="code" href="itkMacro_8h.html#1600305bb01e39e87c472d8bf29bd1cf">itkGetMacro</a>(MinimumObjectSize, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>); <a name="l00159"></a>00159 <a name="l00165"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#4c15a1634624799750fdbd313ad95f96">00165</a> <span class="keyword">const</span> std::vector<unsigned long>& GetSizeOfObjectsInPixels()<span class="keyword"> const</span> <a name="l00166"></a>00166 <span class="keyword"> </span>{ <span class="keywordflow">return</span> m_SizeOfObjectsInPixels; } <a name="l00167"></a>00167 <a name="l00173"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#bdbe90302a3bcff38dd02abbfc65a6dc">00173</a> <span class="keyword">const</span> std::vector<float>& GetSizeOfObjectsInPhysicalUnits()<span class="keyword"> const</span> <a name="l00174"></a>00174 <span class="keyword"> </span>{ <span class="keywordflow">return</span> m_SizeOfObjectsInPhysicalUnits; } <a name="l00175"></a>00175 <a name="l00179"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#35edfe18445bcda607ecb4e7bbd29db0">00179</a> <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> GetSizeOfObjectInPixels(<span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> obj)<span class="keyword"> const</span> <a name="l00180"></a>00180 <span class="keyword"> </span>{ <a name="l00181"></a>00181 <span class="keywordflow">if</span> (obj > 0 && obj <= m_NumberOfObjects) <a name="l00182"></a>00182 { <a name="l00183"></a>00183 <span class="keywordflow">return</span> m_SizeOfObjectsInPixels[obj-1]; <a name="l00184"></a>00184 } <a name="l00185"></a>00185 <span class="keywordflow">else</span> <a name="l00186"></a>00186 { <a name="l00187"></a>00187 <span class="keywordflow">return</span> 0; <a name="l00188"></a>00188 } <a name="l00189"></a>00189 } <a name="l00191"></a>00191 <a name="l00195"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#97e48e6e6304dc105ae64c20b589b39c">00195</a> <span class="keywordtype">float</span> GetSizeOfObjectInPhysicalUnits(<span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> obj)<span class="keyword"> const</span> <a name="l00196"></a>00196 <span class="keyword"> </span>{ <a name="l00197"></a>00197 <span class="keywordflow">if</span> (obj > 0 && obj <= m_NumberOfObjects) <a name="l00198"></a>00198 { <a name="l00199"></a>00199 <span class="keywordflow">return</span> m_SizeOfObjectsInPhysicalUnits[obj-1]; <a name="l00200"></a>00200 } <a name="l00201"></a>00201 <span class="keywordflow">else</span> <a name="l00202"></a>00202 { <a name="l00203"></a>00203 <span class="keywordflow">return</span> 0; <a name="l00204"></a>00204 } <a name="l00205"></a>00205 } <a name="l00207"></a>00207 <a name="l00208"></a>00208 <span class="preprocessor">#ifdef ITK_USE_CONCEPT_CHECKING</span> <a name="l00209"></a>00209 <span class="preprocessor"></span> <a name="l00210"></a>00210 <a class="code" href="itkConceptChecking_8h.html#009eae6c305d9c390972159815e6a710">itkConceptMacro</a>(InputEqualityComparableCheck, <a name="l00211"></a>00211 (<a class="code" href="structitk_1_1Concept_1_1EqualityComparable.html">Concept::EqualityComparable<InputPixelType></a>)); <a name="l00212"></a>00212 <a class="code" href="itkConceptChecking_8h.html#009eae6c305d9c390972159815e6a710">itkConceptMacro</a>(UnsignedLongConvertibleToInputCheck, <a name="l00213"></a>00213 (<a class="code" href="structitk_1_1Concept_1_1Convertible.html">Concept::Convertible<unsigned long, InputPixelType></a>)); <a name="l00214"></a>00214 <a class="code" href="itkConceptChecking_8h.html#009eae6c305d9c390972159815e6a710">itkConceptMacro</a>(OutputLongConvertibleToUnsignedLongCheck, <a name="l00215"></a>00215 (<a class="code" href="structitk_1_1Concept_1_1Convertible.html">Concept::Convertible<OutputPixelType, unsigned long></a>)); <a name="l00216"></a>00216 <a class="code" href="itkConceptChecking_8h.html#009eae6c305d9c390972159815e6a710">itkConceptMacro</a>(InputConvertibleToOutputCheck, <a name="l00217"></a>00217 (<a class="code" href="structitk_1_1Concept_1_1Convertible.html">Concept::Convertible<InputPixelType, OutputPixelType></a>)); <a name="l00218"></a>00218 <a class="code" href="itkConceptChecking_8h.html#009eae6c305d9c390972159815e6a710">itkConceptMacro</a>(SameDimensionCheck, <a name="l00219"></a>00219 (<a class="code" href="structitk_1_1Concept_1_1SameDimension.html">Concept::SameDimension<InputImageDimension, ImageDimension></a>)); <a name="l00220"></a>00220 <a name="l00222"></a>00222 <span class="preprocessor">#endif</span> <a name="l00223"></a>00223 <span class="preprocessor"></span> <a name="l00224"></a>00224 <span class="keyword">protected</span>: <a name="l00225"></a>00225 <a name="l00226"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#312508a247e2a804643548b3d065cca3">00226</a> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">RelabelComponentImageFilter</a>() <a name="l00227"></a>00227 : m_NumberOfObjects(0), m_NumberOfObjectsToPrint(10), <a name="l00228"></a>00228 m_OriginalNumberOfObjects(0), m_MinimumObjectSize(0) <a name="l00229"></a>00229 { this->InPlaceOff(); } <a name="l00230"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#8312d9d39501abfbe3f33a2486d6fa9b">00230</a> <span class="keyword">virtual</span> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html#8312d9d39501abfbe3f33a2486d6fa9b">~RelabelComponentImageFilter</a>() {} <a name="l00231"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter.html#e5d03bfb1fb2480e13ac3ee07ac2bcb4">00231</a> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html#e5d03bfb1fb2480e13ac3ee07ac2bcb4">RelabelComponentImageFilter</a>(<span class="keyword">const</span> <a class="code" href="classitk_1_1RelabelComponentImageFilter.html" title="Relabel the components in an image such that consecutive labels are used.">Self</a>&) {} <a name="l00232"></a>00232 <a name="l00236"></a>00236 <span class="keywordtype">void</span> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#f75a5945cdd8315676941024a0b8c1e9">GenerateData</a>(); <a name="l00237"></a>00237 <a name="l00241"></a>00241 <span class="keywordtype">void</span> GenerateInputRequestedRegion(); <a name="l00242"></a>00242 <a name="l00244"></a>00244 <span class="keywordtype">void</span> <a class="code" href="namespaceHardConnectedComponentImageFilter.html#920ae03048a5ad715d803ca2e92b52de">PrintSelf</a>(std::ostream& os, <a class="code" href="classitk_1_1Indent.html" title="Control indentation during Print() invocation.">Indent</a> indent) <span class="keyword">const</span>; <a name="l00245"></a>00245 <a name="l00246"></a><a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html">00246</a> <span class="keyword">struct </span><a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html">RelabelComponentObjectType</a> <a name="l00247"></a>00247 { <a name="l00248"></a><a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#8d218424d7318c61ef2e2492d807e6d3">00248</a> <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_ObjectNumber; <a name="l00249"></a><a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#af046001d3ada1186d1682e3afaf4fb5">00249</a> <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_SizeInPixels; <a name="l00250"></a><a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#8a779871f9ffb47f6ee367e1ee7431b7">00250</a> <span class="keywordtype">float</span> m_SizeInPhysicalUnits; <a name="l00251"></a>00251 }; <a name="l00252"></a>00252 <a name="l00253"></a>00253 <span class="comment">// put the function objects here for sorting in descending order</span> <a name="l00254"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter_1_1RelabelComponentSizeInPixelsComparator.html">00254</a> <span class="keyword">class </span><a class="code" href="classitk_1_1RelabelComponentImageFilter_1_1RelabelComponentSizeInPixelsComparator.html">RelabelComponentSizeInPixelsComparator</a> <a name="l00255"></a>00255 { <a name="l00256"></a>00256 <span class="keyword">public</span>: <a name="l00257"></a><a class="code" href="classitk_1_1RelabelComponentImageFilter_1_1RelabelComponentSizeInPixelsComparator.html#9f8acdc74d8607ec9d7aa4c6792192a4">00257</a> <span class="keywordtype">bool</span> operator()(<span class="keyword">const</span> <a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html">RelabelComponentObjectType</a>&a, <a name="l00258"></a>00258 <span class="keyword">const</span> <a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html">RelabelComponentObjectType</a> &b) <a name="l00259"></a>00259 { <a name="l00260"></a>00260 <span class="keywordflow">if</span> (a.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#af046001d3ada1186d1682e3afaf4fb5">m_SizeInPixels</a> > b.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#af046001d3ada1186d1682e3afaf4fb5">m_SizeInPixels</a>) <a name="l00261"></a>00261 { <a name="l00262"></a>00262 <span class="keywordflow">return</span> <span class="keyword">true</span>; <a name="l00263"></a>00263 } <a name="l00264"></a>00264 <span class="keywordflow">else</span> <span class="keywordflow">if</span> (a.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#af046001d3ada1186d1682e3afaf4fb5">m_SizeInPixels</a> < b.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#af046001d3ada1186d1682e3afaf4fb5">m_SizeInPixels</a>) <a name="l00265"></a>00265 { <a name="l00266"></a>00266 <span class="keywordflow">return</span> <span class="keyword">false</span>; <a name="l00267"></a>00267 } <a name="l00268"></a>00268 <span class="comment">// size in pixels and physical units are the same, sort based on</span> <a name="l00269"></a>00269 <span class="comment">// original object number</span> <a name="l00270"></a>00270 <span class="keywordflow">else</span> <span class="keywordflow">if</span> (a.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#8d218424d7318c61ef2e2492d807e6d3">m_ObjectNumber</a> < b.<a class="code" href="structitk_1_1RelabelComponentImageFilter_1_1RelabelComponentObjectType.html#8d218424d7318c61ef2e2492d807e6d3">m_ObjectNumber</a>) <a name="l00271"></a>00271 { <a name="l00272"></a>00272 <span class="keywordflow">return</span> <span class="keyword">true</span>; <a name="l00273"></a>00273 } <a name="l00274"></a>00274 <span class="keywordflow">else</span> <a name="l00275"></a>00275 { <a name="l00276"></a>00276 <span class="keywordflow">return</span> <span class="keyword">false</span>; <a name="l00277"></a>00277 } <a name="l00278"></a>00278 } <a name="l00279"></a>00279 }; <a name="l00280"></a>00280 <a name="l00281"></a>00281 <a name="l00282"></a>00282 <span class="keyword">private</span>: <a name="l00283"></a>00283 <a name="l00284"></a>00284 <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_NumberOfObjects; <a name="l00285"></a>00285 <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_NumberOfObjectsToPrint; <a name="l00286"></a>00286 <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_OriginalNumberOfObjects; <a name="l00287"></a>00287 <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> m_MinimumObjectSize; <a name="l00288"></a>00288 <a name="l00289"></a>00289 std::vector<unsigned long> m_SizeOfObjectsInPixels; <a name="l00290"></a>00290 std::vector<float> m_SizeOfObjectsInPhysicalUnits; <a name="l00291"></a>00291 <a name="l00292"></a>00292 }; <a name="l00293"></a>00293 <a name="l00294"></a>00294 } <span class="comment">// end namespace itk</span> <a name="l00295"></a>00295 <a name="l00296"></a>00296 <span class="preprocessor">#ifndef ITK_MANUAL_INSTANTIATION</span> <a name="l00297"></a>00297 <span class="preprocessor"></span><span class="preprocessor">#include "itkRelabelComponentImageFilter.txx"</span> <a name="l00298"></a>00298 <span class="preprocessor">#endif</span> <a name="l00299"></a>00299 <span class="preprocessor"></span> <a name="l00300"></a>00300 <span class="preprocessor">#endif</span> <a name="l00301"></a>00301 <span class="preprocessor"></span> </pre></div></div> <hr><address><small> Generated at Fri May 8 00:04:45 2009 for ITK by <a href="http://www.stack.nl/~dimitri/doxygen/index.html"> <img src="http://www.stack.nl/~dimitri/doxygen/doxygen.png" alt="doxygen" align="middle" border=0 width=110 height=53> </a> 1.5.9 written by <a href="mailto:dimitri@stack.nl">Dimitri van Heesch</a>, © 1997-2000</small></address> </body> </html>