• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 MEDIA_BASE_FILTER_COLLECTION_H_
6 #define MEDIA_BASE_FILTER_COLLECTION_H_
7 
8 #include "base/memory/scoped_ptr.h"
9 #include "media/base/media_export.h"
10 
11 namespace media {
12 
13 class AudioRenderer;
14 class Demuxer;
15 class TextRenderer;
16 class VideoRenderer;
17 
18 // Represents a set of uninitialized demuxer and audio/video decoders and
19 // renderers. Used to start a Pipeline object for media playback.
20 //
21 // TODO(scherkus): Replace FilterCollection with something sensible, see
22 // http://crbug.com/110800
23 class MEDIA_EXPORT FilterCollection {
24  public:
25   FilterCollection();
26   ~FilterCollection();
27 
28   void SetDemuxer(Demuxer* demuxer);
29   Demuxer* GetDemuxer();
30 
31   void SetAudioRenderer(scoped_ptr<AudioRenderer> audio_renderer);
32   scoped_ptr<AudioRenderer> GetAudioRenderer();
33 
34   void SetVideoRenderer(scoped_ptr<VideoRenderer> video_renderer);
35   scoped_ptr<VideoRenderer> GetVideoRenderer();
36 
37   void SetTextRenderer(scoped_ptr<TextRenderer> text_renderer);
38   scoped_ptr<TextRenderer> GetTextRenderer();
39 
40  private:
41   Demuxer* demuxer_;
42   scoped_ptr<AudioRenderer> audio_renderer_;
43   scoped_ptr<VideoRenderer> video_renderer_;
44   scoped_ptr<TextRenderer> text_renderer_;
45 
46   DISALLOW_COPY_AND_ASSIGN(FilterCollection);
47 };
48 
49 }  // namespace media
50 
51 #endif  // MEDIA_BASE_FILTER_COLLECTION_H_
52