diff options
author | qinmin@chromium.org <qinmin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-28 22:51:27 +0000 |
---|---|---|
committer | qinmin@chromium.org <qinmin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-28 22:51:27 +0000 |
commit | 61f198e295225f7081a67e12af665296dbc49996 (patch) | |
tree | 40562c7893cbb60995a0638267ac216a4b05cab7 /media/base/android/media_source_player.h | |
parent | 867b38c53e00420ea92f4901f2afdde35bc5f551 (diff) | |
download | chromium_src-61f198e295225f7081a67e12af665296dbc49996.zip chromium_src-61f198e295225f7081a67e12af665296dbc49996.tar.gz chromium_src-61f198e295225f7081a67e12af665296dbc49996.tar.bz2 |
Fix the resource management issue for MediaSourcePlayer
For MediaSourcePlayer, we did not handle the resource counting correctly.
1.When a video decoder job starts decoding, we did not report to the manager
2.When the video decoder job gets killed, the resources are not immediately released.
We have to wait until the decoder finishes decoding the current chunk.
This change passes callbacks to MediaSourcePlayer so that VideoDecoderJob can use callbacks to inform BrowserMediaPlayerManager that it needs to acquire or release resources.
BUG=348065
Review URL: https://codereview.chromium.org/182403002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254259 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/base/android/media_source_player.h')
-rw-r--r-- | media/base/android/media_source_player.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/media/base/android/media_source_player.h b/media/base/android/media_source_player.h index f6d99a6..4a764cd 100644 --- a/media/base/android/media_source_player.h +++ b/media/base/android/media_source_player.h @@ -41,6 +41,8 @@ class MEDIA_EXPORT MediaSourcePlayer : public MediaPlayerAndroid, // the lifetime of this object. MediaSourcePlayer(int player_id, MediaPlayerManager* manager, + const RequestMediaResourcesCB& request_media_resources_cb, + const ReleaseMediaResourcesCB& release_media_resources_cb, scoped_ptr<DemuxerAndroid> demuxer); virtual ~MediaSourcePlayer(); |