Make sure texture is bound to correct texture unit, stop flashing micro textures in daytona

This commit is contained in:
Ian Curtis 2016-05-04 16:30:15 +00:00
parent b0569007ef
commit 3693a51cbb

View file

@ -227,8 +227,6 @@ UINT32 Texture::UploadTexture(const UINT16* src, UINT8* scratch, int format, boo
} }
glPixelStorei(GL_UNPACK_ALIGNMENT, 4); // rgba is always 4 byte aligned glPixelStorei(GL_UNPACK_ALIGNMENT, 4); // rgba is always 4 byte aligned
glActiveTexture(GL_TEXTURE0); // activate correct texture unit
glGenTextures(1, &m_textureID); glGenTextures(1, &m_textureID);
glBindTexture(GL_TEXTURE_2D, m_textureID); glBindTexture(GL_TEXTURE_2D, m_textureID);