The second argument requires us to tell what option we want to set and for which texture axis we want to configure it for both the S and T axis. The first argument specifies the texture target we're working with 2D textures so the texture target is GL_TEXTURE_2D. GlTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_MIRRORED_REPEAT) GlTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_MIRRORED_REPEAT) Let's see what these look like on a sample texture image (original image by Hólger Rezende):Įach of the aforementioned options can be set per coordinate axis ( s, t (and r if you're using 3D textures) equivalent to x, y, z) with the glTexParameter* function:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |