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

Unified Diff: media/filters/ffmpeg_demuxer_factory.h

Issue 6648004: DemuxerFactory is born! (Closed)
Patch Set: Created 9 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: media/filters/ffmpeg_demuxer_factory.h
diff --git a/media/filters/ffmpeg_demuxer_factory.h b/media/filters/ffmpeg_demuxer_factory.h
new file mode 100644
index 0000000000000000000000000000000000000000..1880ecebf2ea36aceff278de2f6ed9cb58e8db1c
--- /dev/null
+++ b/media/filters/ffmpeg_demuxer_factory.h
@@ -0,0 +1,40 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Implements the DemuxerFactory interface using FFmpegDemuxer.
+
+#ifndef MEDIA_FILTERS_FFMPEG_DEMUXER_FACTORY_H_
+#define MEDIA_FILTERS_FFMPEG_DEMUXER_FACTORY_H_
+
+#include "base/basictypes.h"
+#include "base/scoped_ptr.h"
+#include "media/base/filter_factories.h"
+
+class FilterHost;
+class MessageLoop;
+
+namespace media {
+
+class FFmpegDemuxerFactory : public DemuxerFactory {
+ public:
+ // Takes ownership of |data_source_factory|, but not of |loop| or |host|.
+ FFmpegDemuxerFactory(DataSourceFactory* data_source_factory,
+ MessageLoop* loop,
+ FilterHost* host);
+ virtual ~FFmpegDemuxerFactory();
+
+ virtual void Build(const std::string& url, BuildCallback* cb);
+ virtual DemuxerFactory* Clone() const;
+
+ private:
+ scoped_ptr<DataSourceFactory> data_source_factory_;
+ MessageLoop* loop_; // Unowned.
+ FilterHost* host_; // Unowned.
acolwell GONE FROM CHROMIUM 2011/03/08 21:48:09 Remove? I don't see it being used.
Ami GONE FROM CHROMIUM 2011/03/08 22:44:48 It used to be (before the set_host() shenaniganery
+
+ DISALLOW_COPY_AND_ASSIGN(FFmpegDemuxerFactory);
+};
+
+} // namespace media
+
+#endif // MEDIA_FILTERS_FFMPEG_DEMUXER_FACTORY_H_

Powered by Google App Engine
This is Rietveld 408576698