diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2012-06-25 12:01:46 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-06-29 02:21:36 +0200 |
commit | 5df94d89033e7bbb3f41840a4c07a628ed66b4d5 (patch) | |
tree | e42bcd16d8f5f3a192c48794b610ffeb05b9dc02 /examples/particles/customparticle/fragmentshader.qml | |
parent | 2241d6fa2d39fe890ba0d17ff58b5e0615c1cd7b (diff) |
Rename speed -> velocity in the particle system
Matches the convention set in the QtQuick module, for example by
ListView and Flickable.
Change-Id: I8df57ed1ced8128723d790c30c00cc1b2062787d
Reviewed-by: Bea Lam <bea.lam@nokia.com>
Diffstat (limited to 'examples/particles/customparticle/fragmentshader.qml')
-rw-r--r-- | examples/particles/customparticle/fragmentshader.qml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/particles/customparticle/fragmentshader.qml b/examples/particles/customparticle/fragmentshader.qml index 34acb1bd7c..367cc99b7b 100644 --- a/examples/particles/customparticle/fragmentshader.qml +++ b/examples/particles/customparticle/fragmentshader.qml @@ -63,7 +63,7 @@ ParticleSystem { lifeSpan: 8000 size: 24 sizeVariation: 16 - speed: PointDirection {x: root.width/10; y: root.height/10;} + velocity: PointDirection {x: root.width/10; y: root.height/10;} //acceleration: AngledDirection {angle:225; magnitude: root.width/36; angleVariation: 45; magnitudeVariation: 80} acceleration: PointDirection {x: -root.width/40; y: -root.height/40; xVariation: -root.width/20; yVariation: -root.width/20} } @@ -88,7 +88,7 @@ ParticleSystem { highp vec2 pos = qt_ParticlePos - currentSize / 2. + currentSize * qt_ParticleTex // adjust size - + qt_ParticleVec.xy * t * qt_ParticleData.y // apply speed vector.. + + qt_ParticleVec.xy * t * qt_ParticleData.y // apply velocity vector.. + 0.5 * qt_ParticleVec.zw * pow(t * qt_ParticleData.y, 2.); gl_Position = qt_Matrix * vec4(pos.x, pos.y, 0, 1); |