Remove mask versions of SDL_CreateRGBSurface* #6701 (#6711)

* Rename SDL_CreateRGBSurface{,From} to SDL_CreateSurface{,From}, which now takes a format parameter
This commit is contained in:
Sylvain Becker authored and GitHub committed 2022-12-01 08:04:02 -08:00
1 parent 778b8926b4
commit 932f61348d
36 files changed
+212 -558

No files matched your search

+1 -9
View File
@@ -322,15 +322,7 @@ SDL_GL_LoadTexture(SDL_Surface *surface, GLfloat *texcoord)
texcoord[2] = (GLfloat)surface->w / w; /* Max X */
texcoord[3] = (GLfloat)surface->h / h; /* Max Y */
image = SDL_CreateRGBSurface(w, h, 32,
#if SDL_BYTEORDER == SDL_LIL_ENDIAN /* OpenGL RGBA masks */
0x000000FF,
0x0000FF00, 0x00FF0000, 0xFF000000
#else
0xFF000000,
0x00FF0000, 0x0000FF00, 0x000000FF
#endif
);
image = SDL_CreateSurface(w, h, SDL_PIXELFORMAT_RGBA32);
if (image == NULL) {
return 0;
}