aboutsummaryrefslogtreecommitdiffstats
path: root/src/particles/qquickimageparticle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/particles/qquickimageparticle.cpp')
-rw-r--r--src/particles/qquickimageparticle.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/particles/qquickimageparticle.cpp b/src/particles/qquickimageparticle.cpp
index 8f809176a9..37bf323f42 100644
--- a/src/particles/qquickimageparticle.cpp
+++ b/src/particles/qquickimageparticle.cpp
@@ -1730,9 +1730,9 @@ void QQuickImageParticle::initialize(int gIdx, int pIdx)
if (!datum->rotationOwner)
datum->rotationOwner = this;
rotation =
- (m_rotation + (m_rotationVariation - 2*QRandomGenerator::bounded(m_rotationVariation)) ) * CONV;
+ (m_rotation + (m_rotationVariation - 2*QRandomGenerator::global()->bounded(m_rotationVariation)) ) * CONV;
rotationVelocity =
- (m_rotationVelocity + (m_rotationVelocityVariation - 2*QRandomGenerator::bounded(m_rotationVelocityVariation)) ) * CONV;
+ (m_rotationVelocity + (m_rotationVelocityVariation - 2*QRandomGenerator::global()->bounded(m_rotationVelocityVariation)) ) * CONV;
autoRotate = m_autoRotation?1.0:0.0;
if (datum->rotationOwner == this) {
datum->rotation = rotation;
@@ -1751,10 +1751,10 @@ void QQuickImageParticle::initialize(int gIdx, int pIdx)
if (m_explicitColor) {
if (!datum->colorOwner)
datum->colorOwner = this;
- color.r = m_color.red() * (1 - redVariation) + QRandomGenerator::bounded(256) * redVariation;
- color.g = m_color.green() * (1 - greenVariation) + QRandomGenerator::bounded(256) * greenVariation;
- color.b = m_color.blue() * (1 - blueVariation) + QRandomGenerator::bounded(256) * blueVariation;
- color.a = m_alpha * m_color.alpha() * (1 - m_alphaVariation) + QRandomGenerator::bounded(256) * m_alphaVariation;
+ color.r = m_color.red() * (1 - redVariation) + QRandomGenerator::global()->bounded(256) * redVariation;
+ color.g = m_color.green() * (1 - greenVariation) + QRandomGenerator::global()->bounded(256) * greenVariation;
+ color.b = m_color.blue() * (1 - blueVariation) + QRandomGenerator::global()->bounded(256) * blueVariation;
+ color.a = m_alpha * m_color.alpha() * (1 - m_alphaVariation) + QRandomGenerator::global()->bounded(256) * m_alphaVariation;
if (datum->colorOwner == this)
datum->color = color;
else