[Kotlin/Android] How to get boundry values from `Range` type

Android

Cause

I'm implemeniting Android camera appllication and often retrieve range value of some characteristics.

For example

            val characteristics = CameraManagerWrapper.getCharacteristics()
            val range = characteristics?.get(SENSOR_INFO_SENSITIVITY_RANGE)

I want to know How range is ISO be able to be.

val range should be Range[x,y]

How can you guys retrieve boundry values such xand y?

Answer

val min = range.lower
val max = range.upper

Happy Coding for every developer!!

コメント

タイトルとURLをコピーしました