The size of a sample is stored in bitsPerSample, which allows sub-byte values (i.e. values not divisible by 8). As a result, sample data could span byte boundaries.
Since many images use this method (it allows for smaller files), we need to support this. However, it will require fancy handling, because DataView only allows reading a minimum of one byte at a time.
The size of a sample is stored in bitsPerSample, which allows sub-byte values (i.e. values not divisible by 8). As a result, sample data could span byte boundaries.
Since many images use this method (it allows for smaller files), we need to support this. However, it will require fancy handling, because DataView only allows reading a minimum of one byte at a time.