mirror of
https://github.com/revanced/Apktool.git
synced 2025-01-06 10:05:54 +01:00
code style cleanup
This commit is contained in:
parent
c3ea300b96
commit
a00da345b2
@ -41,8 +41,8 @@ public class Res9patchStreamDecoder implements ResStreamDecoder {
|
||||
BufferedImage im = ImageIO.read(new ByteArrayInputStream(data));
|
||||
int w = im.getWidth(), h = im.getHeight();
|
||||
|
||||
BufferedImage im2 = new BufferedImage(w+2, h+2, BufferedImage.TYPE_INT_ARGB);
|
||||
if(im.getType() == BufferedImage.TYPE_CUSTOM) {
|
||||
BufferedImage im2 = new BufferedImage(w + 2, h + 2, BufferedImage.TYPE_INT_ARGB);
|
||||
if (im.getType() == BufferedImage.TYPE_CUSTOM) {
|
||||
//TODO: Ensure this is gray + alpha case?
|
||||
Raster srcRaster = im.getRaster();
|
||||
WritableRaster dstRaster = im2.getRaster();
|
||||
@ -51,10 +51,10 @@ public class Res9patchStreamDecoder implements ResStreamDecoder {
|
||||
gray = srcRaster.getSamples(0, y, w, 1, 0, gray);
|
||||
alpha = srcRaster.getSamples(0, y, w, 1, 1, alpha);
|
||||
|
||||
dstRaster.setSamples(1, y+1, w, 1, 0, gray);
|
||||
dstRaster.setSamples(1, y+1, w, 1, 1, gray);
|
||||
dstRaster.setSamples(1, y+1, w, 1, 2, gray);
|
||||
dstRaster.setSamples(1, y+1, w, 1, 3, alpha);
|
||||
dstRaster.setSamples(1, y + 1, w, 1, 0, gray);
|
||||
dstRaster.setSamples(1, y + 1, w, 1, 1, gray);
|
||||
dstRaster.setSamples(1, y + 1, w, 1, 2, gray);
|
||||
dstRaster.setSamples(1, y + 1, w, 1, 3, alpha);
|
||||
}
|
||||
} else {
|
||||
im2.createGraphics().drawImage(im, 1, 1, w, h, null);
|
||||
|
Loading…
Reference in New Issue
Block a user