CPE 471 Final Project

Chandler Gifford

Overview

My intro graphics final project was to create a graphics program capable of rendering animated, skinned meshes. I used the Assimp asset importing library to load in model data from models saved in the collada (.dae) format. I chose models which already contained animation information and focuesed my efforts on implementing the rendering in OpenGL.

In addition to the animated models, the world contains a heightmap terrain which the wolf model can move around, and a bunch of randomly generated trees.

Graphics Technologies and Concepts

Animated Skinned Mesh

The mesh is animated by tranforming a set of bones which are defined in the object file. Each vertex contains a set of weights that specify how much it is affected by each bone. The vertex shader uses this weight information along with the bone tranformation data to determine the position of each vertex. This creates animations that deform the mesh very smoothly and look more natural.

The first two images below show the wolf at two different time steps in the animation. The third image shows that the wolf will also match the slope when going up or down hills. See the demo further down the page for a better visualization.

World Design

The world design took mostly from my previous project. The background is a skybox created with a cubemap. The terrain is generated from a heightmap image file and is textured using the same texture as the bottom of the cubemap. The trees are an imported .obj model and are draw randomly throughout the terrain. The trees are also shifted so they sit on the surface of the terrain. The lighting effects are calculating using the Blinn-Phong model and the fog effect is done by creating a linear combination between the caluclated color and the fog color based on distance from the camera.

Demo

Here is a demo of the major features of the project. Notice now the wolf's walking animation is smooth and the speed of movement is (mostly) matched to the speed of the animation. Also notice that when the wolf walks up on the hill it is rotated to match the slope.

Resources Used

Assimp was used to import models. The associated C++ documentation was a major source of info when figuring out how to make animations work.

This tutorial was the main guide I used, I used some design principles from the tutorial's code to for sending bone information to the GPU (using an array of bone transforms and sending an index/weight pair with each vertex) but in general I implemented everything in my own way.

The main animated model I used in my project was this wolf model

The cubemap images for the skybox were taken from this website

Here is the tree model I used