summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/CameraSettings.java
diff options
context:
space:
mode:
authorSteve Kondik <shade@chemlab.org>2013-12-23 22:58:07 -0800
committerArne Coucheron <arco68@gmail.com>2018-01-26 00:51:12 +0100
commit79a276070e613e9b04ad0c06036a876c0602d941 (patch)
treec8f7560bfd53a8d096e8178f0beb865ce4b274b5 /src/com/android/camera/CameraSettings.java
parentc02e557b58cf40aa235d0449f55ea681e6bb3ec4 (diff)
downloadandroid_packages_apps_Snap-79a276070e613e9b04ad0c06036a876c0602d941.tar.gz
android_packages_apps_Snap-79a276070e613e9b04ad0c06036a876c0602d941.tar.bz2
android_packages_apps_Snap-79a276070e613e9b04ad0c06036a876c0602d941.zip
camera: Proper fix for the missing video-sizes issue
* Just honor the defined camcorder profiles. Change-Id: I83e8fe2ca9bb489332f37767906bc7c56389f949
Diffstat (limited to 'src/com/android/camera/CameraSettings.java')
-rw-r--r--src/com/android/camera/CameraSettings.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/com/android/camera/CameraSettings.java b/src/com/android/camera/CameraSettings.java
index b3272c7b5..9f98efffa 100644
--- a/src/com/android/camera/CameraSettings.java
+++ b/src/com/android/camera/CameraSettings.java
@@ -1341,6 +1341,10 @@ public class CameraSettings {
}
private static boolean checkSupportedVideoQuality(Parameters parameters,int width, int height){
List <Size> supported = parameters.getSupportedVideoSizes();
+ if (supported == null) {
+ // video-size not specified in parameter list. just go along with the profile.
+ return true;
+ }
int flag = 0;
for (Size size : supported){
//since we are having two profiles with same height, we are checking with height
@@ -1364,8 +1368,7 @@ public class CameraSettings {
private static ArrayList<String> getSupportedVideoQuality(int cameraId,Parameters parameters) {
ArrayList<String> supported = new ArrayList<String>();
// Check for supported quality
- if (ApiHelper.HAS_FINE_RESOLUTION_QUALITY_LEVELS &&
- parameters.getSupportedVideoSizes() != null) {
+ if (ApiHelper.HAS_FINE_RESOLUTION_QUALITY_LEVELS) {
getFineResolutionQuality(supported,cameraId,parameters);
} else {
supported.add(Integer.toString(CamcorderProfile.QUALITY_HIGH));