In computer graphics, the simulating particle system is a simulation of the natural phenomena, such as dust, smoke, rain, fireworks, and so on. This particle system contains large number of tiny particles, which can vary from few hundreds to millions in numbers. Each of the unit particles possess the same characteristics, such as velocity, color, lifespan, and so on. These particles are updated once every frame. During the update, the respective characteristics of particles are computed and updated. As a result, it makes them move or appear to change its color.
In this recipe, we will implement the particle systems. Each particle is made up of a quad and textured with translucent texture. Each particle possesses a specific color that changes with the update of time. Let's take an overview of this recipe to understand the implementation of the simulation of the particle system:
Define particle attributes: This creates the data structure, which contains the important...