summaryrefslogtreecommitdiffstats
path: root/drm/drmserver/DrmManager.cpp
diff options
context:
space:
mode:
authorTakeshi Aimi <aimitakeshi@gmail.com>2010-11-16 13:56:11 +0900
committerTakeshi Aimi <aimitakeshi@gmail.com>2010-11-19 22:02:51 +0900
commit3473846f64f5b28e1cbeb70ef5867073fc93159e (patch)
tree9651de1dd360d8d77d9d4a53a23ed1181845b93c /drm/drmserver/DrmManager.cpp
parentcf6a8d23345a6e54834e53b1eb7e465f3cb5e914 (diff)
downloadframeworks_av-3473846f64f5b28e1cbeb70ef5867073fc93159e.zip
frameworks_av-3473846f64f5b28e1cbeb70ef5867073fc93159e.tar.gz
frameworks_av-3473846f64f5b28e1cbeb70ef5867073fc93159e.tar.bz2
Update of DRM Framework.
-Access permission handling Introduce an internal function which allows the desired process to access decryption flow. This new function is just for reference and each OEM manufacturer should implement/replace with their solutions. -New API, getMetadata() This API is for retrieving media metadata from container-based DRM, such as OMA forward-lock content. This API asks DRM agent to retrieve media metadata hiddein inside of DRM special container. -New API, acquireRights() This API wraps acquireDrmInfo() and processDrmInfo(). If DRM agent has valid implementation of both APIs, Application can acquire DrmRights only by calling this API. -Bug fix in event loop of OnInfoListener. Separate OnInfo event loop from mail thread loop so as to avoid the issue that message is not dispatched when mail thread is busy. Changes are made by SEMC and Sony. Change-Id: I04ee3e0988152a71e221f2256d83253749a29da0
Diffstat (limited to 'drm/drmserver/DrmManager.cpp')
-rw-r--r--drm/drmserver/DrmManager.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/drm/drmserver/DrmManager.cpp b/drm/drmserver/DrmManager.cpp
index b7a035f..537791c 100644
--- a/drm/drmserver/DrmManager.cpp
+++ b/drm/drmserver/DrmManager.cpp
@@ -23,6 +23,7 @@
#include <drm/DrmInfoEvent.h>
#include <drm/DrmRights.h>
#include <drm/DrmConstraints.h>
+#include <drm/DrmMetadata.h>
#include <drm/DrmInfoStatus.h>
#include <drm/DrmInfoRequest.h>
#include <drm/DrmSupportInfo.h>
@@ -148,6 +149,15 @@ DrmConstraints* DrmManager::getConstraints(int uniqueId, const String8* path, co
return NULL;
}
+DrmMetadata* DrmManager::getMetadata(int uniqueId, const String8* path) {
+ const String8 plugInId = getSupportedPlugInIdFromPath(uniqueId, *path);
+ if (EMPTY_STRING != plugInId) {
+ IDrmEngine& rDrmEngine = mPlugInManager.getPlugIn(plugInId);
+ return rDrmEngine.getMetadata(uniqueId, path);
+ }
+ return NULL;
+}
+
status_t DrmManager::installDrmEngine(int uniqueId, const String8& absolutePath) {
mPlugInManager.loadPlugIn(absolutePath);