150 CHAPTER 5: Textures^
Figure 5-16. Repeating the image is convenient when you need to do repetitive patterns such as wallpaper.
Now let’s distort the texture by changing the vertex geometry, and to make things
visually clearer, restore the original texture coordinates to turn off the repeating:
static const GLfloat squareVertices[] =
{
-0.5f, -0.33f,
0.5f, -0.15f,
-0.5f, 0.33f,
0.5f, 0.15f,
};
This should pinch the right side of the square and take the texture with it, as shown in
Figure 5-17.