encodeToPng

fun encodeToPng(page: EpubPage, scale: Double = 1.0, background: Int = Color.WHITE, theme: ReaderTheme? = null): ByteArray

Convenience: render and return PNG bytes.


fun encodeToPng(page: EpubPage, scale: Double = 1.0, background: Int = Color.WHITE, theme: ReaderTheme? = null, maxPixels: Long): ByteArray

encodeToPng with an explicit allocation ceiling.