0

I’m trying to write a flashlight app for Android. The standard API to turn on the flashlight is:

val cameraManager = getSystemService(Context.CAMERA_SERVICE) as CameraManager
        try {
            val cameraId = cameraManager.cameraIdList[0]
            cameraManager.setTorchMode(cameraId, true)
        } catch (e: CameraAccessException) {
        }

However on my Galaxy S10 just turning on like this sets the brightness at 3 of 5. I’m wondering if the flashlight brightness is accessible to a developer, perhaps by modifying a system file like what used to be possible with some HCL phones.

AFAIK Samsung does not have a Galaxy Camera SDK anymore (and even if it did IDK if you can control brightness with it). Could anyone "shed some light" on the situation?

P.S. I've already looked thru all the links given here.

0 Answers0