diff --git a/lib/src/processor/memory/mmio/gpu.rs b/lib/src/processor/memory/mmio/gpu.rs index 189e03f..3114e32 100644 --- a/lib/src/processor/memory/mmio/gpu.rs +++ b/lib/src/processor/memory/mmio/gpu.rs @@ -322,7 +322,7 @@ where } for x in 0..WIDTH { self.buffer[(scanline as usize * WIDTH) + x] = ColourInner::Error - .rgb_bytes(None, self.is_cgb_mode()) + .rgb_bytes(None, self.cgb_data.is_some()) .into(); } if self.lcdc.bg_window_enable { @@ -337,7 +337,7 @@ where } else { for x in 0..WIDTH { self.buffer[(scanline as usize * WIDTH) + x] = ColourInner::Error - .rgb_bytes(None, self.is_cgb_mode()) + .rgb_bytes(None, self.cgb_data.is_some()) .into(); } } @@ -490,7 +490,7 @@ where }); self.buffer[buffer_index] = - colour.rgb_bytes(cgb_data, self.is_cgb_mode()).into(); + colour.rgb_bytes(cgb_data, self.cgb_data.is_some()).into(); } } } @@ -568,7 +568,7 @@ where .map(|v| (v.palettes.bg, attributes.palette)); self.buffer[(scanline as usize * WIDTH) + x] = - colour.rgb_bytes(cgb_data, self.is_cgb_mode()).into(); + colour.rgb_bytes(cgb_data, self.cgb_data.is_some()).into(); } }