Mercurial > sdl-ios-xcode
diff src/video/SDL_video.c @ 2785:fa1095d42a5b
Fixed bug with converting colorkey surface to texture
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Tue, 25 Nov 2008 02:12:19 +0000 |
parents | 0969758c8809 |
children | 6bacfecbf27e |
line wrap: on
line diff
--- a/src/video/SDL_video.c Tue Nov 25 00:48:25 2008 +0000 +++ b/src/video/SDL_video.c Tue Nov 25 02:12:19 2008 +0000 @@ -46,6 +46,9 @@ #endif #endif /* SDL_VIDEO_OPENGL */ +/* From SDL_surface.c */ +extern void SDL_ConvertColorkeyToAlpha(SDL_Surface *surface); + /* Available video drivers */ static VideoBootStrap *bootstrap[] = { #if SDL_VIDEO_DRIVER_COCOA @@ -1585,6 +1588,7 @@ } dst = SDL_ConvertSurface(surface, dst_fmt, 0); if (dst) { + SDL_ConvertColorkeyToAlpha(dst); SDL_UpdateTexture(textureID, NULL, dst->pixels, dst->pitch); SDL_FreeSurface(dst); }