I have a strange bug with my program, where x ( a green x ) and o ( a red o ), both solid color PNG images with a transparent background, get drawn to the screen completely black. The non-transparent shape remains the same.
The code where the images are loaded:
x = IMG_Load( “x.png” );
o = IMG_Load( “o.png” );
The code where the images are drawn to the main window surface:
SDL_BlitSurface( x, NULL, surface, &board[i][j] );
SDL_BlitSurface( o, NULL, surface, &board[i][j] );
I don’t have a good idea what might be causing this.