Skip to main content

Crate denise_fbdev

Crate denise_fbdev 

Source
Expand description

Legacy Linux fbdev backend for Denise.

§Read this before reaching for it

This is a fallback, and on any current kernel it is a fallback to DRM through a longer route. /dev/fb0 on a modern system is almost always CONFIG_DRM_FBDEV_EMULATION — DRM pretending to be fbdev. The Alpine VM this was developed against reports its framebuffer’s name as virtio_gpudrmfb, and a Raspberry Pi running Bookworm reports vc4drmfb. Going through it means giving up page flips, vsync and buffer age, to reach the same hardware denise_drm already drives properly.

So prefer DRM. Use this when:

  • the kernel is old enough to predate a usable DRM driver for the panel,
  • the panel has an fbdev driver and no DRM driver at all, which still happens with small SPI displays,
  • or DRM master cannot be obtained and a degraded picture beats none.

§What it costs

No page flip and no vsync, so a frame can tear. Drawing goes through a shadow buffer and only damaged rows are copied out, which keeps the tear as small as the change that caused it — the only mitigation available here, and another reason damage tracking belongs in the core rather than in a backend.

§Permissions

Writing to /dev/fb* needs the video group, or root.

Re-exports§

pub use info::FbInfo;
pub use info::FbInfoError;
pub use info::PixelLayout;

Modules§

info
Framebuffer geometry, read from sysfs.

Structs§

FbdevSurface
A framebuffer, drawn into through a shadow buffer.

Enums§

FbdevError
Something went wrong driving /dev/fbN.