make sure to disable the default shutter sound explicitly
This commit is contained in:
parent
d12f6a7586
commit
a021b1fe80
|
@ -175,6 +175,9 @@ public class Preview extends ViewGroup implements SurfaceHolder.Callback, View.O
|
||||||
parameters.setRotation(rotation % 360);
|
parameters.setRotation(rotation % 360);
|
||||||
|
|
||||||
MediaPlayer.create(getContext(), R.raw.camera_shutter).start();
|
MediaPlayer.create(getContext(), R.raw.camera_shutter).start();
|
||||||
|
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.JELLY_BEAN_MR1) {
|
||||||
|
camera.enableShutterSound(false);
|
||||||
|
}
|
||||||
camera.setParameters(parameters);
|
camera.setParameters(parameters);
|
||||||
camera.takePicture(null, null, takePictureCallback);
|
camera.takePicture(null, null, takePictureCallback);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue