我在谷歌上寻找前置手电筒作为手电筒使用,但我无法找到任何答案。如果有,有没有办法?怎么做?
发布于 2020-02-08 00:56:43
打开前置摄像头手电筒的
示例:
CameraManager cameraManager = (CameraManager) getSystemService(Context.CAMERA_SERVICE);
String cameraId = cameraManager.getCameraIdList()[1]; //Id 1 is front camera
cameraManager.setTorchMode(cameraId, true);https://stackoverflow.com/questions/60117589
复制相似问题