Skip to content

Commit

Permalink
Get size with sample size
Browse files Browse the repository at this point in the history
  • Loading branch information
kylecorry31 committed Oct 13, 2024
1 parent 70103e5 commit d402280
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,11 @@ object BitmapUtils {
}
}

fun sampleSizeToScale(sampleSize: Int): Float {
return 1f / sampleSize
fun getSizeWithSampleSize(sampleSize: Int, originalSize: Size): Size {
return Size(
originalSize.width / sampleSize,
originalSize.height / sampleSize
)
}

/**
Expand Down

0 comments on commit d402280

Please sign in to comment.