QCameraLens Class

(Qt3D::QCameraLens)

Qt3D::QCameraLens specifies the projection matrix that will be used to define a Camera for a 3D scene. More...

Header: #include <QCameraLens>
qmake: QT += 3dcore
Since: Qt 5.5
Instantiated By: CameraLens
Inherits: QComponent

Public Types

enum ProjectionType { OrthogonalProjection, PerspectiveProjection, FrustumProjection }

Properties

Public Functions

QCameraLens(QNode * parent = 0)
~QCameraLens()
float aspectRatio() const
float bottom() const
float farPlane() const
float fieldOfView() const
float left() const
float nearPlane() const
QMatrix4x4 projectionMatrix() const
ProjectionType projectionType() const
float right() const
void setAspectRatio(float aspectRatio)
void setBottom(float bottom)
void setFarPlane(float farPlane)
void setFieldOfView(float fieldOfView)
void setFrustumProjection(float left, float right, float bottom, float top, float nearPlane, float farPlane)
void setLeft(float left)
void setNearPlane(float nearPlane)
void setOrthographicProjection(float left, float right, float bottom, float top, float nearPlane, float farPlane)
void setPerspectiveProjection(float fieldOfView, float aspectRatio, float nearPlane, float farPlane)
void setProjectionType(ProjectionType projectionType)
void setRight(float right)
void setTop(float top)
float top() const

Signals

Protected Functions

QCameraLens(QCameraLensPrivate & dd, QNode * parent = 0)

Reimplemented Protected Functions

virtual void copy(const QNode * ref)

Additional Inherited Members

Detailed Description

Qt3D::QCameraLens specifies the projection matrix that will be used to define a Camera for a 3D scene.

Member Type Documentation

enum QCameraLens::ProjectionType

Property Documentation

aspectRatio : float

Access functions:

float aspectRatio() const
void setAspectRatio(float aspectRatio)

Notifier signal:

void aspectRatioChanged()

bottom : float

Access functions:

float bottom() const
void setBottom(float bottom)

Notifier signal:

void bottomChanged()

farPlane : float

Access functions:

float farPlane() const
void setFarPlane(float farPlane)

Notifier signal:

void farPlaneChanged()

fieldOfView : float

Access functions:

float fieldOfView() const
void setFieldOfView(float fieldOfView)

Notifier signal:

void fieldOfViewChanged()

left : float

Access functions:

float left() const
void setLeft(float left)

Notifier signal:

void leftChanged()

nearPlane : float

Access functions:

float nearPlane() const
void setNearPlane(float nearPlane)

Notifier signal:

void nearPlaneChanged()

projectionMatrix : const QMatrix4x4

Access functions:

QMatrix4x4 projectionMatrix() const

Notifier signal:

void projectionMatrixChanged()

projectionType : ProjectionType

Access functions:

ProjectionType projectionType() const
void setProjectionType(ProjectionType projectionType)

Notifier signal:

void projectionTypeChanged()

right : float

Access functions:

float right() const
void setRight(float right)

Notifier signal:

void rightChanged()

top : float

Access functions:

float top() const
void setTop(float top)

Notifier signal:

void topChanged()

Member Function Documentation

QCameraLens::QCameraLens(QNode * parent = 0)

[protected] QCameraLens::QCameraLens(QCameraLensPrivate & dd, QNode * parent = 0)

QCameraLens::~QCameraLens()

[virtual protected] void QCameraLens::copy(const QNode * ref)

void QCameraLens::setFrustumProjection(float left, float right, float bottom, float top, float nearPlane, float farPlane)

Defines an orthographic projection based on left, right, bottom, top, nearPlane, farPlane.

void QCameraLens::setOrthographicProjection(float left, float right, float bottom, float top, float nearPlane, float farPlane)

Defines an orthographic projection based on left, right, bottom, top, nearPlane, farPlane.

void QCameraLens::setPerspectiveProjection(float fieldOfView, float aspectRatio, float nearPlane, float farPlane)

Defines a perspective projection based on fieldOfView, aspectRatio, nearPlane, farPlane.