Matteo Granatiero Active Member Licensed User Sep 14, 2019 #1 I tried browsing in the CameraEx class but I can't get it to work. In the original camera2 project I noticed that this code is used but it turns on the flash as a flashlight (in any mode I insert it) for example "OFF", "ON", "ON_AUTO_FLASH", "ON_ALWAYS_FLASH", "ON_AUTO_FLASH_REDEYE" and freezes. I would like a photo style that flashes and takes the picture if activated and if disabled, simply take the picture. Code: Sub btnAutoExposure_Click Dim flashes As List = cam.SupportedAutoExposureModes Dim i As Int = flashes.IndexOf(cam.AutoExposureMode) i = (i + 1) Mod flashes.Size cam.AutoExposureMode = flashes.Get(i) btnAutoExposure.Text = flashes.Get(i) cam.StartPreview(MyTaskIndex, VideoMode) End Sub https://www.b4x.com/android/forum/threads/camera2-new-camera-library.83855/
I tried browsing in the CameraEx class but I can't get it to work. In the original camera2 project I noticed that this code is used but it turns on the flash as a flashlight (in any mode I insert it) for example "OFF", "ON", "ON_AUTO_FLASH", "ON_ALWAYS_FLASH", "ON_AUTO_FLASH_REDEYE" and freezes. I would like a photo style that flashes and takes the picture if activated and if disabled, simply take the picture. Code: Sub btnAutoExposure_Click Dim flashes As List = cam.SupportedAutoExposureModes Dim i As Int = flashes.IndexOf(cam.AutoExposureMode) i = (i + 1) Mod flashes.Size cam.AutoExposureMode = flashes.Get(i) btnAutoExposure.Text = flashes.Get(i) cam.StartPreview(MyTaskIndex, VideoMode) End Sub https://www.b4x.com/android/forum/threads/camera2-new-camera-library.83855/
DonManfred Expert Licensed User Longtime User Sep 14, 2019 #2 Please use [CODE]code here...[/CODE] tags when posting code. Upvote 0