13
14
15
16
17
18
31 , m_angularVelocity(0)
32 , m_angularAcceleration(0)
37 int id()
const {
return m_id; }
44 if (state() == QEventPoint::State::Stationary &&
45 !qFuzzyCompare(m_x + 2.0, x + 2.0)) {
46 setState(QEventPoint::State::Updated);
50 float x()
const {
return m_x; }
54 if (state() == QEventPoint::State::Stationary &&
55 !qFuzzyCompare(m_y + 2.0, y + 2.0)) {
56 setState(QEventPoint::State::Updated);
60 float y()
const {
return m_y; }
62 void setVX(
float vx) { m_vx = vx; }
63 float vx()
const {
return m_vx; }
65 void setVY(
float vy) { m_vy = vy; }
66 float vy()
const {
return m_vy; }
71 float angle()
const {
return m_angle; }
75 angle = angle -
M_PI * 2.0;
76 if (state() == QEventPoint::State::Stationary &&
77 !qFuzzyCompare(m_angle + 2.0, angle + 2.0)) {
78 setState(QEventPoint::State::Updated);
89 void setState(
const QEventPoint::State &state) { m_state = state; }
101 float m_angularVelocity;
102 float m_angularAcceleration;
103 QEventPoint::State m_state;
float acceleration() const
void setAcceleration(float acceleration)
QEventPoint::State state() const
void setState(const QEventPoint::State &state)
void setAngularAcceleration(float angularAcceleration)
void setAcceleration(float acceleration)
float angularAcceleration() const
float angularVelocity() const
QEventPoint::State state() const
void setState(const QEventPoint::State &state)
void setAngle(float angle)
void setClassId(int classId)
float acceleration() const
void setAngularVelocity(float angularVelocity)
constexpr float qRadiansToDegrees(float radians)
Q_DECLARE_TYPEINFO(QTuioCursor, Q_RELOCATABLE_TYPE)
Q_DECLARE_TYPEINFO(QTuioToken, Q_RELOCATABLE_TYPE)