Upgrade widevine HIDL service to v1.1.

Merged from http://go/wvgerrit/44803.

Upgrade HIDL service to v1.1 and implements new 1.1 media API.

Test: Netflix and Play Movies & TV
  streaming and offline playback

Test: GTS WidevineH264PlaybackTests test
  e.g. ANDROID_BUILD_TOP= ./android-gts/tools/gts-tradefed run gts -m GtsMediaTestCases
  --test com.google.android.media.gts.WidevineH264PlaybackTests#testL1With480P30

Test: GTS MediaDrmTest tests
  e.g. ANDROID_BUILD_TOP= ./android-gts/tools/gts-tradefed run gts -m GtsMediaTestCases
  --test com.google.android.media.gts.MediaDrmTest#testWidevineApi28

Test: unit tests

bug: 69674645
Change-Id: I91e7e43f9178b61a531e846beffb5f5c17050a3c
This commit is contained in:
Edwin Wong
2018-02-06 10:53:10 -08:00
parent efc008c5a1
commit bc66aebfe2
24 changed files with 447 additions and 89 deletions

View File

@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef WVDRM_ANDROID_HARDWARE_DRM_V1_0_TYPECONVERT
#define WVDRM_ANDROID_HARDWARE_DRM_V1_0_TYPECONVERT
#ifndef WVDRM_ANDROID_HARDWARE_DRM_V1_1_TYPECONVERT
#define WVDRM_ANDROID_HARDWARE_DRM_V1_1_TYPECONVERT
#include "utils/Errors.h"
#include <vector>
@@ -26,7 +26,7 @@
namespace android {
namespace hardware {
namespace drm {
namespace V1_0 {
namespace V1_1 {
namespace widevine {
using ::android::hardware::hidl_array;
@@ -71,7 +71,7 @@ template<typename T, size_t SIZE> std::vector<T> toVector(
}
} // namespace widevine
} // namespace V1_0
} // namespace V1_1
} // namespace drm
} // namespace hardware
} // namespace android

View File

@@ -5,17 +5,17 @@
#ifndef WV_CREATE_PLUGIN_FACTORIES_H_
#define WV_CREATE_PLUGIN_FACTORIES_H_
#include <android/hardware/drm/1.0/ICryptoFactory.h>
#include <android/hardware/drm/1.0/IDrmFactory.h>
#include <android/hardware/drm/1.1/ICryptoFactory.h>
#include <android/hardware/drm/1.1/IDrmFactory.h>
namespace wvdrm {
namespace hardware {
namespace drm {
namespace V1_0 {
namespace V1_1 {
namespace widevine {
using ::android::hardware::drm::V1_0::ICryptoFactory;
using ::android::hardware::drm::V1_0::IDrmFactory;
using ::android::hardware::drm::V1_1::ICryptoFactory;
using ::android::hardware::drm::V1_1::IDrmFactory;
extern "C" {
IDrmFactory* createDrmFactory();
@@ -23,7 +23,7 @@ extern "C" {
}
} // namespace widevine
} // namespace V1_0
} // namespace V1_1
} // namespace drm
} // namespace hardware
} // namespace wvdrm

View File

@@ -5,17 +5,17 @@
#ifndef WV_CRYPTO_FACTORY_H_
#define WV_CRYPTO_FACTORY_H_
#include <android/hardware/drm/1.0/ICryptoFactory.h>
#include <android/hardware/drm/1.1/ICryptoFactory.h>
#include "WVTypes.h"
namespace wvdrm {
namespace hardware {
namespace drm {
namespace V1_0 {
namespace V1_1 {
namespace widevine {
using ::android::hardware::drm::V1_0::ICryptoFactory;
using ::android::hardware::drm::V1_1::ICryptoFactory;
using ::android::hardware::drm::V1_0::ICryptoPlugin;
using ::android::hardware::hidl_array;
using ::android::hardware::hidl_vec;
@@ -39,7 +39,7 @@ struct WVCryptoFactory : public ICryptoFactory {
};
} // namespace widevine
} // namespace V1_0
} // namespace V1_1
} // namespace drm
} // namespace hardware
} // namespace wvdrm

View File

@@ -5,7 +5,8 @@
#ifndef WV_DRM_FACTORY_H_
#define WV_DRM_FACTORY_H_
#include <android/hardware/drm/1.0/IDrmFactory.h>
#include <android/hardware/drm/1.1/IDrmFactory.h>
#include <android/hardware/drm/1.1/IDrmPlugin.h>
#include "WVGenericCryptoInterface.h"
#include "WVTypes.h"
@@ -13,11 +14,11 @@
namespace wvdrm {
namespace hardware {
namespace drm {
namespace V1_0 {
namespace V1_1 {
namespace widevine {
using ::android::hardware::drm::V1_0::IDrmFactory;
using ::android::hardware::drm::V1_0::IDrmPlugin;
using ::android::hardware::drm::V1_1::IDrmFactory;
using ::android::hardware::drm::V1_1::IDrmPlugin;
using ::android::hardware::hidl_array;
using ::android::hardware::hidl_string;
using ::android::hardware::Return;
@@ -50,7 +51,7 @@ struct WVDrmFactory : public IDrmFactory {
extern "C" IDrmFactory* HIDL_FETCH_IDrmFactory(const char* name);
} // namespace widevine
} // namespace V1_0
} // namespace V1_1
} // namespace drm
} // namespace hardware
} // namespace wvdrm