GL texture problems
hverbeet at gmail.com
Tue Feb 14 05:46:46 CST 2006
On 14/02/06, Stefan Dösinger <stefandoesinger at gmx.at> wrote:
> Do I need to bind a texture? I create a new texture with glTexImage, upload a
> texture part with glTexSubImage. AFAIK this should be enought to have the
> texture available for drawing.
OpenGL needs to know which texture you're operating on. glBindTexture
binds a texture to a texturing target, like GL_TEXTURE_2D. If you
don't, it's not defined which texture you're operating on, although it
could be a texture you've previously bound somewhere else, and
glTexImage would overwrite it.
glGenTextures is used to allocate texture ids, glDeleteTextures is
used to free them again.
More information about the wine-devel