summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJames Dong <jdong@google.com>2010-07-22 16:28:26 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-07-22 16:28:26 -0700
commit55cb2b8319e6b36e88658de121c534e95cd240b4 (patch)
treec6d266f434dacf09eeb964d05090088f78f4d3d2 /include
parentf661058d77d1484e5911d1962f8e1e8466240687 (diff)
parent00fba4994e33d1b8384ff8bc2221c2de933f387e (diff)
downloadframeworks_av-55cb2b8319e6b36e88658de121c534e95cd240b4.zip
frameworks_av-55cb2b8319e6b36e88658de121c534e95cd240b4.tar.gz
frameworks_av-55cb2b8319e6b36e88658de121c534e95cd240b4.tar.bz2
am 9bc4dc11: am 53d4e0d5: Allows the authoring engine to skip frame.
Merge commit '9bc4dc114fce58606a81d65d4cb31348cc7c1bae' * commit '9bc4dc114fce58606a81d65d4cb31348cc7c1bae': Allows the authoring engine to skip frame.
Diffstat (limited to 'include')
-rw-r--r--include/media/stagefright/MediaSource.h13
-rw-r--r--include/media/stagefright/OMXCodec.h1
2 files changed, 14 insertions, 0 deletions
diff --git a/include/media/stagefright/MediaSource.h b/include/media/stagefright/MediaSource.h
index a31395e..dafc621 100644
--- a/include/media/stagefright/MediaSource.h
+++ b/include/media/stagefright/MediaSource.h
@@ -78,18 +78,31 @@ struct MediaSource : public RefBase {
void clearSeekTo();
bool getSeekTo(int64_t *time_us, SeekMode *mode) const;
+ // Option allows encoder to skip some frames until the specified
+ // time stamp.
+ // To prevent from being abused, when the skipFrame timestamp is
+ // found to be more than 1 second later than the current timestamp,
+ // an error will be returned from read().
+ void clearSkipFrame();
+ bool getSkipFrame(int64_t *timeUs) const;
+ void setSkipFrame(int64_t timeUs);
+
void setLateBy(int64_t lateness_us);
int64_t getLateBy() const;
private:
enum Options {
+ // Bit map
kSeekTo_Option = 1,
+ kSkipFrame_Option = 2,
};
uint32_t mOptions;
int64_t mSeekTimeUs;
SeekMode mSeekMode;
int64_t mLatenessUs;
+
+ int64_t mSkipFrameUntilTimeUs;
};
// Causes this source to suspend pulling data from its upstream source
diff --git a/include/media/stagefright/OMXCodec.h b/include/media/stagefright/OMXCodec.h
index 79e7a2f..6c6949b 100644
--- a/include/media/stagefright/OMXCodec.h
+++ b/include/media/stagefright/OMXCodec.h
@@ -143,6 +143,7 @@ private:
int64_t mSeekTimeUs;
ReadOptions::SeekMode mSeekMode;
int64_t mTargetTimeUs;
+ int64_t mSkipTimeUs;
MediaBuffer *mLeftOverBuffer;