48 #ifndef vtkPerspectiveTransform_h
49 #define vtkPerspectiveTransform_h
51 #include "vtkCommonTransformsModule.h"
70 this->Concatenation->Identity();
81 this->Concatenation->Inverse();
93 void AdjustViewport(
double oldXMin,
double oldXMax,
double oldYMin,
double oldYMax,
94 double newXMin,
double newXMax,
double newYMin,
double newYMax);
103 void AdjustZBuffer(
double oldNearZ,
double oldFarZ,
double newNearZ,
double newFarZ);
110 void Ortho(
double xmin,
double xmax,
double ymin,
double ymax,
double znear,
double zfar);
118 void Frustum(
double xmin,
double xmax,
double ymin,
double ymax,
double znear,
double zfar);
126 void Perspective(
double angle,
double aspect,
double znear,
double zfar);
141 void Shear(
double dxdz,
double dydz,
double zplane);
153 void Stereo(
double angle,
double focaldistance);
160 void SetupCamera(
const double position[3],
const double focalpoint[3],
const double viewup[3]);
162 void SetupCamera(
double p0,
double p1,
double p2,
double fp0,
double fp1,
double fp2,
double vup0,
163 double vup1,
double vup2);
170 void Translate(
double x,
double y,
double z) { this->Concatenation->Translate(x, y, z); }
184 this->Concatenation->Rotate(angle, x, y, z);
188 this->RotateWXYZ(angle, axis[0], axis[1], axis[2]);
192 this->RotateWXYZ(angle, axis[0], axis[1], axis[2]);
202 void RotateX(
double angle) { this->RotateWXYZ(angle, 1, 0, 0); }
203 void RotateY(
double angle) { this->RotateWXYZ(angle, 0, 1, 0); }
204 void RotateZ(
double angle) { this->RotateWXYZ(angle, 0, 0, 1); }
213 void Scale(
double x,
double y,
double z) { this->Concatenation->Scale(x, y, z); }
214 void Scale(
const double s[3]) { this->
Scale(s[0], s[1], s[2]); }
215 void Scale(
const float s[3]) { this->
Scale(s[0], s[1], s[2]); }
227 this->Concatenate(elements);
237 void Concatenate(
const double elements[16]) { this->Concatenation->Concatenate(elements); }
258 if (this->Concatenation->GetPreMultiplyFlag())
262 this->Concatenation->SetPreMultiplyFlag(1);
275 if (!this->Concatenation->GetPreMultiplyFlag())
279 this->Concatenation->SetPreMultiplyFlag(0);
289 return this->Concatenation->GetNumberOfTransforms() + (this->Input ==
nullptr ? 0 : 1);
303 if (this->Input ==
nullptr)
305 t = this->Concatenation->GetTransform(i);
307 else if (i < this->Concatenation->GetNumberOfPreTransforms())
309 t = this->Concatenation->GetTransform(i);
311 else if (i > this->Concatenation->GetNumberOfPreTransforms())
313 t = this->Concatenation->GetTransform(i - 1);
315 else if (this->GetInverseFlag())
355 if (this->Stack ==
nullptr)
359 this->Stack->Push(&this->Concatenation);
371 if (this->Stack ==
nullptr)
375 this->Stack->Pop(&this->Concatenation);
represent and manipulate 4x4 transformation matrices
vtkTypeUInt32 vtkMTimeType
a simple class to control print indentation
virtual void Modified()
Update the modification time for this object.
double Element[4][4]
The internal data is public for historical reasons. Do not use!
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...