Advertisement

Texture tiling

Started by February 06, 2005 04:58 PM
2 comments, last by lc_overlord 19 years, 9 months ago
Let's put this simple. I've got a texture, but I want to use only a small part of it to map a rectangle. Is there any way to tile it instead of stretching it? (BTW, no, I can't create a separate texture for every single part of it - basically it is a skin for a 2D interface) Thanks in advance
Not easily. You could either tesselate your geometry so that the section of the texture is mapped once on each tesselated block, or you could use a fragment program to tile the texture segment, but beware of boundary issues.

Enigma
Advertisement
So, I guess this is something you're not meant to do in OpenGL.
No big problem.

Thanks anyway
Quote: Original post by lazork357
So, I guess this is something you're not meant to do in OpenGL.


no, but it would be nice to do that because it would speed up the graphics.
The normal way to do that type of tiling is to create a separate texture just for that tile.
It might be saved in the same image file but at load time you create a texture of just that tiny little area.

This topic is closed to new replies.

Advertisement