diff options
author | Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> | 2012-09-12 15:38:42 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2012-09-25 10:15:29 +0200 |
commit | 9d73b518fc3c61640123f8499aab7f8373e41dbd (patch) | |
tree | af61e6fd5a655afb46f66aa8ca7d0d68f2026c83 /arch/sandbox/mach-sandbox/include/mach/linux.h | |
parent | 910d0132905ca3ff12dddbcbceb94b4b5112ab5c (diff) | |
download | barebox-9d73b518fc3c61640123f8499aab7f8373e41dbd.tar.gz barebox-9d73b518fc3c61640123f8499aab7f8373e41dbd.tar.xz |
sandbox: add sdl video support
This will allow speed up the dev on framebuffer.
By default the resolution is VGA but this can be changed via cmdline.
We use a pthread to Flip the screen every 100ms as we can not detect when
barebox update it as barebox simpliy write in a buffer.
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/sandbox/mach-sandbox/include/mach/linux.h')
-rw-r--r-- | arch/sandbox/mach-sandbox/include/mach/linux.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/sandbox/mach-sandbox/include/mach/linux.h b/arch/sandbox/mach-sandbox/include/mach/linux.h index 5917fe93de..81f4946ab1 100644 --- a/arch/sandbox/mach-sandbox/include/mach/linux.h +++ b/arch/sandbox/mach-sandbox/include/mach/linux.h @@ -1,6 +1,8 @@ #ifndef __ASM_ARCH_LINUX_H #define __ASM_ARCH_LINUX_H +struct fb_bitfield; + int linux_register_device(const char *name, void *start, void *end); int tap_alloc(char *dev); uint64_t linux_get_time(void); @@ -20,4 +22,15 @@ struct linux_console_data { unsigned int flags; }; +extern int sdl_xres; +extern int sdl_yres; +int sdl_init(void); +void sdl_close(void); +int sdl_open(int xres, int yres, int bpp, void* buf); +void sdl_stop_timer(void); +void sdl_start_timer(void); +void sdl_get_bitfield_rgba(struct fb_bitfield *r, struct fb_bitfield *g, + struct fb_bitfield *b, struct fb_bitfield *a); +void sdl_setpixel(int x, int y, uint8_t r, uint8_t g, uint8_t b, uint8_t a); + #endif /* __ASM_ARCH_LINUX_H */ |