From ac4d88eb150b00c5bdf239be0113f1cd04d34c82 Mon Sep 17 00:00:00 2001 From: Robert Garrett Date: Mon, 6 May 2024 15:48:01 -0500 Subject: [PATCH] Fix OP_RUN test case My did my numbers wrong. 0b1111 is definitely not 13. Not under normal encodings, not with the -1 OP_RUN bias. Bro what. --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 9038217..6474ec7 100644 --- a/src/main.rs +++ b/src/main.rs @@ -368,7 +368,7 @@ mod test { fn decoder_unpack_run() { let compressed = [ (QOI_OP_RUN | 0b0000_0000), // 1 -- bias of -1, so all zeros is a run of 1 pixel - (QOI_OP_RUN | 0b0000_1111), // 13 + (QOI_OP_RUN | 0b0000_1100), // 13 // 0b1111? no it isn't. what? ]; let init_pixel = PixelRGBA::new(50, 100, 150, 200);