4 ms·
You can't write to the framebuffer device while X11 is running because it will just get overwritten immediately. So that means you can only use it on a machine
by bogwog 6y ago
You can't write to the framebuffer device while X11 is running because it will just get overwritten immediately. So that means you can only use it on a machine without a display server running. So... a web server maybe? Sure, but since most people use a web server by SSH'ing into it, a program that writes to framebuffer devices is going to be useless, unless you have a physical display device connected to the server and want to display something on it remotely.
So it's mostly a fun gimmick/curiosity. I wrote a realtime 3D rasterizer that renders to fbdev a while back. It was a fun project, but useless.
- grapeli23 6y agoWorks even in JSlinux. https://bellard.org/jslinux/vm.html?url=buildroot-x86-xwin.cfg&graphic=1 https://bellard.org/jslinux/vm.html?url=buildroot-x86-xwin.c... Download old qemu. https://drive.google.com/file/d/1e6UJcTC9FfwO20xzvcasTToPoaTs9yr_/view?usp=sharing https://drive.google.com/file/d/1e6UJcTC9FfwO20xzvcasTToPoaT... Load into jslinux. And execute the following commands in xterm. gzip -dc qemu-0.9.1.tar.gz | tar xf - -C/ mkdir /dev/shm && mount -t tmpfs tmpfs /dev/shm SDL_NOMOUSE=1 qemu -k en-us -m 4 pi.vfd Necessary condition, Xorg must work with the fbdev driver.
- oldsklgdfth 6y agoYou can login to a tty terminal and run your program that way. Ctrl + Alt + F1-F5 on linux.
- Jasper_ 6y ago> You can't write to the framebuffer device while X11 is running because it will just get overwritten immediately. You can't write to fbdev because that's not what X11 is using to display buffers to the screen, it uses the newer kernel mode-setting (KMS) API. It's only when you switch away to a VT that the "KMS master" drops its session, the kernel switches back to fbcon, and you can see the "raw fbdev" buffer again, which is usually a fake framebuffer. If you then write to the fbdev framebuffer, you'll see your changes, but fbcon will come in and overwrite them with the kernel console, unless you ioctl(KDSETMODE, KD_GRAPHICS); to turn off fbcon from drawing.