From 8e1b6cce24574b9ecd5b0300155776bd0b4ef756 Mon Sep 17 00:00:00 2001 From: Nicolas Catania Date: Thu, 9 Jul 2009 09:21:33 -0700 Subject: Basic plumbing to retrieve metadata from the native player. IMediaPlayer.h Added a getMetadata method that mirrors the on in MediaPlayer.java. MediaPlayer.java Added a native method to get the metadata from the native player. Parse the parcel into a Metadata object. Metadata.java Added a stub to parse the Parcel returned by the native player into a set of metadata. android_media_MediaPlayer.cpp JNI call to forward the getMetadata call. MediaPlayerService.cpp MediaPlayerService::Client implements the new getMetadata method added in IMediaPlayer.h --- media/libmediaplayerservice/MediaPlayerService.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'media/libmediaplayerservice/MediaPlayerService.cpp') diff --git a/media/libmediaplayerservice/MediaPlayerService.cpp b/media/libmediaplayerservice/MediaPlayerService.cpp index 3adbfac..04aab81 100644 --- a/media/libmediaplayerservice/MediaPlayerService.cpp +++ b/media/libmediaplayerservice/MediaPlayerService.cpp @@ -846,6 +846,16 @@ status_t MediaPlayerService::Client::setMetadataFilter(const Parcel& filter) return status; } +status_t MediaPlayerService::Client::getMetadata(bool update_only, bool apply_filter, Parcel *metadata) +{ + status_t status; + metadata->writeInt32(-1); // Placeholder for the return code + + // FIXME: Implement, query the native player and do the optional filtering, etc... + status = OK; + return status; +} + status_t MediaPlayerService::Client::prepareAsync() { LOGV("[%d] prepareAsync", mConnId); -- cgit v1.1