File tree Expand file tree Collapse file tree 1 file changed +1
-5
lines changed
service/assistant/widgets Expand file tree Collapse file tree 1 file changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -151,8 +151,6 @@ func monochrome(img image.Image) image.Image {
151151 } else {
152152 newImg .Set (x , y , color .Black )
153153 }
154- } else if ! isGrey (c ) {
155- newImg .Set (x , y , colourToMonochrome (c ))
156154 } else if closeToBlack (c ) {
157155 newImg .Set (x , y , color .Black )
158156 } else {
@@ -171,8 +169,6 @@ func lowColour(img image.Image) image.Image {
171169 c := img .At (x , y )
172170 if shouldDither (c ) {
173171 newImg .Set (x , y , color.Gray {0xaa })
174- } else if ! isGrey (c ) {
175- newImg .Set (x , y , colourToMonochrome (c ))
176172 } else {
177173 newImg .Set (x , y , greyTo2BitGrey (c ))
178174 }
@@ -220,7 +216,7 @@ func closeToBlack(c color.Color) bool {
220216
221217func shouldDither (c color.Color ) bool {
222218 r , g , b , _ := c .RGBA ()
223- return r == 0 && g == 0 && b == 0xFFFF
219+ return r == 42148 && g == 43176 && b == 43690
224220}
225221
226222func isGrey (c color.Color ) bool {
You can’t perform that action at this time.
0 commit comments