Mercurial > sdl-ios-xcode
comparison src/video/SDL_surface.c @ 4491:2cd7bb613a83
Turn on blending if we're converting from a surface with colorkey enabled
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Wed, 07 Jul 2010 21:35:44 -0700 |
parents | 39c22a953456 |
children | aa8888658021 |
comparison
equal
deleted
inserted
replaced
4490:06c7423f8c60 | 4491:2cd7bb613a83 |
---|---|
849 SDL_SetClipRect(convert, &surface->clip_rect); | 849 SDL_SetClipRect(convert, &surface->clip_rect); |
850 | 850 |
851 /* Enable alpha blending by default if the new surface has an | 851 /* Enable alpha blending by default if the new surface has an |
852 * alpha channel or alpha modulation */ | 852 * alpha channel or alpha modulation */ |
853 if ((surface->format->Amask && format->Amask) || | 853 if ((surface->format->Amask && format->Amask) || |
854 (copy_flags & SDL_COPY_MODULATE_ALPHA)) { | 854 (copy_flags & (SDL_COPY_COLORKEY|SDL_COPY_MODULATE_ALPHA))) { |
855 SDL_SetSurfaceBlendMode(convert, SDL_BLENDMODE_BLEND); | 855 SDL_SetSurfaceBlendMode(convert, SDL_BLENDMODE_BLEND); |
856 } | 856 } |
857 if ((copy_flags & SDL_COPY_RLE_DESIRED) || (flags & SDL_RLEACCEL)) { | 857 if ((copy_flags & SDL_COPY_RLE_DESIRED) || (flags & SDL_RLEACCEL)) { |
858 SDL_SetSurfaceRLE(convert, SDL_RLEACCEL); | 858 SDL_SetSurfaceRLE(convert, SDL_RLEACCEL); |
859 } | 859 } |