Widevine HLS live stream support for L1 secure playback.

Check in for Jeff Tinker.
BUG 5081725

Change-Id: If1d828e97319788ab52c6f15a7782a1da63d8f20
This commit is contained in:
Edwin Wong
2011-09-08 15:11:37 -07:00
parent 758456e6c7
commit ba14720f8e
7 changed files with 14 additions and 10 deletions

View File

@@ -82,6 +82,7 @@ void WVMMediaSource::allocBufferGroup()
status_t WVMMediaSource::setBuffers(const Vector<MediaBuffer *> &buffers) { status_t WVMMediaSource::setBuffers(const Vector<MediaBuffer *> &buffers) {
#ifdef REQUIRE_SECURE_BUFFERS #ifdef REQUIRE_SECURE_BUFFERS
if (!mIsLiveStream) {
LOGI("Using codec-supplied buffers"); LOGI("Using codec-supplied buffers");
delete mGroup; delete mGroup;
@@ -90,6 +91,9 @@ status_t WVMMediaSource::setBuffers(const Vector<MediaBuffer *> &buffers) {
mGroup->add_buffer(buffers.itemAt(i)); mGroup->add_buffer(buffers.itemAt(i));
} }
return OK; return OK;
} else {
return ERROR_UNSUPPORTED;
}
#else #else
return ERROR_UNSUPPORTED; return ERROR_UNSUPPORTED;
#endif #endif
@@ -160,7 +164,7 @@ sp<MetaData> WVMMediaSource::getFormat()
Mutex::Autolock autoLock(mLock); Mutex::Autolock autoLock(mLock);
#ifdef REQUIRE_SECURE_BUFFERS #ifdef REQUIRE_SECURE_BUFFERS
if (mESSelector == WV_EsSelector_Video) { if (!mIsLiveStream && (mESSelector == WV_EsSelector_Video)) {
mTrackMetaData->setInt32(kKeyRequiresSecureBuffers, true); mTrackMetaData->setInt32(kKeyRequiresSecureBuffers, true);
} }
#endif #endif