VESA and SDL in tty terminal
swell.k at gmail.com
Fri Feb 11 23:22:58 UTC 2011
David Demelier <demelier.david at gmail.com> writes:
> On 10/02/2011 15:37, Anonymous wrote:
>> David Demelier<demelier.david at gmail.com> writes:
>>> The SDL's pkg-message says we can use video driver in tty terminal.
>>> To do this you have to load the vesa kernel module or enable it in your
>>> kernel, and set environment variable "SDL_VIDEODRIVER=vgl".
>>> I tried it with mplayer :
>>> $ SDL_VIDEODRIVER=vgl; export SDL_VIDEODRIVER
>>> $ mplayer -vo sdl<the file here>
>>> [VO_SDL] Set_fullmode: SDL_SetVideoMode failed: Unable to switch to
>>> requested mode.
>> IIRC, vgl(3) mode setting unlike vidcontrol(8) doesn't work as regular user.
>> Try running mplayer under root
> Hi it works fine except after leaving mplayer or any SDL application
> my tty seems broken. I can't switch to a tty anymore my screen stays
> black and I must reboot/shutdown (no panic)
I'd try changing ttyvN using chvt, e.g.
$ sudo mplayer ...; sleep 2 && sudo chvt 1
And as mode-setting is somewhat buggy I'd suggest to start with the
least problematic mode, i.e.
mode# flags type size font window linear buffer
24 (0x018) 0x00000001 T 80x25 8x16 0xb8000 32k 32k 0x00000000 32k
and scaling every video to the desired resolution using vf_scale
#fs = false # implied
#vm = false # implied
# 1600x1200 (native) is broken, downscale
vf-add = scale=1270:-2
vf-add = scale=-2:1020::::::1
the one I use - http://pastebin.com/f7ycYyxe
> Are you encountering the same issue? There is no way to use vgl as
> regular user or we could open a PR for it?
More information about the freebsd-questions