PARTICLE SIMULATION OF A  WATERFALL

CSC 471 FINAL PROJECT

Deepashree Krishnamurthy

 

 

Concept Overview

            Particle simulation involves using a system of particles to simulate an appropriate physical process. In our case, the system of particles is used to simulate a waterfall. The main idea involves spawning a system of particles with random offset in position and initial velocity. The position and velocity are updated according to the laws of physics making the simulation realistic.

Simulation Ingredients:

1.  Position and velocity update to simulate the motion of particles.

2.  Random initial position and velocity for a realistic motion of water.

3.  Collision detection to simulate frothing effect at the base of the fall.

4.  Texture mapping for creating the scene that includes waterfall rocks, grass/ground.

5.  Lighting effects to include simulation of fog and changing the color of water.

 

Summary of technical Details

             Updating the position and Velocity of the particles:

For each frame the new velocity and position of every particle is calculated.  The new velocity would be equal to the old velocity added to acceleration due to gravity (constant) times time step.  The new position is given by the addition of the old position and new velocity times time step.

The wavy motion of the particles is brought about by randomizing the initial position and velocity. The particles at the base of the fall are detected through a collision detection scheme. The vertical component of the velocity  is scaled down and reversed in sign to simulate bouncing and the resulting frothing.

            Fog :

                The effect the Fog is brought about by using the OpenGL command for fog.

Download          Waterfall.zip

General Instructions

            Place all the bit maps in the same directory as the executable.

User's Guide


Menu Options  :    

1. Enable/Disable Red Light.
2. Enable/Disable Green Light.
3. Enable/Disable Blue Light.
4. Exit :Exits the application

Keyboard Options :

f / F  : Enable or disable Fog
r / R  : Reset the position of the camera
a / A : Animate the Waterfall
q / Q : Exiting the application.
 

Camera Movement :

Camera is enabled by default.  Click and drag the mouse for the camera to rotate.

Snapshots:

            Start of Simulation                                                      Complete Waterfall                                          Frothing of water at the base, fog

                                                      

 

Resources:

Some useful links

1.  http://www.double.co.nz/dust/col0798.pdf

2.  http://home.cwru.edu/~naw4/