Wednesday, 21 November 2012

Theme Park Scene 1

I am currently developing a Theme Park scene as part of a Graphics Programming module at University. We are using OpenGL and C++. Thus far, I have a basic class structure that allows me to inherit from a 'Primitive' class, which allows me to easily create primitive shapes such as cubes or tetrahedrons. Vertex normal calculations and texture mapping is black boxed by the Primitive class, all the derived class' constructor needs to do is define the vertices, texture mapping coordinates and draw order for the vertices, all on the constructor's stack and the primitive class creates these in the heap as it's own members. I can also inherit from a Model class, and each model can contain a number of primitives to create it's geometry. The camera also moves and rotates on the XZ plane, however I hope to expand this so that the camera is free to move/rotate in all directions. The following are some screenshots of the scene at present, with a few models implemented.

This bridge will go over a river, which will have a small and very basic ripple effect created using recursive subdivision of a single quad surface.




By my next update, I hope to have implemented an algorithm to allow me to generate circles/curved surfaces in order to create a Cylinder primitive. This will require some modification of the vertex normal calculations as well.

No comments:

Post a Comment