Fix webtoon down sampling

This commit is contained in:
tarsin committed 2022-12-11 11:57:39 +08:00
1 parent 85b559c989
commit 45f67ec37f
1 file changed
+2 -1
+2 -1
View File
@@ -35,6 +35,7 @@ import java.io.FileInputStream
import java.nio.ByteBuffer
import java.nio.channels.FileChannel
import kotlin.math.max
import kotlin.math.min
class Image private constructor(
source: Source?, drawable: Drawable? = null,
@@ -55,7 +56,7 @@ class Image private constructor(
decoder.setTargetSampleSize(
max(
max(
min(
info.size.width / (2 * screenWidth),
info.size.height / (2 * screenHeight)
), 1