Textures in GL_VERSION_1_1

I’m trying to write a GL 1.1 compatible texture renderer and I keep getting GL_INVALID_ENUM for this call: glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, 128, 128, 0, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, null)

I’m betting it’s the GL_UNSIGNED_INT_8_8_8_8_REV that is causing the problem (based on the GL spec), but what is a good format to change to?

Just use GL_UNSIGNED_BYTE.

As you’re passing a ByteBuffer, and you might want to work prefer ints (according to usage of GL_UNSIGNED_INT_8_8_8_8_REV), just use bb.asIntBuffer() to manipulate your data.