Skip to content

Commit

Permalink
fix!: framebuffer's byte length
Browse files Browse the repository at this point in the history
  • Loading branch information
zetanumbers committed Jan 14, 2022
1 parent 03dd8b1 commit 7aeec95
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wasm4/src/draw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ impl Framebuffer {

pub const WIDTH: usize = 160;
pub const HEIGHT: usize = 160;
pub const BYTE_LENGTH: usize = Self::WIDTH * Self::HEIGHT * 8 / 2;
pub const BYTE_LENGTH: usize = Self::WIDTH * Self::HEIGHT / 4;

pub fn get(&self) -> &Cell<[u8; Self::BYTE_LENGTH]> {
// SAFETY: WASM-4 is single-threaded
Expand Down

0 comments on commit 7aeec95

Please # to comment.