diff options
author | Andreas Huber <andih@google.com> | 2011-04-21 10:06:43 -0700 |
---|---|---|
committer | James Dong <jdong@google.com> | 2011-05-10 15:49:47 -0700 |
commit | 681755fc0d0797506456f46a2a10555916d6be32 (patch) | |
tree | d31d9bb4e4b58795854e18b623dcf9459ecf34ef /media/libstagefright/WVMExtractor.cpp | |
parent | 1a65546a55d019335655464ad895361ba9f89252 (diff) | |
download | frameworks_av-681755fc0d0797506456f46a2a10555916d6be32.zip frameworks_av-681755fc0d0797506456f46a2a10555916d6be32.tar.gz frameworks_av-681755fc0d0797506456f46a2a10555916d6be32.tar.bz2 |
Using widevine:// to stream adaptive bitrate wvm content no longer
uses stagefright's http cache but defers caching to the WVMExtractor, which
now has the responsibility of reporting buffer status/duration.
Change-Id: Ieec64a20203977fd0a61d0c6834da124de78bfa2
related-to-bug: 4390283
Diffstat (limited to 'media/libstagefright/WVMExtractor.cpp')
-rw-r--r-- | media/libstagefright/WVMExtractor.cpp | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/media/libstagefright/WVMExtractor.cpp b/media/libstagefright/WVMExtractor.cpp index 7c72852..83a1eaa 100644 --- a/media/libstagefright/WVMExtractor.cpp +++ b/media/libstagefright/WVMExtractor.cpp @@ -45,7 +45,8 @@ namespace android { static Mutex gWVMutex; WVMExtractor::WVMExtractor(const sp<DataSource> &source) - : mDataSource(source) { + : mDataSource(source), + mUseAdaptiveStreaming(false) { { Mutex::Autolock autoLock(gWVMutex); if (gVendorLibHandle == NULL) { @@ -100,5 +101,21 @@ sp<MetaData> WVMExtractor::getMetaData() { return mImpl->getMetaData(); } +int64_t WVMExtractor::getCachedDurationUs(status_t *finalStatus) { + // TODO: Fill this with life. + + *finalStatus = OK; + + return 0; +} + +void WVMExtractor::setAdaptiveStreamingMode(bool adaptive) { + mUseAdaptiveStreaming = adaptive; +} + +bool WVMExtractor::getAdaptiveStreamingMode() const { + return mUseAdaptiveStreaming; +} + } //namespace android |