OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef WEBKIT_MEDIA_FILTER_HELPERS_H_ | |
6 #define WEBKIT_MEDIA_FILTER_HELPERS_H_ | |
7 | |
8 #include "base/basictypes.h" | |
9 #include "base/memory/ref_counted.h" | |
10 #include "base/memory/scoped_vector.h" | |
11 // TODO(fgalligan): Remove the dependency on FFmpeg. | |
12 #include "media/filters/ffmpeg_demuxer.h" | |
13 | |
14 namespace base { | |
15 class MessageLoopProxy; | |
16 } | |
17 | |
18 namespace media { | |
19 class AudioDecoder; | |
20 class ChunkDemuxer; | |
21 class DataSource; | |
22 class FilterCollection; | |
23 } | |
24 | |
25 namespace webkit_media { | |
26 | |
27 // Creates and adds the default set of audio decoders to |audio_decoders|. | |
28 void AddDefaultAudioDecoders( | |
29 const scoped_refptr<base::MessageLoopProxy>& message_loop, | |
30 ScopedVector<media::AudioDecoder>* audio_decoders); | |
31 | |
32 // Builds the required filters for handling media source URLs, adds them to | |
33 // |filter_collection|. | |
34 void BuildMediaSourceCollection( | |
35 const scoped_refptr<media::ChunkDemuxer>& demuxer, | |
36 const scoped_refptr<base::MessageLoopProxy>& message_loop, | |
37 media::FilterCollection* filter_collection); | |
38 | |
39 // Builds the required filters for handling regular URLs and adds them to | |
40 // |filter_collection| and fills |video_decoder| returning true if successful. | |
41 void BuildDefaultCollection( | |
42 const scoped_refptr<media::DataSource>& data_source, | |
43 const scoped_refptr<base::MessageLoopProxy>& message_loop, | |
44 media::FilterCollection* filter_collection, | |
45 const media::FFmpegNeedKeyCB& need_key_cb); | |
46 | |
47 } // webkit_media | |
48 | |
49 #endif // WEBKIT_MEDIA_FILTER_HELPERS_H_ | |
OLD | NEW |