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

Side by Side Diff: media/mojo/services/mojo_media_client.h

Issue 2643743002: Mojify demuxers and allow running {Chunk/FFmpeg}Demuxer in a Utility Process (Closed)
Patch Set: Rebase and make sure to unbind mojom::DemuxerPtr on the bound thread during termination Created 3 years, 10 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_ 5 #ifndef MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_
6 #define MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_ 6 #define MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "media/base/demuxer.h"
12 #include "media/mojo/interfaces/video_decoder.mojom.h" 13 #include "media/mojo/interfaces/video_decoder.mojom.h"
13 #include "media/mojo/services/media_mojo_export.h" 14 #include "media/mojo/services/media_mojo_export.h"
14 15
15 namespace base { 16 namespace base {
16 class SingleThreadTaskRunner; 17 class SingleThreadTaskRunner;
17 } 18 }
18 19
19 namespace service_manager { 20 namespace service_manager {
20 class Connector; 21 class Connector;
21 namespace mojom { 22 namespace mojom {
22 class InterfaceProvider; 23 class InterfaceProvider;
23 } 24 }
24 } 25 }
25 26
26 namespace media { 27 namespace media {
27 28
28 class AudioDecoder; 29 class AudioDecoder;
29 class AudioRendererSink; 30 class AudioRendererSink;
30 class CdmFactory; 31 class CdmFactory;
32 class DemuxerFactory;
31 class MediaLog; 33 class MediaLog;
32 class RendererFactory; 34 class RendererFactory;
33 class VideoDecoder; 35 class VideoDecoder;
34 class VideoRendererSink; 36 class VideoRendererSink;
35 37
36 class MEDIA_MOJO_EXPORT MojoMediaClient { 38 class MEDIA_MOJO_EXPORT MojoMediaClient {
37 public: 39 public:
38 // Called before the host application is scheduled to quit. 40 // Called before the host application is scheduled to quit.
39 // The application message loop is still valid at this point, so all clean 41 // The application message loop is still valid at this point, so all clean
40 // up tasks requiring the message loop must be completed before returning. 42 // up tasks requiring the message loop must be completed before returning.
(...skipping 17 matching lines...) Expand all
58 60
59 // Returns the output sink used for rendering video. 61 // Returns the output sink used for rendering video.
60 // May be null if the RendererFactory doesn't need a video sink. 62 // May be null if the RendererFactory doesn't need a video sink.
61 virtual std::unique_ptr<VideoRendererSink> CreateVideoRendererSink( 63 virtual std::unique_ptr<VideoRendererSink> CreateVideoRendererSink(
62 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner); 64 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner);
63 65
64 // Returns the RendererFactory to be used by MojoRendererService. 66 // Returns the RendererFactory to be used by MojoRendererService.
65 virtual std::unique_ptr<RendererFactory> CreateRendererFactory( 67 virtual std::unique_ptr<RendererFactory> CreateRendererFactory(
66 const scoped_refptr<MediaLog>& media_log); 68 const scoped_refptr<MediaLog>& media_log);
67 69
70 // Returns the DemuxerFactory to be used by MojoDemuxerService.
71 virtual std::unique_ptr<DemuxerFactory> CreateDemuxerFactory(
72 const scoped_refptr<MediaLog>& media_log);
73
68 // Returns the CdmFactory to be used by MojoCdmService. |host_interfaces| can 74 // Returns the CdmFactory to be used by MojoCdmService. |host_interfaces| can
69 // be used to request interfaces provided remotely by the host. It may be a 75 // be used to request interfaces provided remotely by the host. It may be a
70 // nullptr if the host chose not to bind the InterfacePtr. 76 // nullptr if the host chose not to bind the InterfacePtr.
71 virtual std::unique_ptr<CdmFactory> CreateCdmFactory( 77 virtual std::unique_ptr<CdmFactory> CreateCdmFactory(
72 service_manager::mojom::InterfaceProvider* host_interfaces); 78 service_manager::mojom::InterfaceProvider* host_interfaces);
73 79
74 protected: 80 protected:
75 MojoMediaClient(); 81 MojoMediaClient();
76 }; 82 };
77 83
78 } // namespace media 84 } // namespace media
79 85
80 #endif // MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_ 86 #endif // MEDIA_MOJO_SERVICES_MOJO_MEDIA_CLIENT_H_
OLDNEW
« no previous file with comments | « media/mojo/services/mojo_demuxer_service_context.cc ('k') | media/mojo/services/mojo_media_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698