← Back to Blog 0.7.0 · VIDEO · BUGFIX

Framebuffer Pixel Format Fix — PixelBitMask RGBA/BGRA Resolution

June 23, 2026 · Sigil-Docs · sigil-video 2f93502
videobugfixreal-silicon0.7.0

Fixes pink-instead-of-purple on real x86 hardware: EFI GOP reports PixelFormat==2 (PixelBitMask) with RGBX byte order. Previously hal_set_pixfmt_gop left pixfmt as raw value 2, causing fb_pack to use wrong byte order. Now compares red vs blue mask multipliers to resolve to FMT_RGBA(0) or FMT_BGRA(1). PIXFMT-PASS.

The fix

fbfmt.sg
PixelBitMask resolutionhal_set_pixfmt_gop(fmt, rmask, gmask, bmask, amask): when fmt == FMT_MASK(2), compares rmask vs bmask multiplier positions to determine if the framebuffer is RGBA or BGRA byte order. Never leaves pixfmt as the raw PixelBitMask value. Real-silicon tested on Director's x86 hardware — purple accent now renders correctly.