View Full Version : Texture tiling
03-22-2009, 02:31 PM
How do I go about tiling the texture? For instance, making a texture which is say 64x64, and rather than stretching it over a very large area, simply repeat it over the area numerous times.
03-22-2009, 02:34 PM
Say you want to tile it 6 times horizontally and 4 vertically :
texcoord 0,0 -> texcoord 6,4 (instead of 1,1)
check the glTexParameter for GL_TEXTURE_WRAP_S/T is still GL_REPEAT (the default).
03-22-2009, 02:37 PM
wow. Was hoping it'd be that simple. I'll give it a go, thanks
03-22-2009, 02:52 PM
Getting a bit confused again. If I'm assigning it to a polygon, how can I specify that many coordinates. Can't I only assign one to each vertex?
03-22-2009, 04:36 PM
huh what ?
To be more precise, imagine for a square, each of the 4 vertex will get one of these :
03-22-2009, 05:38 PM
awesome! Got it working. Thanks very much :)
Powered by vBulletin® Version 4.2.2 Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.