decodeSampledBitmap

fun String.decodeSampledBitmap(maxDimension: Int = 1024): Bitmap?

Decodes a file-backed bitmap with maxDimension cap to avoid OOM on large photos.