Final Project: Rain/Hail/Snow Simulation

CMPS161 - Winter 2009

May Ang
mang@ucsc.edu

Description

This program was to be a rain/hail/snow animation using a simple particle system. The particles would react to the ground depending on what they were. And there would be some parameters that the user could adjust.

What's There

I have a particle system that falls under gravity. Particles change depending on what setting(rain/hail/snow). Hail and snow interact with the ground. Hail bounces(sort of, they kinda disappear after bouncing) and snow accumulates. The size of hail can be adjusted. There's supposedly controls to adjust how fast the particles are moving but they both look the same to me. I added some camera controls too. This isn't as smooth as I'd like but I've sent a quite a bit of time messing with values and they're mostly not that much different.

User Guide

I did this in Linux using OpenGL and was planning to use GLUI to create a GUI to adjust parameters. I ran into an issue with the connection between the redrawing and the controls. For choosing whether rain/hail/snow it would only animate/redraw if I drag the GUI window around the display window. I don't like or understand FLTK very well so I decided to use keyboard commands.

Compilation

Run the makefile in the terminal. Then ./particles

Controls
Key Action
r Rain
h Hail
s Snow
= Increase Hail Size
- Decrease Hail Size
, Decrese Speed?
. Increase Speed?
UP Camera Move Forward
DOWN Camera Move Back
RIGHT Camera Pan Right
LEFT Camera Pan Left
Page Up Camera Tilt Up
Page Down Camera Tilt Down
q Quit

Pictures!

Rain Hail Snow

Movie Clip?

I have not been able to find a good screencast software for Linux. RecordMyDesktop apparently does not work with my graphics card. And the other one I found, there are posts on forums about it messing up their computer and I'd rather not risk that

Files

References

http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=19

Tutorial & base code

http://freespace.virgin.net/hugo.elias/models/m_main.htm

Falling under gravity & bouncing