Fix readBitPacked for 17+ bitwidth

This commit is contained in:
Kenny Daniel 2024-06-13 00:10:45 -07:00
parent b22416d7f1
commit 72cdffef7c
No known key found for this signature in database
GPG Key ID: 90AB653A8CAD7E45

@ -97,7 +97,7 @@ function readBitPacked(reader, header, bitWidth, output, seen) {
if (right > 8) {
right -= 8
left -= 8
data >>= 8
data >>>= 8
} else if (left - right < bitWidth) {
// if we don't have bitWidth number of bits to read, read next byte
data |= reader.view.getUint8(reader.offset) << left