28 #ifndef vtkStructuredExtent_h
29 #define vtkStructuredExtent_h
42 static void Clamp(
int ext[6],
const int wholeExt[]);
46 static bool StrictlySmaller(
const int ext[6],
const int wholeExt[6]);
50 static bool Smaller(
const int ext[6],
const int wholeExt[6]);
53 static void Grow(
int ext[6],
int count);
56 static void Transform(
int ext[6],
int wholeExt[6]);
59 static void GetDimensions(
const int ext[6],
int dims[3]);
75 ext[0] = (ext[0] < wholeExt[0])? wholeExt[0] : ext[0];
76 ext[1] = (ext[1] > wholeExt[1])? wholeExt[1] : ext[1];
78 ext[2] = (ext[2] < wholeExt[2])? wholeExt[2] : ext[2];
79 ext[3] = (ext[3] > wholeExt[3])? wholeExt[3] : ext[3];
81 ext[4] = (ext[4] < wholeExt[4])? wholeExt[4] : ext[4];
82 ext[5] = (ext[5] > wholeExt[5])? wholeExt[5] : ext[5];
88 if (ext[0] < wholeExt[0] || ext[0] > wholeExt[0 + 1] ||
89 ext[0 + 1] < wholeExt[0] || ext[0 + 1] > wholeExt[0 + 1])
94 if (ext[2] < wholeExt[2] || ext[2] > wholeExt[2 + 1] ||
95 ext[2 + 1] < wholeExt[2] || ext[2 + 1] > wholeExt[2 + 1])
100 if (ext[4] < wholeExt[4] || ext[4] > wholeExt[4 + 1] ||
101 ext[4 + 1] < wholeExt[4] || ext[4 + 1] > wholeExt[4 + 1])
117 if (ext[0] > wholeExt[0] || ext[1] < wholeExt[1] ||
118 ext[2] > wholeExt[2] || ext[3] < wholeExt[3] ||
119 ext[4] > wholeExt[4] || ext[5] < wholeExt[5])
143 ext[0] -= wholeExt[0];
144 ext[1] -= wholeExt[0];
146 ext[2] -= wholeExt[2];
147 ext[3] -= wholeExt[2];
149 ext[4] -= wholeExt[4];
150 ext[5] -= wholeExt[4];
156 dims[0] = ext[1]-ext[0] + 1;
157 dims[1] = ext[3]-ext[2] + 1;
158 dims[2] = ext[5]-ext[4] + 1;
static void GetDimensions(const int ext[6], int dims[3])
abstract base class for most VTK objects
static bool Smaller(const int ext[6], const int wholeExt[6])
static void Grow(int ext[6], int count)
static void Clamp(int ext[6], const int wholeExt[])
virtual void PrintSelf(ostream &os, vtkIndent indent)
a simple class to control print indentation
static bool StrictlySmaller(const int ext[6], const int wholeExt[6])
helper class to aid working with structured extents.
#define VTKCOMMONDATAMODEL_EXPORT
static void Transform(int ext[6], int wholeExt[6])