CartoType C++ API 8.8-7-gb35e4dc71
for Windows, Linux, Qt and other platforms supporting C++ development
Public Member Functions | List of all members
CartoTypeCore::Transform3D Class Reference

#include <cartotype_transform.h>

Public Member Functions

 Transform3D (const AffineTransform &aTransform)
 
bool operator== (const Transform3D &aOther) const
 
void Transform (Point3FP &aPoint) const
 
void Transform (double &aX, double &aY, double &aZ, double &aW) const
 
void Concat (const Transform3D &aTransform)
 
void Translate (double aX, double aY, double aZ)
 
void Scale (double aXScale, double aYScale, double aZScale)
 
void RotateX (double aAngle)
 
void RotateY (double aAngle)
 
void RotateZ (double aAngle)
 
void ReflectY (double aY)
 
void Invert ()
 
double Determinant () const
 
Result Perspective (double aFieldOfViewYDegrees, double aAspect, double aNear, double aFar)
 
Result Frustum (double aLeft, double aRight, double aBottom, double aTop, double aNear, double aFar)
 
AffineTransform Affine2DTransform () const
 
const double * Data () const
 

Detailed Description

A 3D transformation.

Constructor & Destructor Documentation

◆ Transform3D()

CartoTypeCore::Transform3D::Transform3D ( const AffineTransform aTransform)

Creates a TTransform3FP object from a 2D transform.

Member Function Documentation

◆ Affine2DTransform()

AffineTransform CartoTypeCore::Transform3D::Affine2DTransform ( ) const

Returns an affine 2D transform derived from the affine 2D part of this transform.

◆ Concat()

void CartoTypeCore::Transform3D::Concat ( const Transform3D aTransform)

Concatenates aTransform to this transform.

◆ Data()

const double * CartoTypeCore::Transform3D::Data ( ) const
inline

Returns a pointer to the contiguous array of 16 values representing the 4x4 transformation matrix.

◆ Determinant()

double CartoTypeCore::Transform3D::Determinant ( ) const

Returns the determinant of the transform's 4x4 matrix.

◆ Frustum()

Result CartoTypeCore::Transform3D::Frustum ( double  aLeft,
double  aRight,
double  aBottom,
double  aTop,
double  aNear,
double  aFar 
)

Concatenates a perspective transformation defined by a frustum to this transform.

◆ Invert()

void CartoTypeCore::Transform3D::Invert ( )

Inverts this transform. If the transform cannot be inverted throws KErrorNoInverse.

◆ operator==()

bool CartoTypeCore::Transform3D::operator== ( const Transform3D aOther) const
inline

The equality operator.

◆ Perspective()

Result CartoTypeCore::Transform3D::Perspective ( double  aFieldOfViewYDegrees,
double  aAspect,
double  aNear,
double  aFar 
)

Concatenates a perspective transformation to this transform.

aFieldOfViewYDegrees is the vertical angle of the field of view: that is, the angle between the top and bottom planes of the view frustum.

aAspect is the ratio between the width and height of the screen and is calculated as width / height.

aNear is the distance from the eye to the near plane of the view frustum.

aFar is the distance from the eye to the far plane of the view frustum.

◆ ReflectY()

void CartoTypeCore::Transform3D::ReflectY ( double  aY)

Reflect the transform around the plane Y == aY.

◆ RotateX()

void CartoTypeCore::Transform3D::RotateX ( double  aAngle)

Rotate the transform around the X axis.

◆ RotateY()

void CartoTypeCore::Transform3D::RotateY ( double  aAngle)

Rotate the transform around the Y axis.

◆ RotateZ()

void CartoTypeCore::Transform3D::RotateZ ( double  aAngle)

Rotate the transform around the Z axis.

◆ Scale()

void CartoTypeCore::Transform3D::Scale ( double  aXScale,
double  aYScale,
double  aZScale 
)

Scale a transform by aXScale, aYScale and aZScale. Do nothing if either XScale, YScale or aZScale is 0, which creates a non-invertible matrix.

◆ Transform() [1/2]

void CartoTypeCore::Transform3D::Transform ( double &  aX,
double &  aY,
double &  aZ,
double &  aW 
) const

Transforms a point given in projective coordinates.

◆ Transform() [2/2]

void CartoTypeCore::Transform3D::Transform ( Point3FP aPoint) const

Transforms a 3D point in place.

◆ Translate()

void CartoTypeCore::Transform3D::Translate ( double  aX,
double  aY,
double  aZ 
)

Concatenates the translation (aX,aY,aZ) to this transform.


The documentation for this class was generated from the following files: