Skip to content

Commit

Permalink
Include CRC
Browse files Browse the repository at this point in the history
  • Loading branch information
JrMasterModelBuilder committed Sep 24, 2023
1 parent 341ac89 commit 866369a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,11 @@ export function* pngReader(data: Readonly<Uint8Array>) {
i += 4;
const tag = dv.getUint32(i, false);
i += 4;
yield [tag, data.subarray(i, i + size)] as [number, Uint8Array];
const d = data.subarray(i, i + size);
i += size;
const crc = dv.getUint32(i, false);
yield [tag, d, crc] as [number, Uint8Array, number];
i += 4;
}
}

Expand Down

0 comments on commit 866369a

Please sign in to comment.