fixed bitwise overflow glitch in PNG alpha channel
This commit is contained in:
parent
f27fcc934b
commit
d03261cb90
|
@ -1084,7 +1084,7 @@ public class EaglerAdapterImpl2 {
|
||||||
int[] pixels = new int[totalPixels];
|
int[] pixels = new int[totalPixels];
|
||||||
for(int i = 0, j; i < pixels.length; ++i) {
|
for(int i = 0, j; i < pixels.length; ++i) {
|
||||||
j = dv.getUint32(i << 2, false);
|
j = dv.getUint32(i << 2, false);
|
||||||
pixels[i] = (j >> 8) | ((j & 0xFF) << 24);
|
pixels[i] = ((j >> 8) & 0xFFFFFF) | ((j & 0xFF) << 24);
|
||||||
}
|
}
|
||||||
ret.complete(new EaglerImage(pixels, pxlsDat.getWidth(), pxlsDat.getHeight(), true));
|
ret.complete(new EaglerImage(pixels, pxlsDat.getWidth(), pxlsDat.getHeight(), true));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user