From a11209e6ed39fcdaf5cbc1750aadc6a57f47a772 Mon Sep 17 00:00:00 2001 From: dosisod <39638017+dosisod@users.noreply.github.com> Date: Sun, 12 Sep 2021 11:18:06 -0700 Subject: [PATCH 1/2] Fix white background bleeding through sixel images: Tested with and without alpha patch applied. Simply setting alpha to 255 seems to fix it. I didn't set `dst` on lines 263 and 273 because those loops are impossible to reach. --- sixel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sixel.c b/sixel.c index 7bfe598..2c382f4 100644 --- a/sixel.c +++ b/sixel.c @@ -252,7 +252,7 @@ sixel_parser_finalize(sixel_state_t *st, unsigned char *pixels) *dst++ = color >> 16 & 0xff; /* b */ *dst++ = color >> 8 & 0xff; /* g */ *dst++ = color >> 0 & 0xff; /* r */ - dst++; /* a */ + *dst++ = 255; /* a */ } /* fill right padding with bgcolor */ for (; x < st->image.width; ++x) { From ac7b02b841cb6041792ff03c8b0d6a1bce6f6c9d Mon Sep 17 00:00:00 2001 From: Steven Date: Thu, 14 Oct 2021 04:57:44 -0500 Subject: [PATCH 2/2] Update patches.def.h Spelling fix. --- patches.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches.def.h b/patches.def.h index 0153aa1..aebf0e9 100644 --- a/patches.def.h +++ b/patches.def.h @@ -29,7 +29,7 @@ */ #define ALPHA_GRADIENT_PATCH 0 -/* This patch allows st to reize to any pixel size rather than snapping to character width/height. +/* This patch allows st to resize to any pixel size rather than snapping to character width/height. * https://st.suckless.org/patches/anysize/ */ #define ANYSIZE_PATCH 0