summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/SampleIterator.cpp
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2011-02-03 13:18:16 -0800
committerAndreas Huber <andih@google.com>2011-02-03 16:08:30 -0800
commitbd352c3cdc6a8682dae58a5108c82a303be05274 (patch)
treea4a6fb99fe36e2b825975d917dcc2b02c3f3a0c0 /media/libstagefright/SampleIterator.cpp
parent23a8a45928c85d779e894b6e82697537194b9e4a (diff)
downloadframeworks_base-bd352c3cdc6a8682dae58a5108c82a303be05274.zip
frameworks_base-bd352c3cdc6a8682dae58a5108c82a303be05274.tar.gz
frameworks_base-bd352c3cdc6a8682dae58a5108c82a303be05274.tar.bz2
Make sure timestamps attached to encoded media are composition timestamps.
not decoding timestamps. Obviously there is no difference between them if the content in question does not involve frame reordering. Change-Id: Iac4d06cfeb8a136f735c1148e98cac340d3ef893 related-to-bug: 3398314
Diffstat (limited to 'media/libstagefright/SampleIterator.cpp')
-rw-r--r--media/libstagefright/SampleIterator.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/media/libstagefright/SampleIterator.cpp b/media/libstagefright/SampleIterator.cpp
index 062ab9b..c7b00b1 100644
--- a/media/libstagefright/SampleIterator.cpp
+++ b/media/libstagefright/SampleIterator.cpp
@@ -307,6 +307,8 @@ status_t SampleIterator::findSampleTime(
*time = mTTSSampleTime + mTTSDuration * (sampleIndex - mTTSSampleIndex);
+ *time += mTable->getCompositionTimeOffset(sampleIndex);
+
return OK;
}