Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkQuadEdgeMeshTraits.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkQuadEdgeMeshTraits.h,v $
00005   Language:  C++
00006   Date:      $Date: 2007/01/29 14:59:51 $
00007   Version:   $Revision: 1.6 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 
00018 #ifndef __itkQuadEdgeMeshTraits_h
00019 #define __itkQuadEdgeMeshTraits_h
00020 
00021 #include <set>
00022 #include <itkCellInterface.h>
00023 #include <itkMapContainer.h>
00024 #include "itkQuadEdgeMeshPoint.h"
00025 #include "itkGeometricalQuadEdge.h"
00026 
00027 namespace itk
00028 {
00038 template< int VPointDimension, typename TCoordRep,
00039           typename TInterpolationWeight, typename TPointIdentifier,
00040           typename TCellIdentifier, typename TCellFeatureIdentifier,
00041           typename TPoint, typename TPointsContainer,
00042           typename TUsingCellsContainer, typename TQE >
00043 class QuadEdgeMeshCellTraitsInfo
00044 {
00045 public:
00046   itkStaticConstMacro( PointDimension, unsigned int, VPointDimension );
00047   typedef TCoordRep               CoordRepType;
00048   typedef TInterpolationWeight    InterpolationWeightType;
00049   typedef TPointIdentifier        PointIdentifier;
00050   typedef TCellIdentifier         CellIdentifier;
00051   typedef TCellFeatureIdentifier  CellFeatureIdentifier;
00052   typedef TPoint                  PointType;
00053   typedef TPointsContainer        PointsContainer;
00054   typedef TUsingCellsContainer    UsingCellsContainer;
00055 
00057   typedef TQE                             QuadEdgeType;
00058   typedef typename TQE::IteratorGeom      PointIdIterator;
00059   typedef typename TQE::ConstIteratorGeom PointIdConstIterator;
00060 };
00061 
00076 template< typename TPixel, unsigned int VPointDimension,
00077           typename TPData, typename TDData, 
00078           typename TCoordRep=float, typename TInterpolationWeight=float >
00079 class QuadEdgeMeshTraits
00080 {
00081 public:
00083   typedef QuadEdgeMeshTraits                Self;
00084   typedef TPixel                            PixelType;
00085   typedef TPixel                            CellPixelType;
00086   typedef TCoordRep                         CoordRepType;
00087   typedef TInterpolationWeight              InterpolationWeightType;
00088 
00089   itkStaticConstMacro( PointDimension, unsigned int, VPointDimension );
00090   itkStaticConstMacro( MaxTopologicalDimension, unsigned int,
00091                        VPointDimension );
00092 
00093   typedef unsigned long PointIdentifier;
00094   typedef unsigned long CellIdentifier;
00095   typedef unsigned long CellFeatureIdentifier;
00096 
00097   typedef std::set< CellIdentifier > UsingCellsContainer;
00098   typedef std::set< CellIdentifier > PointCellLinksContainer;
00099 
00101   typedef TPData PrimalDataType;
00102   typedef TDData DualDataType;
00103   typedef GeometricalQuadEdge< PointIdentifier, CellIdentifier,
00104                         PrimalDataType, DualDataType > QEPrimal;
00105   //typedef QEPrimal QEType;
00106   typedef typename QEPrimal::DualType             QEDual;
00109   typedef typename QEPrimal::OriginRefType     VertexRefType;
00110   typedef typename QEPrimal::DualOriginRefType FaceRefType;
00111 
00113   typedef QuadEdgeMeshPoint< 
00114     CoordRepType, VPointDimension, QEPrimal >           PointType;
00115   typedef MapContainer< PointIdentifier, PointType >    PointsContainer;
00116 
00118   typedef QuadEdgeMeshCellTraitsInfo< 
00119     VPointDimension, CoordRepType,
00120     InterpolationWeightType, PointIdentifier,
00121     CellIdentifier,          CellFeatureIdentifier,
00122     PointType,               PointsContainer,
00123     UsingCellsContainer,     QEPrimal >                 CellTraits;
00124   typedef CellInterface< CellPixelType, CellTraits >    CellType;
00125   typedef typename CellType::CellAutoPointer            CellAutoPointer;
00126 
00128   typedef MapContainer< PointIdentifier,
00129                         PointCellLinksContainer >       CellLinksContainer;
00130   typedef MapContainer< CellIdentifier, CellType* >     CellsContainer;
00131   typedef MapContainer< PointIdentifier, PixelType >    PointDataContainer;
00132   typedef MapContainer< CellIdentifier, CellPixelType > CellDataContainer;
00133 
00135   typedef typename PointType::VectorType VectorType;
00136 };
00137 
00138 } 
00139 
00140 #endif 
00141 

Generated at Mon Mar 12 02:27:45 2007 for ITK by doxygen 1.5.1 written by Dimitri van Heesch, © 1997-2000