CameraController Class | Qt 3D 5.6

Qt 5.6 | Qt 3D | C++ Classes | CameraController

Qt 5.6.2 Reference Documentation

# CameraController Class

(Qt3DInput::Input::CameraController)

Inherits: | QObject

- List of all members, including inherited members

## Public Types

enum | ControlMode { FreeLook, FirstPerson }

## Properties

controlMode : ControlMode firstPersonUpVector : QVector3D linearSpeed : float | lookRate : float multisampleEnabled : const bool orbitRate : float

- 1 property inherited from QObject

## Public Functions

| CameraController(QObject *parent = 0)
Qt3DCore::QCamera * | camera() const
ControlMode | controlMode() const
QVector3D | firstPersonUpVector() const
bool | isMultisampleEnabled() const
bool | keyPressEvent(QKeyEvent *aEvent)
bool | keyReleaseEvent(QKeyEvent *aEvent)
float | linearSpeed() const
float | lookRate() const
void | mouseMoveEvent(QMouseEvent *aEvent)
void | mousePressEvent(QMouseEvent *aEvent)
void | mouseReleaseEvent(QMouseEvent *aEvent)
float | orbitRate() const
void | setCamera(Qt3DCore::QCamera *cam)
void | setControlMode(ControlMode controlMode)
void | setFirstPersonUpVector(const QVector3D &up)
void | setLinearSpeed(float speed)
void | setLookRate(float rate)
void | setOrbitRate(float rate)
void | update(double t)

- 31 public functions inherited from QObject

## Public Slots

void | toggleMSAA()

- 1 public slot inherited from QObject

## Signals

void | controlModeChanged(ControlMode controlMode)
void | firstPersonUpVectorChanged(const QVector3D &up)
void | linearSpeedChanged(float speed)
void | lookRateChanged(float rate)
void | multisampleEnabledChanged(bool enabled)
void | orbitRateChanged(float rate)

- 2 signals inherited from QObject

## Reimplemented Protected Functions

virtual bool | eventFilter(QObject *receiver, QEvent *event)

- 9 protected functions inherited from QObject

### Additional Inherited Members

- 1 public variable inherited from QObject
- 10 static public members inherited from QObject
- 9 protected functions inherited from QObject
- 2 protected variables inherited from QObject

## Member Type Documentation

### enum CameraController::ControlMode

## Property Documentation

### controlMode : ControlMode

Access functions:

ControlMode | controlMode() const
void | setControlMode(ControlMode controlMode)

Notifier signal:

void | controlModeChanged(ControlMode controlMode)

### firstPersonUpVector : QVector3D

Access functions:

QVector3D | firstPersonUpVector() const
void | setFirstPersonUpVector(const QVector3D &up)

Notifier signal:

void | firstPersonUpVectorChanged(const QVector3D &up)

### linearSpeed : float

Access functions:

float | linearSpeed() const
void | setLinearSpeed(float speed)

Notifier signal:

void | linearSpeedChanged(float speed)

### lookRate : float

Access functions:

float | lookRate() const
void | setLookRate(float rate)

Notifier signal:

void | lookRateChanged(float rate)

### multisampleEnabled : const bool

Access functions:

bool | isMultisampleEnabled() const

Notifier signal:

void | multisampleEnabledChanged(bool enabled)

### orbitRate : float

Access functions:

float | orbitRate() const
void | setOrbitRate(float rate)

Notifier signal:

void | orbitRateChanged(float rate)

## Member Function Documentation

### CameraController::CameraController(QObject *parent = 0)

Default constructs an instance of CameraController.

### Qt3DCore::QCamera *CameraController::camera() const

See also setCamera().

### `[virtual protected]` bool CameraController::eventFilter(QObject *receiver, QEvent *event)

### bool CameraController::keyPressEvent(QKeyEvent *aEvent)

### bool CameraController::keyReleaseEvent(QKeyEvent *aEvent)

### void CameraController::mouseMoveEvent(QMouseEvent *aEvent)

### void CameraController::mousePressEvent(QMouseEvent *aEvent)

### void CameraController::mouseReleaseEvent(QMouseEvent *aEvent)

### void CameraController::setCamera(Qt3DCore::QCamera *cam)

See also camera().

### `[slot]` void CameraController::toggleMSAA()

### void CameraController::update(double t)