Is there any way to mute the camera shutter sound in Android (not rooted phone)?
I use this code to mute my audio sound when taking picture:
AudioM
Since API level 17 (4.2) there is a proper, reliable way to do this, if the phone manufacturer supports it.
First, detect whether you can disable the shutter sound programatically, then disable it
Camera.CameraInfo info = new Camera.CameraInfo();
Camera.getCameraInfo(id, info);
if (info.canDisableShutterSound) {
mCamera.enableShutterSound(false)
}
You'll need to set id to the appropriate camera id in the call to Camera.getCameraInfo, or disable them all in a loop from 0 to Camera.getNumberOfCameras()- 1.
The developer documentation recommends that you play another sound in place of the shutter sound, but you're not obliged to.