1ca5ff54cea62bb267fd411f90ce6f4b43629dfb
[profile/ivi/qtdeclarative.git] / examples / declarative / particles / plasmapatrol / content / PlasmaPatrolParticles.qml
1 /****************************************************************************
2 **
3 ** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
4 ** All rights reserved.
5 ** Contact: http://www.qt-project.org/
6 **
7 ** This file is part of the QtDeclarative module of the Qt Toolkit.
8 **
9 ** $QT_BEGIN_LICENSE:LGPL$
10 ** GNU Lesser General Public License Usage
11 ** This file may be used under the terms of the GNU Lesser General Public
12 ** License version 2.1 as published by the Free Software Foundation and
13 ** appearing in the file LICENSE.LGPL included in the packaging of this
14 ** file. Please review the following information to ensure the GNU Lesser
15 ** General Public License version 2.1 requirements will be met:
16 ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
17 **
18 ** In addition, as a special exception, Nokia gives you certain additional
19 ** rights. These rights are described in the Nokia Qt LGPL Exception
20 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
21 **
22 ** GNU General Public License Usage
23 ** Alternatively, this file may be used under the terms of the GNU General
24 ** Public License version 3.0 as published by the Free Software Foundation
25 ** and appearing in the file LICENSE.GPL included in the packaging of this
26 ** file. Please review the following information to ensure the GNU General
27 ** Public License version 3.0 requirements will be met:
28 ** http://www.gnu.org/copyleft/gpl.html.
29 **
30 ** Other Usage
31 ** Alternatively, this file may be used in accordance with the terms and
32 ** conditions contained in a signed written agreement between you and Nokia.
33 **
34 **
35 **
36 **
37 **
38 ** $QT_END_LICENSE$
39 **
40 ****************************************************************************/
41 import QtQuick 2.0
42 import QtQuick.Particles 2.0
43
44 Item {
45     property ParticleSystem sys
46     ImageParticle {
47         system: sys
48         groups: ["default"]
49         source: "pics/blur-circle3.png"
50         color: "#003A3A3A"
51         colorVariation: 0.1
52         z: 0
53     }
54     ImageParticle {
55         system: sys
56         groups: ["redTeam"]
57         source: "pics/blur-circle3.png"
58         color: "#0028060A"
59         colorVariation: 0.1
60         z: 0
61     }
62     ImageParticle {
63         system: sys
64         groups: ["greenTeam"]
65         source: "pics/blur-circle3.png"
66         color: "#0006280A"
67         colorVariation: 0.1
68        z: 0
69     }
70     ImageParticle {
71         system: sys
72         groups: ["blaster"]
73         source: "pics/star2.png"
74         //color: "#0F282406"
75         color: "#0F484416"
76         colorVariation: 0.2
77         z: 2
78     }
79     ImageParticle {
80         system: sys
81         groups: ["laser"]
82         source: "pics/star3.png"
83         //color: "#00123F68"
84         color: "#00428FF8"
85         colorVariation: 0.2
86         z: 2
87     }
88     ImageParticle {
89         system: sys
90         groups: ["cannon"]
91         source: "pics/particle.png"
92         color: "#80FFAAFF"
93         colorVariation: 0.1
94         z: 2
95     }
96     ImageParticle {
97         system: sys
98         groups: ["cannonCore"]
99         source: "pics/particle.png"
100         color: "#00666666"
101         colorVariation: 0.8
102         z: 1
103     }
104     ImageParticle {
105         system: sys
106         groups: ["cannonWake"]
107         source: "pics/star.png"
108         color: "#00CCCCCC"
109         colorVariation: 0.2
110         z: 1
111     }
112     ImageParticle {
113         system: sys
114         groups: ["frigateShield"]
115         source: "pics/blur-circle2.png"
116         color: "#00000000"
117         colorVariation: 0.05
118         blueVariation: 0.5
119         greenVariation: 0.1
120         z: 3
121     }
122     ImageParticle {
123         system: sys
124         groups: ["cruiserArmor"]
125         z: 1
126         sprites:[Sprite {
127                 id: spinState
128                 name: "spinning"
129                 source: "pics/meteor.png"
130                 frames: 35
131                 frameDuration: 40
132                 to: {"death":0, "spinning":1}
133             },Sprite {
134                 name: "death"
135                 source: "pics/meteor_explo.png"
136                 frames: 22
137                 frameDuration: 40
138                 to: {"null":1}
139             }, Sprite {
140                 name: "null"
141                 source: "pics/nullRock.png"
142                 frames: 1
143                 frameDuration: 1000
144             }
145         ]
146     }
147     TrailEmitter {
148         system: sys
149         group: "cannonWake"
150         follow: "cannon"
151         emitRatePerParticle: 64
152         lifeSpan: 600
153         speed: AngleDirection { angleVariation: 360; magnitude: 48}
154         size: 16
155         endSize: 8
156         sizeVariation: 2
157         enabled: true
158         width: 1000//XXX: Terrible hack
159         height: 1000
160     }
161     TrailEmitter {
162         system: sys
163         group: "cannonCore"
164         follow: "cannon"
165         emitRatePerParticle: 256
166         lifeSpan: 128
167         size: 24
168         endSize: 8
169         enabled: true
170         width: 1000//XXX: Terrible hack
171         height: 1000
172     }
173 }