summaryrefslogtreecommitdiff
path: root/src/sdl_fb.c
diff options
context:
space:
mode:
authorVito Caputo <vcaputo@pengaru.com>2020-09-13 20:01:07 -0700
committerVito Caputo <vcaputo@pengaru.com>2020-09-13 20:01:07 -0700
commita44cb1ada0a17289c105e9a23c707085d84d4360 (patch)
tree7f1a5b685f6a1c1d9d287de8666579b109e3c654 /src/sdl_fb.c
parent93d90e8e1d176c2ad2ed925693e6a232ed2d61ae (diff)
sdl_fb: use SDL_CreateRGBSurface() instead
I was using SDL_CreateRGBSurfaceWithFormat() without considering the minimum SDL2 version implications. Switch to SDL_CreateRGBSurface() as there's no relevant difference, so I can lower the minimum SDL2 version in configure.ac.
Diffstat (limited to 'src/sdl_fb.c')
-rw-r--r--src/sdl_fb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sdl_fb.c b/src/sdl_fb.c
index a3eb0d1..6ba69e1 100644
--- a/src/sdl_fb.c
+++ b/src/sdl_fb.c
@@ -187,7 +187,7 @@ static void * sdl_fb_page_alloc(void *context, fb_page_t *res_page)
if (!p)
return NULL;
- p->surface = SDL_CreateRGBSurfaceWithFormat(0, c->width, c->height, 32, SDL_PIXELFORMAT_RGB888);
+ p->surface = SDL_CreateRGBSurface(0, c->width, c->height, 32, 0, 0, 0, 0);
res_page->fragment.buf = p->surface->pixels;
res_page->fragment.width = c->width;
© All Rights Reserved