summaryrefslogtreecommitdiff
path: root/src/sdl_fb.c
AgeCommit message (Collapse)Author
2018-02-26sdl_fb: add fullscreen= and size= settingsVito Caputo
fullscreen takes either "on" or "off" size expects WxH arguments, defaults still to 640x480 size is optional when fullscreen=on. Through the setup machinery, when fullscreen has been selected it will not ask for a size - a "fullscreen desktop" mode is presumed. However, thorugh the explicit commandline flags, a mixed mode can be achieved by specifying both "fullscreen=on,size=WxH". This instructs SDL to attempt a video mode switch to the specified size if needed. I've found it to be pretty unreliable on my Xorg/linux system, unless I choose the same video mode as my desktop is already in. Then I get what looks like rendering into the root window or something, it's weird. Hence there's no effort made to expose that in the interactive setup, but it's technically possible and some effort was made to wire it up.
2018-02-26sdl_fb: jump through SDL_Main() hoopsVito Caputo
Since I don't use the SDL event loop, this needs to be done to keep things happy apparently.
2018-02-26sdl_fb: drain event queue on page flipVito Caputo
2018-02-22fb,settings,drm_fb,sd_fb: const settings_t readersVito Caputo
The fb_ops entrypoints and their descendants are purely readers of the settings, so constify their settings_t instances and the operative functions which only read settings.
2018-02-22sdl_fb: implement rudimentary sdl fb backendVito Caputo
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.
© All Rights Reserved