From ec5606c16a86015edaaf852e317e7cbc96f163cb Mon Sep 17 00:00:00 2001 From: Berkus Decker Date: Sat, 2 Mar 2019 19:16:50 +0200 Subject: [PATCH] [wip] debug depth woes --- src/platform/display.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/platform/display.rs b/src/platform/display.rs index 9cf294d..ec872c7 100644 --- a/src/platform/display.rs +++ b/src/platform/display.rs @@ -133,7 +133,7 @@ impl Display { // 1. Fix display output so we can print some values // 2. Print display info // 3. Go from there. - (y * self.pitch + x * 4/*(self.depth / 8)*/ + self.color_component(chan)) as isize, + (y * self.pitch + x * (self.depth >> 3) + self.color_component(chan)) as isize, ) = c as u8; } }