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

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

Issue 18261007: Migrate webkit/renderer/media/ to content/renderer/media/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix win64 AGAIN 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 // 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.
11 // 11 //
12 // Other issues: 12 // Other issues:
13 // During tear down of the whole browser or a tab, the DOM tree may not be 13 // During tear down of the whole browser or a tab, the DOM tree may not be
14 // destructed nicely, and there will be some dangling media threads trying to 14 // destructed nicely, and there will be some dangling media threads trying to
15 // the main thread, so we need this class to listen to destruction event of the 15 // the main thread, so we need this class to listen to destruction event of the
16 // main thread and cleanup the media threads when the even is received. Also 16 // main thread and cleanup the media threads when the even is received. Also
17 // at destruction of this class we will need to unhook it from destruction event 17 // at destruction of this class we will need to unhook it from destruction event
18 // list of the main thread. 18 // list of the main thread.
19 19
20 #ifndef WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 20 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
21 #define WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 21 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
22 22
23 #include <string> 23 #include <string>
24 #include <vector> 24 #include <vector>
25 25
26 #include "base/basictypes.h" 26 #include "base/basictypes.h"
27 #include "base/memory/ref_counted.h" 27 #include "base/memory/ref_counted.h"
28 #include "base/memory/scoped_ptr.h" 28 #include "base/memory/scoped_ptr.h"
29 #include "base/memory/weak_ptr.h" 29 #include "base/memory/weak_ptr.h"
30 #include "base/threading/thread.h" 30 #include "base/threading/thread.h"
31 #include "cc/layers/video_frame_provider.h" 31 #include "cc/layers/video_frame_provider.h"
(...skipping 25 matching lines...) Expand all
57 namespace media { 57 namespace media {
58 class ChunkDemuxer; 58 class ChunkDemuxer;
59 class FFmpegDemuxer; 59 class FFmpegDemuxer;
60 class MediaLog; 60 class MediaLog;
61 } 61 }
62 62
63 namespace webkit { 63 namespace webkit {
64 class WebLayerImpl; 64 class WebLayerImpl;
65 } 65 }
66 66
67 namespace webkit_media { 67 namespace content {
68
69 class BufferedDataSource; 68 class BufferedDataSource;
70 class WebAudioSourceProviderImpl; 69 class WebAudioSourceProviderImpl;
71 class WebMediaPlayerDelegate; 70 class WebMediaPlayerDelegate;
72 class WebMediaPlayerParams; 71 class WebMediaPlayerParams;
73 class WebTextTrackImpl; 72 class WebTextTrackImpl;
74 73
75 class WebMediaPlayerImpl 74 class WebMediaPlayerImpl
76 : public WebKit::WebMediaPlayer, 75 : public WebKit::WebMediaPlayer,
77 public cc::VideoFrameProvider, 76 public cc::VideoFrameProvider,
78 public base::MessageLoop::DestructionObserver, 77 public base::MessageLoop::DestructionObserver,
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 // Factories for supporting GpuVideoDecoder. May be null. 321 // Factories for supporting GpuVideoDecoder. May be null.
323 scoped_refptr<media::GpuVideoDecoder::Factories> gpu_factories_; 322 scoped_refptr<media::GpuVideoDecoder::Factories> gpu_factories_;
324 323
325 // Routes audio playback to either AudioRendererSink or WebAudio. 324 // Routes audio playback to either AudioRendererSink or WebAudio.
326 scoped_refptr<WebAudioSourceProviderImpl> audio_source_provider_; 325 scoped_refptr<WebAudioSourceProviderImpl> audio_source_provider_;
327 326
328 bool is_local_source_; 327 bool is_local_source_;
329 bool supports_save_; 328 bool supports_save_;
330 329
331 // The decryptor that manages decryption keys and decrypts encrypted frames. 330 // The decryptor that manages decryption keys and decrypts encrypted frames.
332 scoped_ptr<ProxyDecryptor> decryptor_; 331 scoped_ptr<webkit_media::ProxyDecryptor> decryptor_;
333 332
334 bool starting_; 333 bool starting_;
335 334
336 // These two are mutually exclusive: 335 // These two are mutually exclusive:
337 // |data_source_| is used for regular resource loads. 336 // |data_source_| is used for regular resource loads.
338 // |chunk_demuxer_| is used for Media Source resource loads. 337 // |chunk_demuxer_| is used for Media Source resource loads.
339 // 338 //
340 // |demuxer_| will contain the appropriate demuxer based on which resource 339 // |demuxer_| will contain the appropriate demuxer based on which resource
341 // load strategy we're using. 340 // load strategy we're using.
342 scoped_ptr<BufferedDataSource> data_source_; 341 scoped_ptr<BufferedDataSource> data_source_;
(...skipping 22 matching lines...) Expand all
365 // A pointer back to the compositor to inform it about state changes. This is 364 // A pointer back to the compositor to inform it about state changes. This is
366 // not NULL while the compositor is actively using this webmediaplayer. 365 // not NULL while the compositor is actively using this webmediaplayer.
367 cc::VideoFrameProvider::Client* video_frame_provider_client_; 366 cc::VideoFrameProvider::Client* video_frame_provider_client_;
368 367
369 // Text track objects get a unique index value when they're created. 368 // Text track objects get a unique index value when they're created.
370 int text_track_index_; 369 int text_track_index_;
371 370
372 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); 371 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);
373 }; 372 };
374 373
375 } // namespace webkit_media 374 } // namespace content
376 375
377 #endif // WEBKIT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 376 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
OLDNEW
« no previous file with comments | « content/renderer/media/webmediaplayer_delegate.h ('k') | content/renderer/media/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698