@@ -31,7 +31,7 @@ namespace itk
3131 *
3232 * \ingroup MeshToPolyData
3333 */
34- template < typename TPixel >
34+ template < typename TPixel, typename TCellPixel = TPixel >
3535class ITK_TEMPLATE_EXPORT PolyData: public DataObject
3636{
3737public:
@@ -53,7 +53,8 @@ class ITK_TEMPLATE_EXPORT PolyData: public DataObject
5353
5454 /* * Type of PointData or CellData */
5555 using PixelType = TPixel;
56- using MeshTraits = DefaultStaticMeshTraits< PixelType, PointDimension, PointDimension >;
56+ using CellPixelType = TCellPixel;
57+ using MeshTraits = DefaultStaticMeshTraits< PixelType, PointDimension, PointDimension, float , float , CellPixelType >;
5758
5859 /* * Convenient type alias obtained from TMeshTraits template parameter. */
5960 using CoordRepType = typename MeshTraits::CoordRepType;
@@ -121,8 +122,8 @@ class ITK_TEMPLATE_EXPORT PolyData: public DataObject
121122
122123 /* * Access routines to fill the CellData container, and get information
123124 * from it. */
124- void SetCellData (CellIdentifier, PixelType );
125- bool GetCellData (CellIdentifier, PixelType *) const ;
125+ void SetCellData (CellIdentifier, CellPixelType );
126+ bool GetCellData (CellIdentifier, CellPixelType *) const ;
126127
127128protected:
128129 PolyData ();
0 commit comments