3#ifndef vtkCellGridSidesQuery_h
4#define vtkCellGridSidesQuery_h
13#include <unordered_map>
16VTK_ABI_NAMESPACE_BEGIN
48 VerticesOfEdges = 0x01,
49 VerticesOfSurfaces = 0x02,
50 EdgesOfSurfaces = 0x04,
51 VerticesOfVolumes = 0x08,
52 EdgesOfVolumes = 0x10,
53 SurfacesOfVolumes = 0x20,
56 SurfacesOfInputs = 0x20,
58 VerticesOfInputs = 0x0b,
60 NextLowestDimension = 0x25
146 vtkSetMacro(OutputDimensionControl,
int);
147 vtkGetMacro(OutputDimensionControl,
int);
148 vtkBooleanMacro(OutputDimensionControl,
int);
180 this->SetSelectionType(
static_cast<SelectionMode>(selnType));
189 std::unordered_map<vtkStringToken, std::unordered_map<vtkIdType, std::set<int>>>>&
224 int OutputDimensionControl{ SideFlags::SurfacesOfInputs };
228 bool TemporarySideCache{
false };
230 std::unordered_map<vtkStringToken, std::unordered_map<vtkIdType, std::set<int>>>>
Perform an operation on cells in a vtkCellMetadata instance.
Hold a map from hash-ids (representing sides of cells of multiple types) to details on the cells that...
A cell-grid query for enumerating sides of cells.
PassWork
An enum specifying the work responders should perform for each pass.
vtkGetEnumMacro(Strategy, SummaryStrategy)
std::vector< SideSetArray > GetSideSetArrays(vtkStringToken cellType)
Return arrays of cell+side IDs for the given cellType.
vtkSetEnumMacro(SelectionType, SelectionMode)
Set/get whether the extracted sides should be marked as selectable or whether their originating data ...
virtual void SetSelectionType(int selnType)
This method exists for ParaView to set the selection mode.
void SetStrategyToWinding()
vtkCellGridSidesQuery()=default
~vtkCellGridSidesQuery() override
SideFlags
An enum specifying which side(s) each responder should generate.
vtkSetEnumMacro(Strategy, SummaryStrategy)
Set/get the strategy responders should use to generate entries in Sides from entries in SideCache.
void SetStrategyToBoundary()
static vtkStringToken SelectionModeToLabel(SelectionMode mode)
Return a string-token with the given selection mode or vice-versa.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
SummaryStrategy
An enum specifying the strategy by which input hashes are summarized into output Sides entries.
@ Winding
The number of hash entries for a given side should be used to decide whether to include a hash's side...
@ AnyOccurrence
If a hash entry entry exists, a single side should be included in the output.
std::unordered_map< vtkStringToken, std::unordered_map< vtkStringToken, std::unordered_map< vtkIdType, std::set< int > > > > Sides
static SelectionMode SelectionModeFromLabel(vtkStringToken token)
bool Initialize() override
Override this if your query-result state requires initialization.
static vtkCellGridSidesQuery * New()
virtual void SetStrategy(int strategy)
This method exists for ParaView to set the strategy.
std::unordered_map< vtkStringToken, std::unordered_map< vtkStringToken, std::unordered_map< vtkIdType, std::set< int > > > > & GetSides()
bool IsAnotherPassRequired() override
Override this if your query allows responders to execute in multiple phases.
void SetStrategyToAnyOccurrence()
static vtkStringToken SummaryStrategyToLabel(SummaryStrategy strategy)
Return a string-token with the given summarization strategy or vice-versa.
SelectionMode
Indicate how output should be generated or marked so selection works as expected.
@ Input
Input shapes should be selected when output sides are picked.
bool Finalize() override
Override this if your query-result state requires finalization.
static SummaryStrategy SummaryStrategyFromLabel(vtkStringToken token)
virtual void SetSideCache(vtkCellGridSidesCache *cache)
void StartPass() override
Mark the start of a pass through each cell type.
vtkGetEnumMacro(SelectionType, SelectionMode)
dynamic, self-adjusting array of vtkIdType
a simple class to control print indentation
Hold a reference to a vtkObjectBase instance.
Represent a string by its integer hash.
A structure created by the GetSideSetArrays() method for responders to use.
vtkStringToken CellType
The type of parent cell which created the sides.
vtkSmartPointer< vtkIdTypeArray > Sides
An array of tuples of (cell-id, side-id) specifying sides.
vtkStringToken SideShape
The shape of all the sides in the Sides array.
@ Sides
A side specified by a cell ID and an integer index into sides.