diff options
author | James Dong <jdong@google.com> | 2011-11-08 07:00:34 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2011-11-08 07:00:34 +0000 |
commit | 6a9ab553ebd36705d3edacc6deb6a27dd6b799a3 (patch) | |
tree | 0343ba567b6bf72855b11a8a254fea35b587c67f /media/libstagefright/CameraSourceTimeLapse.cpp | |
parent | 78df57fff35a38ab6d68526d340b2853d25721ae (diff) | |
parent | 49e82712b2b7072bb8b8d6e2c86115eaa82e9943 (diff) | |
download | frameworks_av-6a9ab553ebd36705d3edacc6deb6a27dd6b799a3.zip frameworks_av-6a9ab553ebd36705d3edacc6deb6a27dd6b799a3.tar.gz frameworks_av-6a9ab553ebd36705d3edacc6deb6a27dd6b799a3.tar.bz2 |
am ee7ebb32: Merge "Fix a hang issue where the first frame can be dropped for timelapse video recording." into ics-mr1
* commit 'ee7ebb3257d9337627b175835dc3d08f9b8ab339':
Fix a hang issue where the first frame can be dropped for timelapse video recording.
Diffstat (limited to 'media/libstagefright/CameraSourceTimeLapse.cpp')
-rw-r--r-- | media/libstagefright/CameraSourceTimeLapse.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/media/libstagefright/CameraSourceTimeLapse.cpp b/media/libstagefright/CameraSourceTimeLapse.cpp index 3c4885a..23e6e35 100644 --- a/media/libstagefright/CameraSourceTimeLapse.cpp +++ b/media/libstagefright/CameraSourceTimeLapse.cpp @@ -257,6 +257,12 @@ bool CameraSourceTimeLapse::skipFrameAndModifyTimeStamp(int64_t *timestampUs) { mForceRead = false; *timestampUs = mLastFrameTimestampUs + mTimeBetweenTimeLapseVideoFramesUs; + + // Really make sure that this video recording frame will not be dropped. + if (*timestampUs < mStartTimeUs) { + LOGI("set timestampUs to start time stamp %lld us", mStartTimeUs); + *timestampUs = mStartTimeUs; + } return false; } } |