views:

472

answers:

1

I have a sprite sheet of images of differnet width and height, which i have the coordinates to. I need to render only a specific sprite and is wondering how to go about doing it. Can anyone help me?

+2  A: 

If you are using OpenGL for the rendering, then I expect you will be using your sprite sheet as a texture. You can provide texture coordinates (in the range from 0 to 1) to specify which parts are used.

There is a good tutorial on texturing in opengl here...

http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=06

rikh