QAbstractCameraController¶
The
QAbstractCameraController
class provides basic functionality for camera controllers. More…
Inherited by: QFirstPersonCameraController, QOrbitCameraController
New in version 5.10.
Synopsis¶
Functions¶
def
acceleration
()def
camera
()def
deceleration
()def
keyboardDevice
()def
linearSpeed
()def
lookSpeed
()def
mouseDevice
()def
setAcceleration
(acceleration)def
setCamera
(camera)def
setDeceleration
(deceleration)def
setLinearSpeed
(linearSpeed)def
setLookSpeed
(lookSpeed)
Signals¶
def
accelerationChanged
(acceleration)def
cameraChanged
()def
decelerationChanged
(deceleration)def
linearSpeedChanged
()def
lookSpeedChanged
()
Detailed Description¶
QAbstractCameraController
sets up and handles input from keyboard, mouse, and other devices.QAbstractCameraController
is an abstract class and cannot itself be instantiated. It provides a standard interface for camera controllers.Derived classes need only implement the frameActionTriggered() method to move the camera.
- class PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController([parent=None])¶
- Parameters:
parent –
PySide2.Qt3DCore.Qt3DCore.QNode
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.acceleration()¶
- Return type:
float
Holds the current acceleration of the camera controller.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.accelerationChanged(acceleration)¶
- Parameters:
acceleration – float
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.camera()¶
- Return type:
Holds the currently controlled camera.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.cameraChanged()¶
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.deceleration()¶
- Return type:
float
Holds the current deceleration of the camera controller.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.decelerationChanged(deceleration)¶
- Parameters:
deceleration – float
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.keyboardDevice()¶
- Return type:
Provides access to the keyboard device.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.linearSpeed()¶
- Return type:
float
Holds the current linear speed of the camera controller. Linear speed determines the movement speed of the camera.
The default is
10.0
.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.linearSpeedChanged()¶
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.lookSpeed()¶
- Return type:
float
Holds the current look speed of the camera controller. The look speed determines the turn rate of the camera pan and tilt.
The default is
180.0
.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.lookSpeedChanged()¶
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.mouseDevice()¶
- Return type:
Provides access to the mouse device.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.setAcceleration(acceleration)¶
- Parameters:
acceleration – float
Holds the current acceleration of the camera controller.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.setCamera(camera)¶
- Parameters:
Holds the currently controlled camera.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.setDeceleration(deceleration)¶
- Parameters:
deceleration – float
Holds the current deceleration of the camera controller.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.setLinearSpeed(linearSpeed)¶
- Parameters:
linearSpeed – float
Holds the current linear speed of the camera controller. Linear speed determines the movement speed of the camera.
The default is
10.0
.
- PySide2.Qt3DExtras.Qt3DExtras.QAbstractCameraController.setLookSpeed(lookSpeed)¶
- Parameters:
lookSpeed – float
Holds the current look speed of the camera controller. The look speed determines the turn rate of the camera pan and tilt.
The default is
180.0
.
© 2022 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.