As a beginner in OpenGL i was wondering what could be the best way to render a textured terrain.
The data is stored in a grid-like structure and for every point the height and the texture (which could be i.e. grass, mud, stone …) are saved.
At the moment i render the grid multiple times, one time for every possible texture, specifying glColor3f(1.0,1.0,1.0) if the texture is set on a given point and glColor4f(1.0,1.0,1.0, 0.0) if the texture is not set, creating a smooth fade.
To me this doesn’t seem to be an efficient way so i’m asking which other ways could be possible to do this. Any hint would be apprechiated.