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

Unified Diff: content/utility/utility_service_factory.cc

Issue 2867213004: [Mojo Video Capture] Hook up video capture service behind a feature flag (Closed)
Patch Set: Rebase to May 19th Created 3 years, 7 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
« no previous file with comments | « content/utility/DEPS ('k') | media/capture/video/video_capture_system.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/utility/utility_service_factory.cc
diff --git a/content/utility/utility_service_factory.cc b/content/utility/utility_service_factory.cc
index 734fdebd587cd6bff7c43b0644918fc0daa12f29..894bdbe02d16c186c805d2bb77c5a6578a67d813 100644
--- a/content/utility/utility_service_factory.cc
+++ b/content/utility/utility_service_factory.cc
@@ -18,11 +18,21 @@
#include "services/data_decoder/public/interfaces/constants.mojom.h"
#include "services/shape_detection/public/interfaces/constants.mojom.h"
#include "services/shape_detection/shape_detection_service.h"
+#include "services/video_capture/public/interfaces/constants.mojom.h"
+#include "services/video_capture/service_impl.h"
#if defined(ENABLE_MOJO_MEDIA_IN_UTILITY_PROCESS)
#include "media/mojo/services/media_service_factory.h" // nogncheck
#endif
+namespace {
+
+std::unique_ptr<service_manager::Service> CreateVideoCaptureService() {
+ return base::MakeUnique<video_capture::ServiceImpl>();
+}
+
+} // anonymous namespace
+
namespace content {
namespace {
@@ -42,6 +52,11 @@ UtilityServiceFactory::~UtilityServiceFactory() {}
void UtilityServiceFactory::RegisterServices(ServiceMap* services) {
GetContentClient()->utility()->RegisterServices(services);
+ ServiceInfo video_capture_info;
+ video_capture_info.factory = base::Bind(&CreateVideoCaptureService);
+ services->insert(
+ std::make_pair(video_capture::mojom::kServiceName, video_capture_info));
+
#if defined(ENABLE_MOJO_MEDIA_IN_UTILITY_PROCESS)
ServiceInfo info;
info.factory = base::Bind(&media::CreateMediaService);
« no previous file with comments | « content/utility/DEPS ('k') | media/capture/video/video_capture_system.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698