diff options
author | Arisotura <thetotalworm@gmail.com> | 2019-06-03 15:00:49 +0200 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2019-06-03 15:00:49 +0200 |
commit | 4a4415fc2ec067fb79881e17e14953b69ef80e0c (patch) | |
tree | e62443817e1d5ee7e652edcd57dfa8ec97895353 /src/libui_sdl/libui/unix | |
parent | 43e3e53afc4a8777592333717cfc4f4b304051eb (diff) |
more work on OSD
Diffstat (limited to 'src/libui_sdl/libui/unix')
-rw-r--r-- | src/libui_sdl/libui/unix/draw.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libui_sdl/libui/unix/draw.c b/src/libui_sdl/libui/unix/draw.c index e55397e..5befcd3 100644 --- a/src/libui_sdl/libui/unix/draw.c +++ b/src/libui_sdl/libui/unix/draw.c @@ -143,13 +143,13 @@ void uiDrawRestore(uiDrawContext *c) // bitmap API -uiDrawBitmap* uiDrawNewBitmap(uiDrawContext* c, int width, int height) +uiDrawBitmap* uiDrawNewBitmap(uiDrawContext* c, int width, int height, int alpha) { uiDrawBitmap* bmp; bmp = uiNew(uiDrawBitmap); - bmp->bmp = cairo_image_surface_create(CAIRO_FORMAT_RGB24, width, height); + bmp->bmp = cairo_image_surface_create(alpha ? CAIRO_FORMAT_ARGB32 : CAIRO_FORMAT_RGB24, width, height); if (cairo_surface_status(bmp->bmp) != CAIRO_STATUS_SUCCESS) implbug("error creating bitmap: %s", cairo_status_to_string(cairo_surface_status(bmp->bmp))); |