Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(312)

Side by Side Diff: content/renderer/media/webmediaplayer_params.h

Issue 18123002: Migrate webkit/renderer/media/ to content/renderer/media/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: delegates Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_
6 #define WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_ 6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "content/common/content_export.h"
9 #include "media/filters/gpu_video_decoder.h" 10 #include "media/filters/gpu_video_decoder.h"
10 11
11 namespace base { 12 namespace base {
12 class MessageLoopProxy; 13 class MessageLoopProxy;
13 } 14 }
14 15
15 namespace media { 16 namespace media {
16 class AudioRendererSink; 17 class AudioRendererSink;
17 class MediaLog; 18 class MediaLog;
18 } 19 }
19 20
20 namespace webkit_media { 21 namespace content {
22 class MediaPlayerLoadDelegate;
21 23
22 // Holds parameters for constructing WebMediaPlayerImpl without having 24 // Holds parameters for constructing WebMediaPlayerImpl without having
23 // to plumb arguments through various abstraction layers. 25 // to plumb arguments through various abstraction layers.
24 class WebMediaPlayerParams { 26 class CONTENT_EXPORT WebMediaPlayerParams {
25 public: 27 public:
26 // |message_loop_proxy| and |media_log| are the only required parameters; 28 // |message_loop_proxy| and |media_log| are the only required parameters;
27 // all others may be null. 29 // all others may be null.
28 WebMediaPlayerParams( 30 WebMediaPlayerParams(
29 const scoped_refptr<base::MessageLoopProxy>& message_loop_proxy, 31 const scoped_refptr<base::MessageLoopProxy>& message_loop_proxy,
32 MediaPlayerLoadDelegate* load_delegate,
30 const scoped_refptr<media::AudioRendererSink>& audio_renderer_sink, 33 const scoped_refptr<media::AudioRendererSink>& audio_renderer_sink,
31 const scoped_refptr<media::GpuVideoDecoder::Factories>& gpu_factories, 34 const scoped_refptr<media::GpuVideoDecoder::Factories>& gpu_factories,
32 const scoped_refptr<media::MediaLog>& media_log); 35 const scoped_refptr<media::MediaLog>& media_log);
33 ~WebMediaPlayerParams(); 36 ~WebMediaPlayerParams();
34 37
35 const scoped_refptr<base::MessageLoopProxy>& message_loop_proxy() const { 38 const scoped_refptr<base::MessageLoopProxy>& message_loop_proxy() const {
36 return message_loop_proxy_; 39 return message_loop_proxy_;
37 } 40 }
38 41
42 MediaPlayerLoadDelegate* load_delegate() const { return load_delegate_; }
43
39 const scoped_refptr<media::AudioRendererSink>& audio_renderer_sink() const { 44 const scoped_refptr<media::AudioRendererSink>& audio_renderer_sink() const {
40 return audio_renderer_sink_; 45 return audio_renderer_sink_;
41 } 46 }
42 47
43 const scoped_refptr<media::GpuVideoDecoder::Factories>& 48 const scoped_refptr<media::GpuVideoDecoder::Factories>&
44 gpu_factories() const { 49 gpu_factories() const {
45 return gpu_factories_; 50 return gpu_factories_;
46 } 51 }
47 52
48 const scoped_refptr<media::MediaLog>& media_log() const { 53 const scoped_refptr<media::MediaLog>& media_log() const {
49 return media_log_; 54 return media_log_;
50 } 55 }
51 56
52 private: 57 private:
53 scoped_refptr<base::MessageLoopProxy> message_loop_proxy_; 58 scoped_refptr<base::MessageLoopProxy> message_loop_proxy_;
59 MediaPlayerLoadDelegate* load_delegate_;
54 scoped_refptr<media::AudioRendererSink> audio_renderer_sink_; 60 scoped_refptr<media::AudioRendererSink> audio_renderer_sink_;
55 scoped_refptr<media::GpuVideoDecoder::Factories> gpu_factories_; 61 scoped_refptr<media::GpuVideoDecoder::Factories> gpu_factories_;
56 scoped_refptr<media::MediaLog> media_log_; 62 scoped_refptr<media::MediaLog> media_log_;
57 63
58 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMediaPlayerParams); 64 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMediaPlayerParams);
59 }; 65 };
60 66
61 } // namespace media 67 } // namespace media
62 68
63 #endif // WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_ 69 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_PARAMS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698