A farm world (written in C++ / OpenGL / GLSL) with some animations, textures, and hierarchical modeling.
Details
Aerial View of the farm
All the graphics for this project are generated using OpenGL. Two different kinds of objects can be found in the scene. The majority of the shapes found in the scene are not simple, they are complex obj meshes e.g., the pumpkins are created from a file called pumpkin.obj. The barn is made up of two simple shapes, a cube and a triangular prism. The cube.obj was provided in class. The roof.obj is an obj file that I created myself by providing the necessary vertices that make up the object.
How to Maneuver the Scene
- W - Zoom in
- S - Zoom out
- A - Strafe left
- D - Strafe right
- P - Spin pumpkins
- H - Begin bunny hopping
- L - Change dog course to the left
- R - Change dog course to the right
- Scrolling the mousepad will move the camera to see more of the scene.
Pumpkin Patch!
Hierarchically Modeled Objects
The dog is hierarchically modeled. The dog is made up of a few different meshes - a head, a body, and each leg is split into an upper and a lower part. Each of the pieces is built off of the location of another. For instance, the lower leg is put into place based on the location of the upper legs. The legs and the head are put into place based on the location of the body. The legs of the dog are animated and the direction of movement as keys are pressed!
Hierarchically Modeled Dog
Textures
Each of the objects in the world is textured to give a more realistic feel to the scene. The following images are the textures used throughout the scene.
Texture used for the roof
Texture used for the barn
Texture used for the ground
Texture used for the cows
Texture used for the pumpkins
Texture used for the bunnies
Texture used for the dog
More Images
Closer view of the barn
Closer view of the pumpkins and bunnies
Closer view of the cows
Bunnies can hop with press of H key!
References
Cow and Pumpkin OBJ files source
Texture Mapping Description
Sun and Shadow Placement Info
Spherical Texture Mapping
Directional Lighting Tutorial
Thanks for reading!
Lana Hodzic