ParallelDisplayController Class
Package: GHIElectronics.Endpoint.Devices.Display
Namespace: GHIElectronics.Endpoint.Devices.Display
The built-in display driven by the SoC's parallel RGB LCD controller (DRM "DPI" / parallel-RGB). Opens /dev/fb0 inside ParallelDisplayController.Enable, respects the real framebuffer stride, converts source pixel formats to the panel's bit depth, and blits with ParallelDisplayController.Flush.
public sealed class ParallelDisplayController : DisplayController
Constructors
ParallelDisplayController()
public ParallelDisplayController()
Properties
Height
public int Height { get; }
Returns int
IsEnabled
public bool IsEnabled { get; }
Returns bool
Width
public int Width { get; }
Returns int
Methods
Disable()
public override void Disable()
Closes /dev/fb0 and turns the parallel-RGB controller off.
Dispose()
public override void Dispose()
Calls ParallelDisplayController.Disable (best-effort - swallows any exception).
Enable()
public override void Enable()
Programs the parallel-RGB controller from /config/display.json, opens /dev/fb0, and reads the live stride and bits-per-pixel from /sys/class/graphics/fb0 (overriding the configured values if the kernel pinned a different format).
Flush(ReadOnlySpan<byte> pixels, PixelFormat format, int x, int y, int width, int height)
public override void Flush(ReadOnlySpan<byte> pixels, PixelFormat format, int x, int y, int width, int height)
Writes pixels to the region (x, y, width, height), converting from format to the framebuffer's native depth (16, 24, or 32 bpp) one row at a time.
| Parameter | Type | Description |
|---|---|---|
pixels | ReadOnlySpan<byte> | Source pixels in format, laid out row by row with no padding. |
format | PixelFormat | Source pixel format: Rgb565, Rgb24, Rgb32 or Argb32. |
x | int | Left edge of the target region in pixels. |
y | int | Top edge of the target region in pixels. |
width | int | Region width in pixels. |
height | int | Region height in pixels. |