CameraController Class
(Qt3D::Input::CameraController)Inherits: |
Properties
- linearSpeed : float
- lookRate : float
- multisampleEnabled : const bool
- orbitRate : float
Public Functions
CameraController(QObject * parent = 0) | |
QCamera * | camera() 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(QCamera * cam) |
void | setLinearSpeed(float speed) |
void | setLookRate(float rate) |
void | setOrbitRate(float rate) |
void | update(double t) |
Public Slots
void | toggleMSAA() |
Signals
void | linearSpeedChanged() |
void | lookRateChanged() |
void | multisampleEnabledChanged() |
void | orbitRateChanged() |
Protected Functions
bool | eventFilter(QObject * receiver, QEvent * event) |
Property Documentation
linearSpeed : float
Access functions:
float | linearSpeed() const |
void | setLinearSpeed(float speed) |
Notifier signal:
void | linearSpeedChanged() |
lookRate : float
Access functions:
float | lookRate() const |
void | setLookRate(float rate) |
Notifier signal:
void | lookRateChanged() |
multisampleEnabled : const bool
Access functions:
bool | isMultisampleEnabled() const |
Notifier signal:
void | multisampleEnabledChanged() |
orbitRate : float
Access functions:
float | orbitRate() const |
void | setOrbitRate(float rate) |
Notifier signal:
void | orbitRateChanged() |
Member Function Documentation
CameraController::CameraController(QObject * parent = 0)
QCamera * CameraController::camera() const
See also setCamera().
[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(QCamera * cam)
CameraController expects to find a Camera entity. That means if you have built you Camera yourself using an Entity, a CameraLens and a Transform instead of using the ready made Camera element, it won't work.
See also camera().