bonsoir
la transparence sur la texture tga ne s'affiche pas, pourtant j'utilise le code ci-dessous et je ne vois pas quoi d'autre à ajouter ou modifier au code

merci d'avance pour un eventuel tuyau:
#include <gl/glext.h>
class Csdl
{
public:
GLuint texture_name;
void LoadTexture(const char*file,GLuint texture)
{
SDL_Surface *image=IMG_Load(file);
if (image==NULL)
{
MessageBox(NULL,"Image pas chargée","debug",MB_ICONSTOP|MB_OK);
}
GetObject(image, sizeof(image), &image);
glGenTextures(1,&texture_name);
glBindTexture(GL_TEXTURE_2D,texture);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_REPEAT);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_REPEAT);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
if(strstr(file,".tga"))
gluBuild2DMipmaps(GL_TEXTURE_2D, 3, image->w, image->h,
GL_BGRA, GL_UNSIGNED_BYTE, image->pixels);
if(strstr(file,".bmp"))
gluBuild2DMipmaps(GL_TEXTURE_2D, 3, image->w, image->h,
GL_BGR, GL_UNSIGNED_BYTE, image->pixels);
if(strstr(file,".jpg"))
gluBuild2DMipmaps(GL_TEXTURE_2D, 3, image->w, image->h,
GL_RGB, GL_UNSIGNED_BYTE, image->pixels);
glEnable(GL_TEXTURE_2D);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_BLEND);
DeleteObject(image);
}
};