diff options
author | Vladislav Hristov <vhristov@mm-sol.com> | 2011-09-14 14:50:44 -0700 |
---|---|---|
committer | Iliyan Malchev <malchev@google.com> | 2011-09-14 16:00:43 -0700 |
commit | 0579e5e597f9504389905ba5cdc9dbf0a6cd014e (patch) | |
tree | 8843e92eb8f2f181191220b4634f6d4a2b660308 /test | |
parent | 76f0345d0475def0f0c6fd2da7c2b35ed8a1bb2a (diff) | |
download | omap4xxx-omapzoom-0579e5e597f9504389905ba5cdc9dbf0a6cd014e.tar.gz |
Camera_test: remove O_SYNC on image files
When O_SYNC is set it takes very long time, to save
the file. This is unnecessary, so we can remove this
flag and have fast capture test.
Change-Id: I0edca1445cf5c1a1aa68fed2e127d10dce50535e
Signed-off-by: Vladislav Hristov <vhristov@mm-sol.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/CameraHal/camera_test_menu.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/CameraHal/camera_test_menu.cpp b/test/CameraHal/camera_test_menu.cpp index e365444a..f8ef2b1b 100644 --- a/test/CameraHal/camera_test_menu.cpp +++ b/test/CameraHal/camera_test_menu.cpp @@ -467,7 +467,7 @@ void my_raw_callback(const sp<IMemory>& mem) { fn[0] = 0; sprintf(fn, "/sdcard/img%03d.raw", counter); - fd = open(fn, O_CREAT | O_WRONLY | O_SYNC | O_TRUNC, 0777); + fd = open(fn, O_CREAT | O_WRONLY | O_TRUNC, 0777); if (fd < 0) goto out; @@ -511,7 +511,7 @@ void saveFile(const sp<IMemory>& mem) { fn[0] = 0; sprintf(fn, "/sdcard/preview%03d.yuv", counter); - fd = open(fn, O_CREAT | O_WRONLY | O_SYNC | O_TRUNC, 0777); + fd = open(fn, O_CREAT | O_WRONLY | O_TRUNC, 0777); if(fd < 0) { LOGE("Unable to open file %s: %s", fn, strerror(fd)); goto out; @@ -600,7 +600,7 @@ void my_jpeg_callback(const sp<IMemory>& mem) { fn[0] = 0; sprintf(fn, "%s/img%03d.jpg", dir_path,counter); - fd = open(fn, O_CREAT | O_WRONLY | O_SYNC | O_TRUNC, 0777); + fd = open(fn, O_CREAT | O_WRONLY | O_TRUNC, 0777); if(fd < 0) { LOGE("Unable to open file %s: %s", fn, strerror(fd)); |