Exercises
Now that we’ve covered the basics of a particle system, let’s take it further and create some firework bursts in the air. Depending on how you implement things, your app might look as shown in the next figure.
Here are some challenges that you’ll want to consider as you work on this exercise:
-
How does one create the trails? Will you update the particle positions in Java code and use that to create new particles? Or can you modify the particle creation times and create effects with that?
-
There’s a tradeoff between particle count and size and what the device is capable of. At some point, too many particles will slow down the frame rate.
-
Should the fireworks create smoke?
As a research exercise, do some more reading on particle systems ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access