[DEV] set game working
This commit is contained in:
parent
427607da70
commit
fe0e00a356
@ -82,9 +82,9 @@ class PngEncoderLogic {
|
||||
final byte[] scanlineBytes;
|
||||
|
||||
if (bufferedImage.hasAlpha()) {
|
||||
scanlineBytes = ToolImage.convertInByteBufferRGBA(bufferedImage);
|
||||
scanlineBytes = ToolImage.pngConvertInByteBufferRGBA(bufferedImage);
|
||||
} else {
|
||||
scanlineBytes = ToolImage.convertInByteBufferRGB(bufferedImage);
|
||||
scanlineBytes = ToolImage.pngConvertInByteBufferRGB(bufferedImage);
|
||||
}
|
||||
|
||||
final int segmentMaxLengthOriginal = PngEncoderDeflaterOutputStream.getSegmentMaxLengthOriginal(scanlineBytes.length);
|
||||
@ -95,10 +95,12 @@ class PngEncoderLogic {
|
||||
deflaterOutputStream.write(scanlineBytes);
|
||||
deflaterOutputStream.finish();
|
||||
deflaterOutputStream.flush();
|
||||
//deflaterOutputStream.close();
|
||||
} else {
|
||||
PngEncoderDeflaterOutputStream deflaterOutputStream = new PngEncoderDeflaterOutputStream(idatChunksOutputStream, compressionLevel, segmentMaxLengthOriginal);
|
||||
deflaterOutputStream.write(scanlineBytes);
|
||||
deflaterOutputStream.finish();
|
||||
//deflaterOutputStream.close();
|
||||
}
|
||||
|
||||
countingOutputStream.write(PngEncoderLogic.FILE_ENDING);
|
||||
|
Loading…
x
Reference in New Issue
Block a user