mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-08 13:23:51 +00:00
Change CellShapeTag*:Id type to vtkm::UInt8
The shape array in CellSetExplicit was changed a while ago to be of type vtkm::UInt8. However, the shape types remained at vtkm::IdComponent. I can think of no reason why they should not be the same type.
This commit is contained in:
parent
b175468082
commit
3f9a1edb7b
@ -92,7 +92,7 @@ struct CellShapeIdToTag {
|
||||
|
||||
#define VTKM_DEFINE_CELL_TAG(name, idname) \
|
||||
struct CellShapeTag ## name { \
|
||||
static const vtkm::IdComponent Id = vtkm::idname; \
|
||||
static const vtkm::UInt8 Id = vtkm::idname; \
|
||||
}; \
|
||||
namespace internal { \
|
||||
template<> \
|
||||
@ -135,9 +135,9 @@ VTKM_DEFINE_CELL_TAG(Pyramid, CELL_SHAPE_PYRAMID);
|
||||
///
|
||||
struct CellShapeTagGeneric {
|
||||
VTKM_EXEC_CONT
|
||||
CellShapeTagGeneric(vtkm::IdComponent shape) : Id(shape) { }
|
||||
CellShapeTagGeneric(vtkm::UInt8 shape) : Id(shape) { }
|
||||
|
||||
vtkm::IdComponent Id;
|
||||
vtkm::UInt8 Id;
|
||||
};
|
||||
|
||||
|
||||
|
@ -68,8 +68,7 @@ public:
|
||||
VTKM_EXEC
|
||||
CellShapeTag GetCellShape(vtkm::Id index) const
|
||||
{
|
||||
// Likewise, should Shapes be vtkm::Id or something smaller?
|
||||
return CellShapeTag(static_cast<vtkm::IdComponent>(this->Shapes.Get(index)));
|
||||
return CellShapeTag(this->Shapes.Get(index));
|
||||
}
|
||||
|
||||
using IndicesType = vtkm::VecFromPortal<ConnectivityPortalType>;
|
||||
|
Loading…
Reference in New Issue
Block a user