Red & blue channels swapped for texture
I'm am trying to follow the examples to get a sprite into a game, but no matter what I do, the sprite's red and blue channels show up swapped. I inserted it into an example game, and even copy-pasted an example grit file, and yet it still shows up with the colors swapped. Here is the image I've been using for testing
It appears my initial images have stopped working; here they are. First, how the sprite should look:
And here it is in the 2Dplus3D example game.
The grit file is this:
Code: Select all
# Set the warning/log level to 3
-W3
#bitmap mode
-gb
# Set the bit depth to 4 (16 colors)
-gB4
#include pal
-p
The load method I am calling is this:
Code: Select all
glLoadTileSet(
TestImage,
16,
16,
16,
16,
GL_RGB16,
TEXTURE_SIZE_16,
TEXTURE_SIZE_16,
GL_TEXTURE_WRAP_S|GL_TEXTURE_WRAP_T|TEXGEN_OFF|GL_TEXTURE_COLOR0_TRANSPARENT,
16,
(u16*)shipGfxPal,
(u8*)shipGfxBitmap
);
And the rendering method I am calling is this:
Code: Select all
glSprite(16, 16, GL_FLIP_NONE, TestImage);
Does anyone know what might be causing this?