all repos — honk @ 1c233017b1d97c4db0632e9257d713a2ab3c7420

my fork of honk

fix alpha channel in rescale. gah, that was ugly.
Ted Unangst tedu@tedunangst.com
Mon, 29 Apr 2019 18:14:41 -0400
commit

1c233017b1d97c4db0632e9257d713a2ab3c7420

parent

ccc6b5a9de02e7af2cda8749f6b76296bb48c448

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M image.goimage.go

@@ -58,7 +58,7 @@ return delineate((l1 + l2 + l3 + l4) / 4.0)

} func squish(d []byte, s1, s2, s3, s4 int) byte { - return uint8((uint32(s1) + uint32(s2)) / 2) + return uint8((uint32(d[s1]) + uint32(d[s2]) + uint32(d[s3]) + uint32(d[s4])) / 4) } func vacuumwrap(img image.Image, format string) ([]byte, string, error) {