always use the max possible preview in video

This commit is contained in:
Tibor Kaputa 2016-11-24 14:35:08 +01:00
parent e68384100a
commit 69c269d7c6

View File

@ -633,13 +633,9 @@ public class Preview extends ViewGroup
return false;
mSwitchToVideoAsap = false;
Camera.Size preferred = mParameters.getPreferredPreviewSizeForVideo();
if (preferred == null) {
final List<Camera.Size> previewSizes = mParameters.getSupportedPreviewSizes();
Collections.sort(previewSizes, new SizesComparator());
preferred = previewSizes.get(0);
}
Camera.Size preferred = previewSizes.get(0);
mParameters.setPreviewSize(preferred.width, preferred.height);
mCamera.setParameters(mParameters);
@ -759,7 +755,7 @@ public class Preview extends ViewGroup
if (file.exists() && file.length() == 0) {
file.delete();
}
}
}
private void toggleShutterSound(Boolean mute) {
if (!Config.Companion.newInstance(mContext).isSoundEnabled()) {