Inline an unnecessary block.
This commit is contained in:
Kartik K. Agaram 2021-07-11 09:17:15 -07:00
parent 5234ba60f5
commit 7e21abe0c9
1 changed files with 30 additions and 32 deletions

2
img.mu
View File

@ -487,7 +487,6 @@ fn _dither-pgm-unordered src: (addr array byte), width: int, height: int, buf: (
compare x, width
break-if->=
var error/ebx: int <- _read-dithering-error buf, x, y, width
{
# error += src_color << 16
var curr/eax: byte <- _read-pgm-buffer src, x, y, width
var curr-int/eax: int <- copy curr
@ -520,7 +519,6 @@ fn _dither-pgm-unordered src: (addr array byte), width: int, height: int, buf: (
#? draw-text-wrapping-right-then-down-from-cursor-over-full-screen 0/screen, " ", 7/fg 0/bg
var color-byte/eax: byte <- copy-byte color
_write-raw-buffer dest, x, y, width, color-byte
}
_diffuse-dithering-error-floyd-steinberg buf, x, y, width, height, error
x <- increment
loop