diff options
author | Vincent Sanders <vince@netsurf-browser.org> | 2009-04-24 13:42:40 +0000 |
---|---|---|
committer | Vincent Sanders <vince@netsurf-browser.org> | 2009-04-24 13:42:40 +0000 |
commit | 3d5b21e1473dbdee6c3df66d9ba2a9d657f1b486 (patch) | |
tree | f88a339bd1510e9cf5cf1a2a33e345dd8014d513 /src/frontend_sdl.c | |
parent | 2b303df06ea14e99e41b118b299bb0bcf58aafd5 (diff) | |
download | libnsfb-3d5b21e1473dbdee6c3df66d9ba2a9d657f1b486.tar.gz libnsfb-3d5b21e1473dbdee6c3df66d9ba2a9d657f1b486.tar.bz2 |
add legacy plotter API
svn path=/trunk/libnsfb/; revision=7304
Diffstat (limited to 'src/frontend_sdl.c')
-rw-r--r-- | src/frontend_sdl.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/frontend_sdl.c b/src/frontend_sdl.c index 82342d3..ca98199 100644 --- a/src/frontend_sdl.c +++ b/src/frontend_sdl.c @@ -13,6 +13,7 @@ #include "libnsfb_event.h" #include "nsfb.h" #include "frontend.h" +#include "plotters.h" enum nsfb_key_code_e sdl_nsfb_map[] = { NSFB_KEY_UNKNOWN, @@ -378,6 +379,9 @@ static int sdl_set_geometry(nsfb_t *nsfb, int width, int height, int bpp) nsfb->height = height; nsfb->bpp = bpp; + /* select default sw plotters for bpp */ + select_plotters(nsfb); + return 0; } @@ -390,7 +394,7 @@ static int sdl_initialise(nsfb_t *nsfb) /* sanity checked depth. */ if ((nsfb->bpp != 32) && (nsfb->bpp != 16) && (nsfb->bpp != 8)) - nsfb->bpp = 16; + return -1; /* initialise SDL library */ if (SDL_Init(SDL_INIT_VIDEO) < 0 ) { |