VTK  9.6.20260202
vtkExtentSplitter.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
16
17#ifndef vtkExtentSplitter_h
18#define vtkExtentSplitter_h
19
20#include "vtkCommonExecutionModelModule.h" // For export macro
21#include "vtkObject.h"
22
23VTK_ABI_NAMESPACE_BEGIN
24class vtkExtentSplitterInternals;
25
26class VTKCOMMONEXECUTIONMODEL_EXPORT vtkExtentSplitter : public vtkObject
27{
28public:
30 void PrintSelf(ostream& os, vtkIndent indent) override;
32
34
39 void AddExtentSource(int id, int priority, int x0, int x1, int y0, int y1, int z0, int z1);
40 void AddExtentSource(int id, int priority, int* extent);
41 void RemoveExtentSource(int id);
44
46
50 void AddExtent(int x0, int x1, int y0, int y1, int z0, int z1);
51 void AddExtent(int* extent);
53
61
68
70
76 int* GetSubExtent(int index) VTK_SIZEHINT(6);
77 void GetSubExtent(int index, int* extent);
79
85 int GetSubExtentSource(int index);
86
88
95 vtkGetMacro(PointMode, vtkTypeBool);
96 vtkSetMacro(PointMode, vtkTypeBool);
97 vtkBooleanMacro(PointMode, vtkTypeBool);
99
100protected:
103
104 // Internal utility methods.
105 void SplitExtent(int* extent, int* subextent);
106 int IntersectExtents(const int* extent1, const int* extent2, int* result);
107
108 // Internal implementation data.
109 vtkExtentSplitterInternals* Internal;
110
111 // On if reading only all points (but not always all cells) is
112 // necessary. Used for reading volumes of planar slices storing
113 // only point data.
115
116private:
117 vtkExtentSplitter(const vtkExtentSplitter&) = delete;
118 void operator=(const vtkExtentSplitter&) = delete;
119};
120
121VTK_ABI_NAMESPACE_END
122#endif
~vtkExtentSplitter() override
vtkExtentSplitterInternals * Internal
void RemoveExtentSource(int id)
Add/Remove a source providing the given extent.
void SplitExtent(int *extent, int *subextent)
void AddExtent(int *extent)
Add an extent to the queue of extents to be split among the available sources.
int * GetSubExtent(int index)
Get the sub-extent associated with the given index.
int ComputeSubExtents()
Split the extents currently in the queue among the available sources.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void AddExtent(int x0, int x1, int y0, int y1, int z0, int z1)
Add an extent to the queue of extents to be split among the available sources.
void AddExtentSource(int id, int priority, int x0, int x1, int y0, int y1, int z0, int z1)
Add/Remove a source providing the given extent.
void AddExtentSource(int id, int priority, int *extent)
Add/Remove a source providing the given extent.
int GetSubExtentSource(int index)
Get the id of the source from which the sub-extent associated with the given index should be read.
int IntersectExtents(const int *extent1, const int *extent2, int *result)
void GetSubExtent(int index, int *extent)
Get the sub-extent associated with the given index.
int GetNumberOfSubExtents()
Get the number of sub-extents into which the original set of extents have been split across the avail...
void RemoveAllExtentSources()
Add/Remove a source providing the given extent.
static vtkExtentSplitter * New()
a simple class to control print indentation
Definition vtkIndent.h:108
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_SIZEHINT(...)