| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Delegate calls from WebCore::MediaPlayerPrivate to Chrome's video player. | 5 // Delegate calls from WebCore::MediaPlayerPrivate to Chrome's video player. |
| 6 // It contains Pipeline which is the actual media player pipeline, it glues | 6 // It contains Pipeline which is the actual media player pipeline, it glues |
| 7 // the media player pipeline, data source, audio renderer and renderer. | 7 // the media player pipeline, data source, audio renderer and renderer. |
| 8 // Pipeline would creates multiple threads and access some public methods | 8 // Pipeline would creates multiple threads and access some public methods |
| 9 // of this class, so we need to be extra careful about concurrent access of | 9 // of this class, so we need to be extra careful about concurrent access of |
| 10 // methods and members. | 10 // methods and members. |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 #include <string> | 23 #include <string> |
| 24 | 24 |
| 25 #include "base/memory/ref_counted.h" | 25 #include "base/memory/ref_counted.h" |
| 26 #include "base/memory/scoped_ptr.h" | 26 #include "base/memory/scoped_ptr.h" |
| 27 #include "base/memory/weak_ptr.h" | 27 #include "base/memory/weak_ptr.h" |
| 28 #include "base/threading/thread.h" | 28 #include "base/threading/thread.h" |
| 29 #include "cc/layers/video_frame_provider.h" | 29 #include "cc/layers/video_frame_provider.h" |
| 30 #include "googleurl/src/gurl.h" | 30 #include "googleurl/src/gurl.h" |
| 31 #include "media/base/audio_renderer_sink.h" | 31 #include "media/base/audio_renderer_sink.h" |
| 32 #include "media/base/decryptor.h" | 32 #include "media/base/decryptor.h" |
| 33 #include "media/base/media_keys.h" |
| 33 #include "media/base/pipeline.h" | 34 #include "media/base/pipeline.h" |
| 34 #include "media/base/text_track.h" | 35 #include "media/base/text_track.h" |
| 35 #include "media/filters/gpu_video_decoder.h" | 36 #include "media/filters/gpu_video_decoder.h" |
| 36 #include "media/filters/skcanvas_video_renderer.h" | 37 #include "media/filters/skcanvas_video_renderer.h" |
| 37 #include "skia/ext/platform_canvas.h" | 38 #include "skia/ext/platform_canvas.h" |
| 38 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3
D.h" | 39 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3
D.h" |
| 39 #include "third_party/WebKit/Source/WebKit/chromium/public/WebAudioSourceProvide
r.h" | 40 #include "third_party/WebKit/Source/WebKit/chromium/public/WebAudioSourceProvide
r.h" |
| 40 #include "third_party/WebKit/Source/WebKit/chromium/public/WebMediaPlayer.h" | 41 #include "third_party/WebKit/Source/WebKit/chromium/public/WebMediaPlayer.h" |
| 41 #include "third_party/WebKit/Source/WebKit/chromium/public/WebMediaPlayerClient.
h" | 42 #include "third_party/WebKit/Source/WebKit/chromium/public/WebMediaPlayerClient.
h" |
| 42 #include "webkit/media/crypto/key_systems.h" | 43 #include "webkit/media/crypto/key_systems.h" |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 194 | 195 |
| 195 void OnPipelineSeek(media::PipelineStatus status); | 196 void OnPipelineSeek(media::PipelineStatus status); |
| 196 void OnPipelineEnded(); | 197 void OnPipelineEnded(); |
| 197 void OnPipelineError(media::PipelineStatus error); | 198 void OnPipelineError(media::PipelineStatus error); |
| 198 void OnPipelineBufferingState( | 199 void OnPipelineBufferingState( |
| 199 media::Pipeline::BufferingState buffering_state); | 200 media::Pipeline::BufferingState buffering_state); |
| 200 void OnDemuxerOpened(scoped_ptr<WebKit::WebMediaSource> media_source); | 201 void OnDemuxerOpened(scoped_ptr<WebKit::WebMediaSource> media_source); |
| 201 void OnKeyAdded(const std::string& key_system, const std::string& session_id); | 202 void OnKeyAdded(const std::string& key_system, const std::string& session_id); |
| 202 void OnKeyError(const std::string& key_system, | 203 void OnKeyError(const std::string& key_system, |
| 203 const std::string& session_id, | 204 const std::string& session_id, |
| 204 media::Decryptor::KeyError error_code, | 205 media::MediaKeys::KeyError error_code, |
| 205 int system_code); | 206 int system_code); |
| 206 void OnKeyMessage(const std::string& key_system, | 207 void OnKeyMessage(const std::string& key_system, |
| 207 const std::string& session_id, | 208 const std::string& session_id, |
| 208 const std::string& message, | 209 const std::string& message, |
| 209 const std::string& default_url); | 210 const std::string& default_url); |
| 210 void OnNeedKey(const std::string& key_system, | 211 void OnNeedKey(const std::string& key_system, |
| 211 const std::string& type, | 212 const std::string& type, |
| 212 const std::string& session_id, | 213 const std::string& session_id, |
| 213 scoped_ptr<uint8[]> init_data, | 214 scoped_ptr<uint8[]> init_data, |
| 214 int init_data_size); | 215 int init_data_size); |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 377 | 378 |
| 378 // Text track objects get a unique index value when they're created. | 379 // Text track objects get a unique index value when they're created. |
| 379 int text_track_index_; | 380 int text_track_index_; |
| 380 | 381 |
| 381 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); | 382 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); |
| 382 }; | 383 }; |
| 383 | 384 |
| 384 } // namespace webkit_media | 385 } // namespace webkit_media |
| 385 | 386 |
| 386 #endif // WEBKIT_MEDIA_WEBMEDIAPLAYER_IMPL_H_ | 387 #endif // WEBKIT_MEDIA_WEBMEDIAPLAYER_IMPL_H_ |
| OLD | NEW |