Skip to content

Commit

Permalink
Kobo: Check for RGBA vs BGRA the proper way
Browse files Browse the repository at this point in the history
i.e., poke at the fb vinfo data to check the component offsets.

Fix koreader#11952
  • Loading branch information
NiLuJe committed Jun 1, 2024
1 parent c5600ff commit 83d45c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/device/kobo/device.lua
Original file line number Diff line number Diff line change
Expand Up @@ -701,7 +701,7 @@ function Kobo:init()
mxcfb_bypass_wait_for = mxcfb_bypass_wait_for,
no_cfa_post_processing = G_reader_settings:isTrue("no_cfa_post_processing"),
}
if self.screen.fb_bpp == 32 and not self:hasColorScreen() then
if self.screen.fb_bpp == 32 and self.screen._vinfo.red.offset ~= 0 then
-- Ensure we decode images properly, as our framebuffer is BGRA...
logger.info("Enabling Kobo @ 32bpp BGR tweaks")
self.hasBGRFrameBuffer = yes
Expand Down

0 comments on commit 83d45c8

Please sign in to comment.