rem: glBegin(GL_QUADS); glTexCoord2i(0, 0); glVertex3f(sprite->x, sprite->y, 0); glTexCoord2i(sprite->bitmap->width, 0); glVertex3f(sprite->x + sprite->width, sprite->y, 0); glTexCoord2i(sprite->bitmap->width, sprite->bitmap->height); glVertex3f(sprite->x + sprite->width, sprite->y + sprite->height, 0); glTexCoord2i(0, sprite->bitmap->height); glVertex3f(sprite->x, sprite->y + sprite->height, 0);
add: glBegin(GL_QUADS); { glTexCoord2i(0,                         0); glVertex2i  (sprite->x,                 sprite->y);  glTexCoord2i(sprite->bitmap->width,     0); glVertex2i  (sprite->x + sprite->width, sprite->y);  glTexCoord2i(sprite->bitmap->width,     sprite->bitmap->height); glVertex2i  (sprite->x + sprite->width, sprite->y + sprite->height);  glTexCoord2i(0,                         sprite->bitmap->height); glVertex2i  (sprite->x,                 sprite->y + sprite->height); }
context: bool glgfx_sprite_render(struct glgfx_sprite* sprite) {  glColor4f(1,1,1,1);  glEnable(GL_TEXTURE_RECTANGLE_ARB);  glBindTexture(GL_TEXTURE_RECTANGLE_ARB, sprite->bitmap->texture);  glBegin(GL_QUADS);  glTexCoord2i(0, 0);  glVertex3f(sprite->x,	     sprite->y, 0);  glTexCoord2i(sprite->bitmap->width,	       0);  glVertex3f(sprite->x + sprite->width,	     sprite->y, 0);  glTexCoord2i(sprite->bitmap->width,	       sprite->bitmap->height);  glVertex3f(sprite->x + sprite->width,	     sprite->y + sprite->height, 0);  glTexCoord2i(0,	       sprite->bitmap->height);  glVertex3f(sprite->x,	     sprite->y + sprite->height, 0);  glEnd();  GLGFX_CHECKERROR();  return true;}