summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDimitar Borisov <x0152684@ti.com>2012-09-29 11:42:16 +0300
committerDaniel Levin <dendy@ti.com>2012-11-26 18:58:11 +0200
commitd458f243fccabfa85a3705e56708b097a70d7a6d (patch)
tree84ff516c1529d08681b3bb5fe656625435d274ba /test
parentfdf88db2eb1a57e701ade1e4ca9e558a4073e7ed (diff)
downloadhardware_ti_omap4-d458f243fccabfa85a3705e56708b097a70d7a6d.zip
hardware_ti_omap4-d458f243fccabfa85a3705e56708b097a70d7a6d.tar.gz
hardware_ti_omap4-d458f243fccabfa85a3705e56708b097a70d7a6d.tar.bz2
Camera_test: Video mode fix
When start recoding camera is not in video mode but in HQ mode. This is because the width and height are different for preview and video recording. Preview is restarted and in this case the mode is lost and the default HQ mode is set. To prevent this behaviour width and height for the preview are set the same as for video recording. Change-Id: I72df65f7732b3f4067cd4b3e9b5047081a0b0dd7 Signed-off-by: Dimitar Borisov <x0152684@ti.com>
Diffstat (limited to 'test')
-rw-r--r--test/CameraHal/camera_test_menu.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/CameraHal/camera_test_menu.cpp b/test/CameraHal/camera_test_menu.cpp
index 03affe8..23e691d 100644
--- a/test/CameraHal/camera_test_menu.cpp
+++ b/test/CameraHal/camera_test_menu.cpp
@@ -1303,7 +1303,11 @@ int startPreview() {
params.set(KEY_S3D_CAP_FRAME_LAYOUT, stereoCapLayout[stereoCapLayoutIDX]);
}
- params.setPreviewSize(preview_Array[previewSizeIDX]->width, preview_Array[previewSizeIDX]->height);
+ if ((cameraInfo.orientation == 90 || cameraInfo.orientation == 270) && recordingMode) {
+ params.setPreviewSize(previewHeight, previewWidth);
+ } else {
+ params.setPreviewSize(previewWidth, previewHeight);
+ }
params.setPictureSize(capture_Array[captureSizeIDX]->width, capture_Array[captureSizeIDX]->height);
// calculate display orientation from sensor orientation