diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2018-01-02 00:49:29 -0800 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2018-02-22 14:26:05 -0800 |
commit | d58d959a94f24fa6f496380b1f085cda48560a63 (patch) | |
tree | 4b7ba5ed50312d0c3eb49571b5fe42d507275a45 /src/sdl_fb.h | |
parent | 6e687a50a93ae780b5a7cbc03193f40f6e80eaa6 (diff) |
sdl_fb: implement rudimentary sdl fb backend
This uses a simple fixed 640x480 windowed mode (for now).
The SDL2 Renderer & Texture API is used for vsync-synchronized presents.
There's probably excessive copying going on because the rototiller fb
code manages pages and flips but SDL2 doesn't really expose low-level
control of such things.
This backend is quite useful for development purposes, allowing quick
iteration in a windowed environment.
Note this is just the backend implementation, it's dormant code but
trivially activated.
Diffstat (limited to 'src/sdl_fb.h')
-rw-r--r-- | src/sdl_fb.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/sdl_fb.h b/src/sdl_fb.h new file mode 100644 index 0000000..4cd0ee9 --- /dev/null +++ b/src/sdl_fb.h @@ -0,0 +1,9 @@ +#ifndef _SDL_FB_H +#define _SDL_FB_H + +typedef struct sdl_fb_t sdl_fb_t; + +sdl_fb_t * sdl_fb_new(); +void sdl_fb_free(sdl_fb_t *fb); + +#endif |