![]() |
Qt 6.x
The Qt SDK
|
#include <qrigidbody_p.h>
Public Types | |
enum class | MassMode { DefaultDensity , CustomDensity , Mass , MassAndInertiaTensor , MassAndInertiaMatrix } |
enum | AxisLock { LockNone = 0 , LockX = 1 , LockY = 2 , LockZ = 4 } |
![]() | |
enum | TransformSpace { LocalSpace , ParentSpace , SceneSpace } |
enum | StaticFlags { None } |
Public Member Functions | |
QDynamicRigidBody () | |
\qmltype DynamicRigidBody \inqmlmodule QtQuick3D.Physics \inherits PhysicsBody | |
~QDynamicRigidBody () | |
float | mass () const |
void | setMass (float mass) |
float | density () const |
void | setDensity (float density) |
bool | isKinematic () const |
void | setIsKinematic (bool isKinematic) |
Q_REVISION (6, 5) AxisLock linearAxisLock() const | |
Q_REVISION (6, 5) void setLinearAxisLock(AxisLock new AxisLockLinear) | |
Q_REVISION (6, 5) AxisLock angularAxisLock() const | |
Q_REVISION (6, 5) void setAngularAxisLock(AxisLock new AxisLockAngular) | |
bool | gravityEnabled () const |
void | setGravityEnabled (bool gravityEnabled) |
Q_INVOKABLE void | applyCentralForce (const QVector3D &force) |
Q_INVOKABLE void | applyForce (const QVector3D &force, const QVector3D &position) |
Q_INVOKABLE void | applyTorque (const QVector3D &torque) |
Q_INVOKABLE void | applyCentralImpulse (const QVector3D &impulse) |
Q_INVOKABLE void | applyImpulse (const QVector3D &impulse, const QVector3D &position) |
Q_INVOKABLE void | applyTorqueImpulse (const QVector3D &impulse) |
Q_INVOKABLE void | setAngularVelocity (const QVector3D &angularVelocity) |
Q_INVOKABLE void | setLinearVelocity (const QVector3D &linearVelocity) |
Q_INVOKABLE void | reset (const QVector3D &position, const QVector3D &eulerRotation) |
QQueue< QPhysicsCommand * > & | commandQueue () |
void | updateDefaultDensity (float defaultDensity) |
MassMode | massMode () const |
void | setMassMode (const MassMode newMassMode) |
const QVector3D & | inertiaTensor () const |
void | setInertiaTensor (const QVector3D &newInertiaTensor) |
const QVector3D & | centerOfMassPosition () const |
void | setCenterOfMassPosition (const QVector3D &newCenterOfMassPosition) |
const QQuaternion & | centerOfMassRotation () const |
void | setCenterOfMassRotation (const QQuaternion &newCenterOfMassRotation) |
const QList< float > & | readInertiaMatrix () const |
void | setInertiaMatrix (const QList< float > &newInertiaMatrix) |
const QMatrix3x3 & | inertiaMatrix () const |
Q_REVISION (6, 5) void setKinematicPosition(const QVector3D &position) | |
Q_REVISION (6, 5) QVector3D kinematicPosition() const | |
Q_REVISION (6, 5) void setKinematicRotation(const QQuaternion &rotation) | |
Q_REVISION (6, 5) QQuaternion kinematicRotation() const | |
Q_REVISION (6, 5) void setKinematicEulerRotation(const QVector3D &rotation) | |
Q_REVISION (6, 5) QVector3D kinematicEulerRotation() const | |
Q_REVISION (6, 5) void setKinematicPivot(const QVector3D &pivot) | |
Q_REVISION (6, 5) QVector3D kinematicPivot() const | |
![]() | |
QAbstractPhysicsBody () | |
\qmltype PhysicsBody \inherits PhysicsNode \inqmlmodule QtQuick3D.Physics | |
QPhysicsMaterial * | physicsMaterial () const |
void | setPhysicsMaterial (QPhysicsMaterial *newPhysicsMaterial) |
![]() | |
QAbstractPhysicsNode () | |
\qmltype PhysicsNode \inherits Node \inqmlmodule QtQuick3D.Physics | |
~QAbstractPhysicsNode () override | |
QQmlListProperty< QAbstractCollisionShape > | collisionShapes () |
const QVector< QAbstractCollisionShape * > & | getCollisionShapesList () const |
void | updateFromPhysicsTransform (const physx::PxTransform &transform) |
void | registerContact (QAbstractPhysicsNode *body, const QVector< QVector3D > &positions, const QVector< QVector3D > &impulses, const QVector< QVector3D > &normals) |
bool | sendContactReports () const |
void | setSendContactReports (bool sendContactReports) |
bool | receiveContactReports () const |
void | setReceiveContactReports (bool receiveContactReports) |
Q_REVISION (6, 5) bool sendTriggerReports() const | |
Q_REVISION (6, 5) void setSendTriggerReports(bool sendTriggerReports) | |
Q_REVISION (6, 5) bool receiveTriggerReports() const | |
Q_REVISION (6, 5) void setReceiveTriggerReports(bool receiveTriggerReports) | |
bool | hasStaticShapes () const |
![]() | |
QQuick3DNode (QQuick3DNode *parent=nullptr) | |
\qmltype Node \inherits Object3D \inqmlmodule QtQuick3D | |
~QQuick3DNode () override | |
float | x () const |
\qmlproperty real QtQuick3D::Node::x | |
float | y () const |
\qmlproperty real QtQuick3D::Node::y | |
float | z () const |
\qmlproperty real QtQuick3D::Node::z | |
QQuaternion | rotation () const |
\qmlproperty quaternion QtQuick3D::Node::rotation | |
QVector3D | eulerRotation () const |
\qmlproperty vector3d QtQuick3D::Node::eulerRotation | |
QVector3D | position () const |
\qmlproperty vector3d QtQuick3D::Node::position | |
QVector3D | scale () const |
\qmlproperty vector3d QtQuick3D::Node::scale | |
QVector3D | pivot () const |
\qmlproperty vector3d QtQuick3D::Node::pivot | |
float | localOpacity () const |
\qmlproperty real QtQuick3D::Node::opacity | |
bool | visible () const |
\qmlproperty bool QtQuick3D::Node::visible | |
int | staticFlags () const |
\qmlproperty int QtQuick3D::Node::staticFlags | |
QQuick3DNode * | parentNode () const |
QVector3D | forward () const |
\qmlproperty vector3d QtQuick3D::Node::forward \readonly | |
QVector3D | up () const |
\qmlproperty vector3d QtQuick3D::Node::up \readonly | |
QVector3D | right () const |
\qmlproperty vector3d QtQuick3D::Node::right \readonly | |
QVector3D | scenePosition () const |
\qmlproperty vector3d QtQuick3D::Node::scenePosition \readonly | |
QQuaternion | sceneRotation () const |
\qmlproperty quaternion QtQuick3D::Node::sceneRotation \readonly | |
QVector3D | sceneScale () const |
\qmlproperty vector3d QtQuick3D::Node::sceneScale \readonly | |
QMatrix4x4 | sceneTransform () const |
\qmlproperty matrix4x4 QtQuick3D::Node::sceneTransform \readonly | |
Q_INVOKABLE void | rotate (qreal degrees, const QVector3D &axis, QQuick3DNode::TransformSpace space) |
\qmlmethod QtQuick3D::Node::rotate(real degrees, vector3d axis, enumeration space) | |
Q_INVOKABLE QVector3D | mapPositionToScene (const QVector3D &localPosition) const |
\qmlmethod vector3d QtQuick3D::Node::mapPositionToScene(vector3d localPosition) | |
Q_INVOKABLE QVector3D | mapPositionFromScene (const QVector3D &scenePosition) const |
\qmlmethod vector3d QtQuick3D::Node::mapPositionFromScene(vector3d scenePosition) | |
Q_INVOKABLE QVector3D | mapPositionToNode (const QQuick3DNode *node, const QVector3D &localPosition) const |
\qmlmethod vector3d QtQuick3D::Node::mapPositionToNode(QtQuick3D::Node node, vector3d localPosition) | |
Q_INVOKABLE QVector3D | mapPositionFromNode (const QQuick3DNode *node, const QVector3D &localPosition) const |
\qmlmethod vector3d QtQuick3D::Node::mapPositionFromNode(QtQuick3D::Node node, vector3d localPosition) | |
Q_INVOKABLE QVector3D | mapDirectionToScene (const QVector3D &localDirection) const |
\qmlmethod vector3d QtQuick3D::Node::mapDirectionToScene(vector3d localDirection) | |
Q_INVOKABLE QVector3D | mapDirectionFromScene (const QVector3D &sceneDirection) const |
\qmlmethod vector3d QtQuick3D::Node::mapDirectionFromScene(vector3d sceneDirection) | |
Q_INVOKABLE QVector3D | mapDirectionToNode (const QQuick3DNode *node, const QVector3D &localDirection) const |
\qmlmethod vector3d QtQuick3D::Node::mapDirectionToNode(QtQuick3D::Node node, vector3d localDirection) | |
Q_INVOKABLE QVector3D | mapDirectionFromNode (const QQuick3DNode *node, const QVector3D &localDirection) const |
\qmlmethod vector3d QtQuick3D::Node::mapDirectionFromNode(QtQuick3D::Node node, vector3d localDirection) | |
void | markAllDirty () override |
![]() | |
Q_INVOKABLE | QObject (QObject *parent=nullptr) |
Constructs an object with parent object parent. | |
virtual | ~QObject () |
Destroys the object, deleting all its child objects. | |
virtual bool | event (QEvent *event) |
This virtual function receives events to an object and should return true if the event e was recognized and processed. | |
virtual bool | eventFilter (QObject *watched, QEvent *event) |
Filters events if this object has been installed as an event filter for the watched object. | |
QString | objectName () const |
Q_WEAK_OVERLOAD void | setObjectName (const QString &name) |
Sets the object's name to name. | |
void | setObjectName (QAnyStringView name) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
QBindable< QString > | bindableObjectName () |
bool | isWidgetType () const |
Returns true if the object is a widget; otherwise returns false . | |
bool | isWindowType () const |
Returns true if the object is a window; otherwise returns false . | |
bool | isQuickItemType () const |
Returns true if the object is a QQuickItem; otherwise returns false . | |
bool | signalsBlocked () const noexcept |
Returns true if signals are blocked; otherwise returns false . | |
bool | blockSignals (bool b) noexcept |
If block is true, signals emitted by this object are blocked (i.e., emitting a signal will not invoke anything connected to it). | |
QThread * | thread () const |
Returns the thread in which the object lives. | |
void | moveToThread (QThread *thread) |
Changes the thread affinity for this object and its children. | |
int | startTimer (int interval, Qt::TimerType timerType=Qt::CoarseTimer) |
This is an overloaded function that will start a timer of type timerType and a timeout of interval milliseconds. | |
int | startTimer (std::chrono::milliseconds time, Qt::TimerType timerType=Qt::CoarseTimer) |
void | killTimer (int id) |
Kills the timer with timer identifier, id. | |
template<typename T > | |
T | findChild (const QString &aName=QString(), Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
Returns the child of this object that can be cast into type T and that is called name, or \nullptr if there is no such object. | |
template<typename T > | |
QList< T > | findChildren (const QString &aName, Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
Returns all children of this object with the given name that can be cast to type T, or an empty list if there are no such objects. | |
template<typename T > | |
QList< T > | findChildren (Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
const QObjectList & | children () const |
Returns a list of child objects. | |
void | setParent (QObject *parent) |
Makes the object a child of parent. | |
void | installEventFilter (QObject *filterObj) |
Installs an event filter filterObj on this object. | |
void | removeEventFilter (QObject *obj) |
Removes an event filter object obj from this object. | |
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const char *member, Qt::ConnectionType type=Qt::AutoConnection) const |
bool | disconnect (const char *signal=nullptr, const QObject *receiver=nullptr, const char *member=nullptr) const |
bool | disconnect (const QObject *receiver, const char *member=nullptr) const |
void | dumpObjectTree () const |
Dumps a tree of children to the debug output. | |
void | dumpObjectInfo () const |
Dumps information about signal connections, etc. | |
bool | setProperty (const char *name, const QVariant &value) |
Sets the value of the object's name property to value. | |
bool | setProperty (const char *name, QVariant &&value) |
QVariant | property (const char *name) const |
Returns the value of the object's name property. | |
QList< QByteArray > | dynamicPropertyNames () const |
QBindingStorage * | bindingStorage () |
const QBindingStorage * | bindingStorage () const |
QObject * | parent () const |
Returns a pointer to the parent object. | |
bool | inherits (const char *classname) const |
Returns true if this object is an instance of a class that inherits className or a QObject subclass that inherits className; otherwise returns false . | |
![]() | |
QQmlParserStatus () | |
virtual | ~QQmlParserStatus () |
virtual void | classBegin ()=0 |
Invoked after class creation, but before any properties have been set. | |
virtual void | componentComplete ()=0 |
Invoked after the root component that caused this instantiation has completed construction. | |
Additional Inherited Members | |
![]() | |
void | setX (float x) |
void | setY (float y) |
void | setZ (float z) |
void | setRotation (const QQuaternion &rotation) |
void | setEulerRotation (const QVector3D &eulerRotation) |
void | setPosition (const QVector3D &position) |
void | setScale (const QVector3D &scale) |
void | setPivot (const QVector3D &pivot) |
void | setLocalOpacity (float opacity) |
void | setVisible (bool visible) |
void | setStaticFlags (int staticFlags) |
![]() | |
void | update () |
void | setParentItem (QQuick3DObject *parentItem) |
![]() | |
void | deleteLater () |
\threadsafe | |
![]() | |
static QMetaObject::Connection | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *member, Qt::ConnectionType=Qt::AutoConnection) |
\threadsafe | |
static QMetaObject::Connection | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::ContextTypeForFunctor< Func2 >::ContextType *context, Func2 &&slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, Func2 &&slot) |
static bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *member) |
\threadsafe | |
static bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &member) |
static bool | disconnect (const QMetaObject::Connection &) |
Disconnect a connection. | |
template<typename Func1 , typename Func2 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiver, Func2 slot) |
template<typename Func1 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const QObject *receiver, void **zero) |
![]() | |
void | connectNotify (const QMetaMethod &signal) override |
void | disconnectNotify (const QMetaMethod &signal) override |
void | componentComplete () override |
Invoked after the root component that caused this instantiation has completed construction. | |
QQuick3DNode (QQuick3DNodePrivate &dd, QQuick3DNode *parent=nullptr) | |
QSSGRenderGraphObject * | updateSpatialNode (QSSGRenderGraphObject *node) override |
virtual void | itemChange (ItemChange, const ItemChangeData &) override |
![]() | |
virtual QSSGRenderGraphObject * | updateSpatialNode (QSSGRenderGraphObject *node) |
virtual void | markAllDirty () |
virtual void | itemChange (ItemChange, const ItemChangeData &) |
QQuick3DObject (QQuick3DObjectPrivate &dd, QQuick3DObject *parent=nullptr) | |
void | classBegin () override |
Invoked after class creation, but before any properties have been set. | |
void | componentComplete () override |
Invoked after the root component that caused this instantiation has completed construction. | |
bool | isComponentComplete () const |
virtual void | preSync () |
![]() | |
QObject * | sender () const |
Returns a pointer to the object that sent the signal, if called in a slot activated by a signal; otherwise it returns \nullptr. | |
int | senderSignalIndex () const |
int | receivers (const char *signal) const |
Returns the number of receivers connected to the signal. | |
bool | isSignalConnected (const QMetaMethod &signal) const |
virtual void | timerEvent (QTimerEvent *event) |
This event handler can be reimplemented in a subclass to receive timer events for the object. | |
virtual void | childEvent (QChildEvent *event) |
This event handler can be reimplemented in a subclass to receive child events. | |
virtual void | customEvent (QEvent *event) |
This event handler can be reimplemented in a subclass to receive custom events. | |
virtual void | connectNotify (const QMetaMethod &signal) |
virtual void | disconnectNotify (const QMetaMethod &signal) |
QObject (QObjectPrivate &dd, QObject *parent=nullptr) | |
![]() | |
QScopedPointer< QObjectData > | d_ptr |
![]() | |
template< class T > T | qobject_cast (const QObject *object) |
Returns the given object cast to type T if the object is of type T (or of a subclass); otherwise returns \nullptr. | |
template< typename T > T | qFindChildqFindChildren (const QObject *obj, const QString &name)() |
template< typename T > QList< T > | qFindChildrenqFindChildren (const QObject *obj, const QString &name)() |
QObjectList | |
\macro Q_CLASSINFO(Name, Value) | |
Definition at line 28 of file qrigidbody_p.h.
Enumerator | |
---|---|
LockNone | |
LockX | |
LockY | |
LockZ |
Definition at line 40 of file qrigidbody_p.h.
|
strong |
Enumerator | |
---|---|
DefaultDensity | |
CustomDensity | |
Mass | |
MassAndInertiaTensor | |
MassAndInertiaMatrix |
Definition at line 31 of file qrigidbody_p.h.
|
default |
\qmltype DynamicRigidBody \inqmlmodule QtQuick3D.Physics \inherits PhysicsBody
A physical body that can move or be moved.
This type defines a dynamic rigid body: an object that is part of the physics scene and behaves like a physical object with mass and velocity.
false
.\qmlproperty float DynamicRigidBody::mass
This property defines the mass of the body. Note that this is only used when massMode is not {DynamicRigidBody.CustomDensity}
or {DynamicRigidBody.DefaultDensity}
. Also note that a value of 0 is interpreted as infinite mass and that negative numbers are not allowed.
Default value is 1
.
Range: {[0, inf]}
\qmlproperty float DynamicRigidBody::density
This property defines the density of the body. This is only used when massMode is set to {DynamicRigidBody.CustomDensity}
.
Default value is {0.001}.
Range: {(0, inf]}
\qmlproperty AxisLock DynamicRigidBody::linearAxisLock
This property locks the linear velocity of the body along the axes defined by the DynamicRigidBody.AxisLock enum. To lock several axes just bitwise-or their enum values.
Available options:
\value DynamicRigidBody.None No axis lock (default value).
\value DynamicRigidBody.LockX Lock X axis.
\value DynamicRigidBody.LockY Lock Y axis.
\value DynamicRigidBody.LockZ Lock Z axis.
\qmlproperty AxisLock DynamicRigidBody::angularAxisLock
This property locks the angular velocity of the body along the axes defined by the DynamicRigidBody.AxisLock enum. To lock several axes just bitwise-or their enum values.
Available options:
\value DynamicRigidBody.None No axis lock (default value).
\value DynamicRigidBody.LockX Lock X axis.
\value DynamicRigidBody.LockY Lock Y axis.
\value DynamicRigidBody.LockZ Lock Z axis.
\qmlproperty bool DynamicRigidBody::isKinematic This property defines whether the object is kinematic or not. A kinematic object does not get influenced by external forces and can be seen as an object of infinite mass. If this property is set then in every simulation frame the physical object will be moved to its target position regardless of external forces. Note that to move and rotate the kinematic object you need to use the kinematicPosition, kinematicRotation, kinematicEulerRotation and kinematicPivot properties.
\qmlproperty bool DynamicRigidBody::gravityEnabled This property defines whether the object is going to be affected by gravity or not.
\qmlproperty MassMode DynamicRigidBody::massMode
This property holds the enum which describes how mass and inertia are calculated for this body.
By default, DynamicRigidBody.DefaultDensity
is used.
Available options:
\value DynamicRigidBody.DefaultDensity Use the density specified in the \l {PhysicsWorld::}{defaultDensity} property in PhysicsWorld to calculate mass and inertia assuming a uniform density.
\value DynamicRigidBody.CustomDensity Use specified density in the specified in the \l {DynamicRigidBody::}{density} to calculate mass and inertia assuming a uniform density.
\value DynamicRigidBody.Mass Use the specified mass to calculate inertia assuming a uniform density.
\value DynamicRigidBody.MassAndInertiaTensor Use the specified mass value and inertia tensor.
\value DynamicRigidBody.MassAndInertiaMatrix Use the specified mass value and calculate inertia from the specified inertia matrix.
\qmlproperty vector3d DynamicRigidBody::inertiaTensor
Defines the inertia tensor vector, using a parameter specified in mass space coordinates.
This is the diagonal vector of a 3x3 diagonal matrix, if you have a non diagonal world/actor space inertia tensor then you should use \l{DynamicRigidBody::inertiaMatrix}{inertiaMatrix} instead.
The inertia tensor components must be positive and a value of 0 in any component is interpreted as infinite inertia along that axis. Note that this is only used when massMode is set to DynamicRigidBody.MassAndInertiaTensor
.
Default value is (1, 1, 1).
\qmlproperty vector3d DynamicRigidBody::centerOfMassPosition
Defines the position of the center of mass relative to the body. Note that this is only used when massMode is set to DynamicRigidBody.MassAndInertiaTensor
.
\qmlproperty quaternion DynamicRigidBody::centerOfMassRotation
Defines the rotation of the center of mass pose, i.e. it specifies the orientation of the body's principal inertia axes relative to the body. Note that this is only used when massMode is set to DynamicRigidBody.MassAndInertiaTensor
.
\qmlproperty list<float> DynamicRigidBody::inertiaMatrix
Defines the inertia tensor matrix. This is a 3x3 matrix in column-major order. Note that this matrix is expected to be diagonalizable. Note that this is only used when massMode is set to DynamicRigidBody.MassAndInertiaMatrix
.
\qmlproperty vector3d DynamicRigidBody::kinematicPosition
Defines the position of the object when it is kinematic, i.e. when \l isKinematic is set to true
. On each iteration of the simulation the physical object will be updated according to this value.
\qmlproperty vector3d DynamicRigidBody::kinematicRotation
Defines the rotation of the object when it is kinematic, i.e. when \l isKinematic is set to true
. On each iteration of the simulation the physical object will be updated according to this value.
\qmlproperty vector4d DynamicRigidBody::kinematicEulerRotation
Defines the euler rotation of the object when it is kinematic, i.e. when \l isKinematic is set to true
. On each iteration of the simulation the physical object will be updated according to this value.
\qmlproperty vector3d DynamicRigidBody::kinematicPivot
Defines the pivot of the object when it is kinematic, i.e. when \l isKinematic is set to true
. On each iteration of the simulation the physical object will be updated according to this value.
\qmlmethod DynamicRigidBody::applyCentralForce(vector3d force)
Applies a force on the center of the body.
\qmlmethod DynamicRigidBody::applyForce(vector3d force, vector3d position)
Applies a force at a position on the body.
\qmlmethod DynamicRigidBody::applyTorque(vector3d torque)
Applies a torque on the body.
\qmlmethod DynamicRigidBody::applyCentralImpulse(vector3d impulse)
Applies an impulse on the center of the body.
\qmlmethod DynamicRigidBody::applyImpulse(vector3d impulse, vector3d position)
Applies an impulse at a position on the body.
\qmlmethod DynamicRigidBody::applyTorqueImpulse(vector3d impulse)
Applies a torque impulse on the body.
\qmlmethod DynamicRigidBody::setAngularVelocity(vector3d angularVelocity)
Sets the angularVelocity of the body.
\qmlmethod DynamicRigidBody::setLinearVelocity(vector3d linearVelocity)
Sets the linearVelocity of the body.
\qmlmethod DynamicRigidBody::reset(vector3d position, vector3d eulerRotation)
Resets the body's position and eulerRotation.
QDynamicRigidBody::~QDynamicRigidBody | ( | ) |
Definition at line 284 of file qrigidbody.cpp.
References QList< T >::clear(), and qDeleteAll().
Definition at line 559 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
Definition at line 574 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
Definition at line 564 of file qrigidbody.cpp.
References QQueue< T >::enqueue(), and QQuick3DNode::position.
Definition at line 579 of file qrigidbody.cpp.
References QQueue< T >::enqueue(), and QQuick3DNode::position.
Definition at line 569 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
Definition at line 584 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
const QVector3D & QDynamicRigidBody::centerOfMassPosition | ( | ) | const |
Definition at line 308 of file qrigidbody.cpp.
|
signal |
const QQuaternion & QDynamicRigidBody::centerOfMassRotation | ( | ) | const |
Definition at line 290 of file qrigidbody.cpp.
|
signal |
QQueue< QPhysicsCommand * > & QDynamicRigidBody::commandQueue | ( | ) |
Definition at line 548 of file qrigidbody.cpp.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes().
float QDynamicRigidBody::density | ( | ) | const |
Definition at line 474 of file qrigidbody.cpp.
|
signal |
bool QDynamicRigidBody::gravityEnabled | ( | ) | const |
Definition at line 445 of file qrigidbody.cpp.
|
signal |
const QMatrix3x3 & QDynamicRigidBody::inertiaMatrix | ( | ) | const |
Definition at line 430 of file qrigidbody.cpp.
|
signal |
const QVector3D & QDynamicRigidBody::inertiaTensor | ( | ) | const |
Definition at line 379 of file qrigidbody.cpp.
|
signal |
bool QDynamicRigidBody::isKinematic | ( | ) | const |
Definition at line 440 of file qrigidbody.cpp.
|
signal |
float QDynamicRigidBody::mass | ( | ) | const |
Definition at line 435 of file qrigidbody.cpp.
|
signal |
QDynamicRigidBody::MassMode QDynamicRigidBody::massMode | ( | ) | const |
Definition at line 337 of file qrigidbody.cpp.
|
signal |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
new |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const & |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const & |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const & |
QDynamicRigidBody::Q_REVISION | ( | 6 | , |
5 | |||
) | const & |
|
new |
const QList< float > & QDynamicRigidBody::readInertiaMatrix | ( | ) | const |
Definition at line 396 of file qrigidbody.cpp.
Definition at line 594 of file qrigidbody.cpp.
References QQueue< T >::enqueue(), QQuick3DNode::eulerRotation, and QQuick3DNode::position.
Definition at line 517 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
Definition at line 313 of file qrigidbody.cpp.
References centerOfMassPositionChanged(), CustomDensity, DefaultDensity, emit, QQueue< T >::enqueue(), Mass, MassAndInertiaMatrix, MassAndInertiaTensor, and qFuzzyCompare().
void QDynamicRigidBody::setCenterOfMassRotation | ( | const QQuaternion & | newCenterOfMassRotation | ) |
Definition at line 295 of file qrigidbody.cpp.
References centerOfMassRotationChanged(), emit, QQueue< T >::enqueue(), MassAndInertiaTensor, and qFuzzyCompare().
void QDynamicRigidBody::setDensity | ( | float | density | ) |
Definition at line 479 of file qrigidbody.cpp.
References CustomDensity, density, densityChanged(), emit, QQueue< T >::enqueue(), and qFuzzyCompare().
void QDynamicRigidBody::setGravityEnabled | ( | bool | gravityEnabled | ) |
Definition at line 507 of file qrigidbody.cpp.
References emit, QQueue< T >::enqueue(), gravityEnabled, and gravityEnabledChanged().
Definition at line 414 of file qrigidbody.cpp.
References QList< T >::data(), QGenericMatrix< N, M, T >::data(), emit, QQueue< T >::enqueue(), fuzzyEquals(), inertiaMatrixChanged(), QList< T >::length(), MassAndInertiaMatrix, and qMin().
Definition at line 384 of file qrigidbody.cpp.
References emit, QQueue< T >::enqueue(), inertiaTensorChanged(), MassAndInertiaTensor, and qFuzzyCompare().
void QDynamicRigidBody::setIsKinematic | ( | bool | isKinematic | ) |
Definition at line 491 of file qrigidbody.cpp.
References emit, QQueue< T >::enqueue(), QAbstractPhysicsNode::hasStaticShapes(), isKinematic, isKinematicChanged(), and qWarning.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes().
Definition at line 589 of file qrigidbody.cpp.
References QQueue< T >::enqueue().
void QDynamicRigidBody::setMass | ( | float | mass | ) |
Definition at line 450 of file qrigidbody.cpp.
References CustomDensity, DefaultDensity, emit, QQueue< T >::enqueue(), Mass, mass, MassAndInertiaMatrix, MassAndInertiaTensor, massChanged(), and qFuzzyCompare().
Definition at line 342 of file qrigidbody.cpp.
References CustomDensity, DefaultDensity, emit, QQueue< T >::enqueue(), QPhysicsWorld::getWorld(), Mass, MassAndInertiaMatrix, MassAndInertiaTensor, massModeChanged(), qWarning, and world.
void QDynamicRigidBody::updateDefaultDensity | ( | float | defaultDensity | ) |
Definition at line 553 of file qrigidbody.cpp.
References DefaultDensity, and QQueue< T >::enqueue().
Referenced by QPhysXDynamicBody::updateDefaultDensity().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by getLockFlags().
|
read |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysicsCommandSetMassAndInertiaTensor::execute(), and QPhysicsCommandSetMassAndInertiaMatrix::execute().
|
read |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysicsCommandSetMassAndInertiaTensor::execute().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes(), and setDensity().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by setGravityEnabled().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes(), and setIsKinematic().
|
read |
Definition at line 205 of file qrigidbody_p.h.
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by getLockFlags().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes(), and setMass().
|
readwrite |
Definition at line 205 of file qrigidbody_p.h.
Referenced by QPhysXDynamicBody::rebuildDirtyShapes().