LoadModel

Check your repo for the LoadModel program. Complete the TODOs and checkin your code. This project is quite challenging! Get started early!

This project uses several new commands.

It uses vertices and vertex elements to construct triangles. The OpenGL commands are:

The code also uses multiple vertex array objects (VAO). Review the code in RenderEngine.setupBuffers() and the corresponding code in RenderEngine.display().

For this project, you will use an OBJ model loader. The loader should read files into its internal data stuctures. You will need to put that data into the model structure in the project. The API for the OJB loader is here.

Rubric

Position attribute 0 : No positions 1 : Load OBJ position
Element data 0 : No elements 1 : Load OBJ vertex indices
Color attribute 0 : No colors 1 : Load OBJ diffuse color
Triangle normal data 0 : No triangle normals 1 : Compute from OBJ face
Vertex normal value 0 : Incorrect value 2 : Set from connected faces
Vertex normal value 0 : Incorrect value 1 : Unit length
Vertex normal value 0 : Missing value 1 : Set for each vertex
Normal attribute 0 : No normals 1 : Set and uploaded to GPU
Display scaled normals 0 : No normals displayed 1 : Scaled to range [-1,1]

Final scaled normals:




Unscaled for reference: