From: Ted Bullock Subject: Re: rasops32: fix fonts on byte swapped framebuffers To: Crystal Kolipe Cc: tech@openbsd.org Date: Thu, 08 Oct 2026 11:31:10 -0600 Hi Crystal, I think there is probably a big endian issue with this approach. On a big endian framebuffer without RI_BSWAP, the mixed pixel pairs would be reversed. Also, b and f are signed int values, so the cast can corrupt the adjacent pixel. For example, white after byte swapping is 0xc7c7c700: (uint64_t)f /* 0xffffffffc7c7c700 */ (uint64_t)(uint32_t)f /* 0x00000000c7c7c700 */ It needs the additional cast through uint32_t before combining the two colours. Ted