Chapter 7Adding Detail with Textures

We’ve managed to get a lot done with just simple shapes and colors. There’s something missing though: what if we could paint onto our shapes and add refined detail? Like artists, we can start out with basic shapes and color and add extra detail onto our surfaces by using textures. A texture is simply an image or a picture that has been uploaded into OpenGL.

We can add an incredible amount of detail with textures. Think of a beautiful 3D game you might have played recently. At the heart of things, the game is just using points, lines, and triangles, like any other 3D program. However, with the detail of textures and the touch of a skilled artist, these triangles can be textured to build a beautiful 3D scene. ...

Get OpenGL ES 2 for Android now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.