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

Side by Side Diff: webkit/glue/webmediaplayer_impl.h

Issue 7480032: Plumb media data from renderers up to MediaInternals in the browser process. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Responding to feedback. Created 9 years, 4 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 PipelineImpl which is the actual media player pipeline, it glues 6 // It contains PipelineImpl 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 // PipelineImpl would creates multiple threads and access some public methods 8 // PipelineImpl 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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 #include "ui/gfx/rect.h" 70 #include "ui/gfx/rect.h"
71 #include "ui/gfx/size.h" 71 #include "ui/gfx/size.h"
72 #include "webkit/glue/media/web_data_source.h" 72 #include "webkit/glue/media/web_data_source.h"
73 73
74 class GURL; 74 class GURL;
75 75
76 namespace WebKit { 76 namespace WebKit {
77 class WebFrame; 77 class WebFrame;
78 } 78 }
79 79
80 namespace media {
81 class MediaLog;
82 }
83
80 namespace webkit_glue { 84 namespace webkit_glue {
81 85
82 class MediaResourceLoaderBridgeFactory; 86 class MediaResourceLoaderBridgeFactory;
83 class MediaStreamClient; 87 class MediaStreamClient;
84 class WebVideoRenderer; 88 class WebVideoRenderer;
85 89
86 class WebMediaPlayerImpl 90 class WebMediaPlayerImpl
87 : public WebKit::WebMediaPlayer, 91 : public WebKit::WebMediaPlayer,
88 public MessageLoop::DestructionObserver { 92 public MessageLoop::DestructionObserver {
89 public: 93 public:
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 // provided by WebKit to perform renderering. The simple data source does 205 // provided by WebKit to perform renderering. The simple data source does
202 // resource loading by loading the whole resource object into memory. Null 206 // resource loading by loading the whole resource object into memory. Null
203 // audio renderer is a fake audio device that plays silence. Provider of the 207 // audio renderer is a fake audio device that plays silence. Provider of the
204 // |collection| can override the default filters by adding extra filters to 208 // |collection| can override the default filters by adding extra filters to
205 // |collection| before calling this method. 209 // |collection| before calling this method.
206 // 210 //
207 // Callers must call |Initialize()| before they can use the object. 211 // Callers must call |Initialize()| before they can use the object.
208 WebMediaPlayerImpl(WebKit::WebMediaPlayerClient* client, 212 WebMediaPlayerImpl(WebKit::WebMediaPlayerClient* client,
209 media::FilterCollection* collection, 213 media::FilterCollection* collection,
210 media::MessageLoopFactory* message_loop_factory, 214 media::MessageLoopFactory* message_loop_factory,
211 MediaStreamClient* media_stream_client); 215 MediaStreamClient* media_stream_client,
216 media::MediaLog* media_log);
212 virtual ~WebMediaPlayerImpl(); 217 virtual ~WebMediaPlayerImpl();
213 218
214 // Finalizes initialization of the object. 219 // Finalizes initialization of the object.
215 bool Initialize( 220 bool Initialize(
216 WebKit::WebFrame* frame, 221 WebKit::WebFrame* frame,
217 bool use_simple_data_source, 222 bool use_simple_data_source,
218 scoped_refptr<WebVideoRenderer> web_video_renderer); 223 scoped_refptr<WebVideoRenderer> web_video_renderer);
219 224
220 virtual void load(const WebKit::WebURL& url); 225 virtual void load(const WebKit::WebURL& url);
221 virtual void cancelLoad(); 226 virtual void cancelLoad();
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 WebKit::WebMediaPlayerClient* client_; 359 WebKit::WebMediaPlayerClient* client_;
355 360
356 scoped_refptr<Proxy> proxy_; 361 scoped_refptr<Proxy> proxy_;
357 362
358 MediaStreamClient* media_stream_client_; 363 MediaStreamClient* media_stream_client_;
359 364
360 #if WEBKIT_USING_CG 365 #if WEBKIT_USING_CG
361 scoped_ptr<skia::PlatformCanvas> skia_canvas_; 366 scoped_ptr<skia::PlatformCanvas> skia_canvas_;
362 #endif 367 #endif
363 368
369 scoped_refptr<media::MediaLog> media_log_;
370
364 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); 371 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);
365 }; 372 };
366 373
367 } // namespace webkit_glue 374 } // namespace webkit_glue
368 375
369 #endif // WEBKIT_GLUE_WEBMEDIAPLAYER_IMPL_H_ 376 #endif // WEBKIT_GLUE_WEBMEDIAPLAYER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698