OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ | 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ |
6 #define MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ | 6 #define MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ |
7 | 7 |
8 #include <jni.h> | 8 #include <jni.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 MediaSourcePlayer( | 44 MediaSourcePlayer( |
45 int player_id, | 45 int player_id, |
46 MediaPlayerManager* manager, | 46 MediaPlayerManager* manager, |
47 const OnDecoderResourcesReleasedCB& on_decoder_resources_released_cb, | 47 const OnDecoderResourcesReleasedCB& on_decoder_resources_released_cb, |
48 std::unique_ptr<DemuxerAndroid> demuxer, | 48 std::unique_ptr<DemuxerAndroid> demuxer, |
49 const GURL& frame_url, | 49 const GURL& frame_url, |
50 int media_session_id); | 50 int media_session_id); |
51 ~MediaSourcePlayer() override; | 51 ~MediaSourcePlayer() override; |
52 | 52 |
53 // MediaPlayerAndroid implementation. | 53 // MediaPlayerAndroid implementation. |
54 void SetVideoSurface(gfx::ScopedJavaSurface surface) override; | 54 void SetVideoSurface(gl::ScopedJavaSurface surface) override; |
55 void Start() override; | 55 void Start() override; |
56 void Pause(bool is_media_related_action) override; | 56 void Pause(bool is_media_related_action) override; |
57 void SeekTo(base::TimeDelta timestamp) override; | 57 void SeekTo(base::TimeDelta timestamp) override; |
58 void Release() override; | 58 void Release() override; |
59 bool HasVideo() const override; | 59 bool HasVideo() const override; |
60 bool HasAudio() const override; | 60 bool HasAudio() const override; |
61 int GetVideoWidth() override; | 61 int GetVideoWidth() override; |
62 int GetVideoHeight() override; | 62 int GetVideoHeight() override; |
63 base::TimeDelta GetCurrentTime() override; | 63 base::TimeDelta GetCurrentTime() override; |
64 base::TimeDelta GetDuration() override; | 64 base::TimeDelta GetDuration() override; |
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 base::WeakPtr<MediaSourcePlayer> weak_this_; | 281 base::WeakPtr<MediaSourcePlayer> weak_this_; |
282 // NOTE: Weak pointers must be invalidated before all other member variables. | 282 // NOTE: Weak pointers must be invalidated before all other member variables. |
283 base::WeakPtrFactory<MediaSourcePlayer> weak_factory_; | 283 base::WeakPtrFactory<MediaSourcePlayer> weak_factory_; |
284 | 284 |
285 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer); | 285 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer); |
286 }; | 286 }; |
287 | 287 |
288 } // namespace media | 288 } // namespace media |
289 | 289 |
290 #endif // MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ | 290 #endif // MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ |
OLD | NEW |