Skip to content

Commit

Permalink
Merge branch 'kim/refactor/captureModes/update_useCaseMode_to_capture…
Browse files Browse the repository at this point in the history
…Mode' into kim/refactor/captureModes/captureMode_Ui
  • Loading branch information
Kimblebee committed Feb 4, 2025
2 parents 17106ad + 1b10158 commit 4f7b60e
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -423,13 +423,12 @@ internal fun createUseCaseGroup(
}.build()
}

private fun getVideoQualityFromResolution(resolution: Size?): VideoQuality {
return resolution?.let { res ->
private fun getVideoQualityFromResolution(resolution: Size?): VideoQuality =
resolution?.let { res ->
QUALITY_RANGE_MAP.firstNotNullOfOrNull {
if (it.value.contains(res.height)) it.key else null
}
} ?: VideoQuality.UNSPECIFIED
}

private fun getWidthFromCropRect(cropRect: Rect?): Int {
if (cropRect == null) {
Expand Down

0 comments on commit 4f7b60e

Please # to comment.