How to get SDL to use fbcon not caca
Asked Answered
D

1

7

I am trying to get started using SDL to create a portable and pretty front end that can run under X, or directly from the terminal (hopefully on a rasberry pi at some point) - at the moment I'm on a laptop with the latest Ubuntu on it.

I am having trouble getting an image displayed properly on the terminal - it comes out as ascii art. I think this is a problem with my system configuration rather than the example program I have, as it works fine when run under X.

So far all I think I know is that SDL should be using the fbcon video driver, but is instead using aalib. I gather that SDL checks to see if framebuffer is available and uses it if it is - and it is there - at least according to the output of

> fbset -i  

mode "1024x768"
    geometry 1024 768 1024 768 32
    timings 0 0 0 0 0 0 0
    accel true
    rgba 8/16,8/8,8/0,0/0
endmode
Diaphaneity answered 30/1, 2013 at 23:21 Comment(0)
J
7

Make sure that your SDL install is built with framebuffer support (--enable-video-fbcon and/or --enable-video-directfb) and that the SDL_VIDEODRIVER environment variable is set to fbcon or directfb.

Jilt answered 31/1, 2013 at 18:42 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.