Desert Featuring a Day/Night Cycle

My project features a desert scene, textured with a cracked earth, supporting decaying trees and having popcorn-like clouds overhead. The car is a Shelby AC Cobra 269 which can be driven through the desert using WASD for movement with mouse control for direction of travel. The camera follows directly behind the car so that the user may stay in control of it like in a video game. The goal of the project was to further explore lighting an interactive environment.

Technology Emphasis

The technology I focused on for this project was lighting. I use a Blinn-Phong shading model with a directional light. To simulate sunrise, sunset, and nighttime, the color of the directional light changes RGB values depending on the angle of the incoming light. There is broken code for a shadow map commented out within main.cpp and the shader files, for the depth texture is not working correctly at this time. The .GIF below shows the camera's point of view as it rotates around the scene, capturing an orthographic view to make the shadow map with. The shadow shaders are then supposed to sample this texture to see if the fragment is closer to the light source than the depth of the texture; if it isn't, then a shadow should be drawn. The user can switch between the viewpoint of the lightsource for this shadowmap and the normal viewpoint behind the car by pressing L or C, respectively.






Shelby AC Cobra 269 –

Clouds and Trees -

Ground Texture -|DGFY1ZU8Fw2QY7FqLL18Vf3vLQ5UEYjygKHkKBmZRyMtJh|g7i8GX*AO66Zoh1zkMOIL43Oommk9dSwhI885fDcCrFMf5vfssF0pYXm47|iZRMU2SNihaYhb2ncTWyBNg3Z1ZMkYXjwym12Ujjnp4lWNjE0ue28oeXAZnW39EZ3OOcxN5JJ8O|d4vN4LIEr8olD3YtHzWl281A