summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/httplive
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2011-03-08 15:59:28 -0800
committerAndreas Huber <andih@google.com>2011-03-09 10:14:46 -0800
commit1156dc913a5ba7b2bc86489468d4914430f03d14 (patch)
tree351803a481df1784b789fdcdfa13cbc9b30a0a12 /media/libstagefright/httplive
parent271151e65fdc289514317b6e4e1b8805e6c647e1 (diff)
downloadframeworks_av-1156dc913a5ba7b2bc86489468d4914430f03d14.zip
frameworks_av-1156dc913a5ba7b2bc86489468d4914430f03d14.tar.gz
frameworks_av-1156dc913a5ba7b2bc86489468d4914430f03d14.tar.bz2
An HTTP datasource for stagefright using the chromium code.
Use of this new datasource is now the default unless overwritten by adb shell setprop media.stagefright.use-chromium false Change-Id: I156a8eb9a1fff1cb537b4aec6cf3e8e6052be81e
Diffstat (limited to 'media/libstagefright/httplive')
-rw-r--r--media/libstagefright/httplive/LiveSession.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/media/libstagefright/httplive/LiveSession.cpp b/media/libstagefright/httplive/LiveSession.cpp
index f0cd6a0..8e1bdf3 100644
--- a/media/libstagefright/httplive/LiveSession.cpp
+++ b/media/libstagefright/httplive/LiveSession.cpp
@@ -23,7 +23,7 @@
#include "LiveDataSource.h"
#include "include/M3UParser.h"
-#include "include/NuHTTPDataSource.h"
+#include "include/HTTPBase.h"
#include <cutils/properties.h>
#include <media/stagefright/foundation/hexdump.h>
@@ -45,9 +45,9 @@ LiveSession::LiveSession(uint32_t flags)
: mFlags(flags),
mDataSource(new LiveDataSource),
mHTTPDataSource(
- new NuHTTPDataSource(
+ HTTPBase::Create(
(mFlags & kFlagIncognito)
- ? NuHTTPDataSource::kFlagIncognito
+ ? HTTPBase::kFlagIncognito
: 0)),
mPrevBandwidthIndex(-1),
mLastPlaylistFetchTimeUs(-1),
@@ -625,7 +625,12 @@ status_t LiveSession::decryptBuffer(
} else {
key = new ABuffer(16);
- sp<NuHTTPDataSource> keySource = new NuHTTPDataSource;
+ sp<HTTPBase> keySource =
+ HTTPBase::Create(
+ (mFlags & kFlagIncognito)
+ ? HTTPBase::kFlagIncognito
+ : 0);
+
status_t err = keySource->connect(keyURI.c_str());
if (err == OK) {