CSC476 - Real-Time 3D Computer Graphics Software Systems (Final Project)

Students: Nick Burns, KaShing Chan

Professor: Zoë J. Wood


 

Description

Hi, this is Nick and Kashing, we implemented this car racing game and using the Cal Poly campus as the "playground". A computer controlled and human controlled player compete with each other, and the player that crosses the finish line first will win. Some of the stuffs that we have used in this game are described as follows and the corresponding movie clips are available for download.

Screen Shots

Path finding & Time based character movement: this is the most important element of this game. We have the road/track represented as concrete points. Each concrete point is a checkpoint which indicates where the player should pass. The path finding methodology compute the shortest path using Dijkstra’s algorithm based on a 2D array representation of the terrain. Location information of the checkpoint, velocity of the player and costs of the path are all considered for path finding. (Implemented by Nick)

 

World Model: the terrain model is based on the Digital Elevation Model downloaded from the Internet. We texture-mapped the terrain with the aerial photo of the campus and aligned the buildings with the photo. Buildings are based on the AutoCAD model available from one of the Cal Poly websites. The original model is in 2D format and we extruded it to 3D, export it to ASE file format through 3D Studio. We also write our parser for changing the entire world model to mesh file. (Implemented by Kashing)

 

Player Model: The car model actually used the spring-mass physical based system, which is similar to particle system in some ways. The spring controls the distance between the wheels. Different forces are applied to the player. For instance, there is gravity force, friction and reaction force due to collision with terrain or building. (Implemented by Nick)

 

Collision Detection: Collision is checked against the terrain and other models. To speed up the detection, we used different techniques. Basically, we use a hierarchy and performing the test from lower detail to higher detail. For example, every object has a bounding box, whenever we test for collision, we check if there is intersection between the player bounding box and the object bounding box. If yes, we test the player bounding box against the objects’ triangles’ bounding boxes. Then we test the player bounding sphere with the triangle plane. To speed up CD on terrain, we locate the player first and test it against the corresponding terrain grid(s) only. (Implemented by Nick and Kashing)

 

View Frustum culling: This may not be observable from the game since the terrain is not big enough and we have a big view frustum. Anyway we have that implemented in this game. (Implemented by Nick)

 

Destructible mesh: When the player collides with the building or the road block, vertices are displayed and triangles are tessellated. Since the buildings are also destructible, player can move across building in some case. (Implemented by Nick)

  

User Interface: A mini-map is shown at the corner (a sky view). It follows the rotation and translation of the player.

start of the game

 

 

Path finding

 

 

Collision detection & deformation

References

Terrain map (DEM model): www.usgs.com

Models of the Buildings (AutoCAD format): www.facilities.calpoly.edu

Download executable for the game