def jpeg.idct.blocks

gralha-jpeg-decode@0.1.0.1 · jpeg.bend:652

import gralha-jpeg-decode@0.1.0.1/jpeg.bend as Jpeg
import Base
import gralha-bytes@0.1.0.1/bytes.bend as Bin

652def jpeg.idct.blocks(n: Nat, +index: U32, +cols: U32, +coefficients: Bin.Bytes, +quant: Bin.Bytes, out: Bin.Bytes) -> Bin.Bytes:
653  match n:
654    case 0n: out
655    case 1n+d: jpeg.idct.blocks(d, U32.inc(index), cols, coefficients, quant, jpeg.idct.pixels(64n, 0, (index % cols * 8 : U32), (index / cols * 8 : U32), (cols * 8 : U32), jpeg.idct.rows(64n, 0, (index * 64 : U32), coefficients, quant), out))

Uses (9)

Used by (1)