Handle correct data offset in raw decoder
There is often buffered data ahead of the pixel data so we need to take this in account when making sure pixels are opaque.
This commit is contained in:
@@ -51,7 +51,7 @@ export default class RawDecoder {
|
||||
|
||||
// Max sure the image is fully opaque
|
||||
for (let i = 0; i < pixels; i++) {
|
||||
data[i * 4 + 3] = 255;
|
||||
data[index + i * 4 + 3] = 255;
|
||||
}
|
||||
|
||||
display.blitImage(x, curY, width, currHeight, data, index);
|
||||
|
||||
Reference in New Issue
Block a user