Fixed a bug where png files were not read correctly

This commit is contained in:
Oupson 2021-02-10 12:24:02 +01:00
parent ce6293e88f
commit a37ca949b6
2 changed files with 4 additions and 4 deletions

View File

@ -406,10 +406,10 @@ class ApngDecoder {
body.addAll(Utils.IDAT.asList())
// Get image bytes
body.addAll(
byteArray.slice(
i + 4..
byteArray.copyOfRange(
i + 4,
i + 4 + bodySize
)
).asList()
)
val crC32 = CRC32()
crC32.update(body.toByteArray(), 0, body.size)

View File

@ -375,7 +375,7 @@ class CreatorActivity : AppCompatActivity() {
}
}
runCatching {
runCatching { // TODO
encoder.writeEnd()
}