For this assignment, you will create a randomized rough terrain as a wireframe mesh then fly over the terrain from the perspective of the camera using C or C++ with the OpenGL Utility Toolkit (GLUT). The specifications are outlined below.
The terrain should be created from a three-dimensional array of vertices (X, Y, Z).
Each vertex should be evenly spaced on a grid in the X plane (left to right) and Z plane (moving in and out of the screen).
Each vertex should have a randomized value in the Y plane (up and down). The Y plane is what gives the terrain a mountainous surface.
Draw an unfilled triangle (wireframe) between every adjacent vertex such that each triangle shares an edge with another triangle. The triangles should not overlap or encapsulate other triangles. This will create a giant, tesselated, polygonal surface mesh.
The camera will be controlled using the following keys:
The camera should not move beyond the edges of your ground terrain (in the X and Z planes).
Note: It is ok for the camera to fly through a mountain peak.