149 #ifndef vtkTransform_h
150 #define vtkTransform_h
152 #include "vtkCommonTransformsModule.h"
157 VTK_ABI_NAMESPACE_BEGIN
184 void Translate(
double x,
double y,
double z) { this->Concatenation->Translate(x, y, z); }
198 this->Concatenation->Rotate(angle, x, y, z);
202 this->RotateWXYZ(angle, axis[0], axis[1], axis[2]);
206 this->RotateWXYZ(angle, axis[0], axis[1], axis[2]);
216 void RotateX(
double angle) { this->RotateWXYZ(angle, 1, 0, 0); }
217 void RotateY(
double angle) { this->RotateWXYZ(angle, 0, 1, 0); }
218 void RotateZ(
double angle) { this->RotateWXYZ(angle, 0, 0, 1); }
227 void Scale(
double x,
double y,
double z) { this->Concatenation->Scale(x, y, z); }
228 void Scale(
const double s[3]) { this->
Scale(s[0], s[1], s[2]); }
229 void Scale(
const float s[3]) { this->
Scale(s[0], s[1], s[2]); }
240 this->Concatenation->Identity();
241 this->Concatenate(elements);
251 void Concatenate(
const double elements[16]) { this->Concatenation->Concatenate(elements); }
272 if (this->Concatenation->GetPreMultiplyFlag())
276 this->Concatenation->SetPreMultiplyFlag(1);
289 if (!this->Concatenation->GetPreMultiplyFlag())
293 this->Concatenation->SetPreMultiplyFlag(0);
303 return this->Concatenation->GetNumberOfTransforms() + (this->Input ==
nullptr ? 0 : 1);
317 if (this->Input ==
nullptr)
319 t = this->Concatenation->GetTransform(i);
321 else if (i < this->Concatenation->GetNumberOfPreTransforms())
323 t = this->Concatenation->GetTransform(i);
325 else if (i > this->Concatenation->GetNumberOfPreTransforms())
327 t = this->Concatenation->GetTransform(i - 1);
329 else if (this->GetInverseFlag())
350 this->GetOrientation(temp);
351 orient[0] =
static_cast<float>(temp[0]);
352 orient[1] =
static_cast<float>(temp[1]);
353 orient[2] =
static_cast<float>(temp[2]);
357 this->GetOrientation(this->ReturnValue);
358 return this->ReturnValue;
377 this->GetOrientationWXYZ(temp);
378 wxyz[0] =
static_cast<float>(temp[0]);
379 wxyz[1] =
static_cast<float>(temp[1]);
380 wxyz[2] =
static_cast<float>(temp[2]);
381 wxyz[3] =
static_cast<float>(temp[3]);
385 this->GetOrientationWXYZ(this->ReturnValue);
386 return this->ReturnValue;
400 this->GetPosition(temp);
401 pos[0] =
static_cast<float>(temp[0]);
402 pos[1] =
static_cast<float>(temp[1]);
403 pos[2] =
static_cast<float>(temp[2]);
407 this->GetPosition(this->ReturnValue);
408 return this->ReturnValue;
423 this->GetScale(temp);
424 scale[0] =
static_cast<float>(temp[0]);
425 scale[1] =
static_cast<float>(temp[1]);
426 scale[2] =
static_cast<float>(temp[2]);
430 this->GetScale(this->ReturnValue);
431 return this->ReturnValue;
476 if (this->Stack ==
nullptr)
480 this->Stack->Push(&this->Concatenation);
492 if (this->Stack ==
nullptr)
496 this->Stack->Pop(&this->Concatenation);
555 double DoublePoint[4];
556 double ReturnValue[4];
563 VTK_ABI_NAMESPACE_END
a simple class to control print indentation
represent and manipulate 4x4 transformation matrices
void MultiplyPoint(const float in[4], float out[4])
Multiply a homogeneous coordinate by this matrix, i.e.
double Element[4][4]
The internal data is public for historical reasons. Do not use!
virtual void Modified()
Update the modification time for this object.
vtkTypeUInt32 vtkMTimeType
#define VTK_SIZEHINT(...)