Christian Fremerey would like Ricky Liang and Emircan Uysaler to review this change.
[Video Capture Service, ChromeOS] Separate startup of CameraHalDelegate from instantiation of VideoCaptureDeviceFactory
Separate startup of CameraHalDelegate from instantiation of
VideoCaptureDeviceFactory by extracting the corresponding constructs into a
new class CameraHalContext and creating an instance in MediaStreamManager.
For ChromeOS builds that us the cros_camer_service for video capture, the
CameraHalDelegate must be started as part of Chrome startup. This startup has
for now been tied to the instantiation of VideoCaptureDeviceFactoryChromeOS.
With the move to the VideoCaptureService, the instantiation of
VideoCaptureDeviceFactoryChromeOS no longer happens on Chrome startup, but
instead happens on-demand and potentially more than once.
Design Doc: https://docs.google.com/document/d/169LS3U0DD7hHpqZSli0gpCaCqE1eWN4QXFSIGoruPwQ/edit?usp=sharing
Test: See test plan section in design doc.
Bug: 820608
Change-Id: I257a9eaa6368144fd252e532d211dfa716e8c242
---
M content/browser/renderer_host/media/media_stream_manager.cc
M content/browser/renderer_host/media/media_stream_manager.h
M content/browser/renderer_host/media/service_video_capture_provider.cc
M content/browser/renderer_host/media/service_video_capture_provider.h
M content/browser/service_manager/service_manager_context.cc
M content/public/common/BUILD.gn
M content/public/common/content_features.cc
M media/capture/BUILD.gn
M media/capture/video/chromeos/camera_buffer_factory.cc
M media/capture/video/chromeos/camera_device_delegate_unittest.cc
A media/capture/video/chromeos/camera_hal_context.cc
A media/capture/video/chromeos/camera_hal_context.h
M media/capture/video/chromeos/camera_hal_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_dispatcher_impl.cc
A media/capture/video/chromeos/public/BUILD.gn
A media/capture/video/chromeos/public/cros_features.cc
A media/capture/video/chromeos/public/cros_features.h
M media/capture/video/chromeos/video_capture_device_factory_chromeos.cc
M media/capture/video/chromeos/video_capture_device_factory_chromeos.h
M media/capture/video/linux/video_capture_device_factory_linux.cc
A media/capture/video/null_video_capture_device_factory.cc
A media/capture/video/null_video_capture_device_factory.h
M media/capture/video/video_capture_device_factory.cc
M media/capture/video/video_capture_device_factory.h
M media/capture/video/video_capture_device_unittest.cc
M services/video_capture/device_factory_provider_impl.cc
M services/video_capture/device_factory_provider_impl.h
M services/video_capture/public/mojom/device_factory_provider.mojom
28 files changed, 346 insertions(+), 246 deletions(-)
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
jcliang@: PTAL first pass or delegate to the most appropriate team member.
emircan@: FYI for now, since I promised in the previous CL to fix the thing you pointed out would not work.
Patch set 2:-Code-Review
shik@, hiwu@: friendly ping
3 comments:
Patch Set #8, Line 13: us the cros_camer_service
use the cros_camera_service
Patch Set #8, Line 14: CameraHalDelegate
Actually we need the CameraHalDispatcher to be started as part of Chrome startup, so the camera service bootstrapping between CrOS, Chrome, and ARC++ can proceed. CameraHalDelegate can be started/stopped on-demand with VCDFactoryChromeOS.
File media/capture/video/chromeos/camera_hal_dispatcher_impl.cc:
Patch Set #8, Line 70: LOG(ERROR) << "Stop() was called";
I guess you'd want to change these back to VLOG(1).
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
Christian Fremerey uploaded patch set #10 to this change.
[Video Capture Service, ChromeOS] Separate startup of CameraHalDispatcher from instantiation of VideoCaptureDeviceFactory
Separate startup of CameraHalDispatcher from instantiation of
VideoCaptureDeviceFactory by extracting the startup calls from
VideoCaptureDeviceFactoryChromeOS to MediaStreamManager (which is where
VideoCaptureDeviceFactoryChromeOS gets instantiated in case the
video capture service is not enabled).
For ChromeOS builds that us the cros_camer_service for video capture, the
CameraHalDispatcher must be started as part of Chrome startup. This startup has
for now been tied to the instantiation of VideoCaptureDeviceFactoryChromeOS.
With the move to the VideoCaptureService, the instantiation of
VideoCaptureDeviceFactoryChromeOS no longer happens on Chrome startup, but
instead happens on-demand and potentially more than once.
Design Doc: https://docs.google.com/document/d/169LS3U0DD7hHpqZSli0gpCaCqE1eWN4QXFSIGoruPwQ/edit?usp=sharing
Test: See test plan section in design doc.
Bug: 820608
Change-Id: I257a9eaa6368144fd252e532d211dfa716e8c242
---
M content/browser/renderer_host/media/media_stream_manager.cc
M content/browser/renderer_host/media/service_video_capture_provider.cc
M content/browser/renderer_host/media/service_video_capture_provider.h
M content/browser/renderer_host/media/service_video_capture_provider_unittest.cc
M content/browser/service_manager/service_manager_context.cc
M content/public/common/BUILD.gn
M content/public/common/content_features.cc
M media/capture/BUILD.gn
M media/capture/video/android/video_capture_device_factory_android.cc
M media/capture/video/chromeos/camera_device_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_dispatcher_impl.cc
A media/capture/video/chromeos/public/BUILD.gn
A media/capture/video/chromeos/public/cros_features.cc
A media/capture/video/chromeos/public/cros_features.h
M media/capture/video/chromeos/video_capture_device_factory_chromeos.cc
M media/capture/video/chromeos/video_capture_device_factory_chromeos.h
M media/capture/video/linux/video_capture_device_factory_linux.cc
M media/capture/video/mac/video_capture_device_factory_mac.mm
A media/capture/video/null_video_capture_device_factory.cc
A media/capture/video/null_video_capture_device_factory.h
M media/capture/video/video_capture_device_factory.cc
M media/capture/video/video_capture_device_factory.h
M media/capture/video/video_capture_device_unittest.cc
M media/capture/video/win/video_capture_device_factory_win.cc
M services/video_capture/device_factory_provider_impl.cc
M services/video_capture/device_factory_provider_impl.h
M services/video_capture/public/mojom/device_factory_provider.mojom
28 files changed, 221 insertions(+), 207 deletions(-)
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
Christian Fremerey uploaded patch set #11 to this change.
[Video Capture Service, ChromeOS] Separate startup of CameraHalDispatcher from instantiation of VideoCaptureDeviceFactory
Separate startup of CameraHalDispatcher from instantiation of
VideoCaptureDeviceFactory by extracting the startup calls from
VideoCaptureDeviceFactoryChromeOS to MediaStreamManager (which is where
VideoCaptureDeviceFactoryChromeOS gets instantiated in case the
video capture service is not enabled).
For ChromeOS builds that use the cros_camer_service for video capture, the
CameraHalDispatcher must be started as part of Chrome startup. This startup has
for now been tied to the instantiation of VideoCaptureDeviceFactoryChromeOS.
With the move to the VideoCaptureService, the instantiation of
VideoCaptureDeviceFactoryChromeOS no longer happens on Chrome startup, but
instead happens on-demand and potentially more than once.
Design Doc: https://docs.google.com/document/d/169LS3U0DD7hHpqZSli0gpCaCqE1eWN4QXFSIGoruPwQ/edit?usp=sharing
Test: See test plan section in design doc.
Bug: 820608
Change-Id: I257a9eaa6368144fd252e532d211dfa716e8c242
---
M content/browser/renderer_host/media/media_stream_manager.cc
M content/browser/renderer_host/media/service_video_capture_provider.cc
M content/browser/renderer_host/media/service_video_capture_provider.h
M content/browser/renderer_host/media/service_video_capture_provider_unittest.cc
M content/browser/service_manager/service_manager_context.cc
M content/public/common/BUILD.gn
M content/public/common/content_features.cc
M media/capture/BUILD.gn
M media/capture/video/android/video_capture_device_factory_android.cc
M media/capture/video/chromeos/camera_device_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_dispatcher_impl.cc
A media/capture/video/chromeos/public/BUILD.gn
A media/capture/video/chromeos/public/cros_features.cc
A media/capture/video/chromeos/public/cros_features.h
M media/capture/video/chromeos/video_capture_device_factory_chromeos.cc
M media/capture/video/chromeos/video_capture_device_factory_chromeos.h
M media/capture/video/linux/video_capture_device_factory_linux.cc
M media/capture/video/mac/video_capture_device_factory_mac.mm
A media/capture/video/null_video_capture_device_factory.cc
A media/capture/video/null_video_capture_device_factory.h
M media/capture/video/video_capture_device_factory.cc
M media/capture/video/video_capture_device_factory.h
M media/capture/video/video_capture_device_unittest.cc
M media/capture/video/win/video_capture_device_factory_win.cc
M services/video_capture/device_factory_provider_impl.cc
M services/video_capture/device_factory_provider_impl.h
M services/video_capture/public/mojom/device_factory_provider.mojom
28 files changed, 221 insertions(+), 207 deletions(-)
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
jcliang@: Thanks, that simplified this CL a bit.
Patch set 12:Commit-Queue +1
3 comments:
Patch Set #8, Line 13: not enabled).
use the cros_camera_service
Done
Actually we need the CameraHalDispatcher to be started as part of Chrome startup, so the camera serv […]
Done
File media/capture/video/chromeos/camera_hal_dispatcher_impl.cc:
Patch Set #8, Line 70: VLOG(1) << "Stop() was called";
I guess you'd want to change these back to VLOG(1).
Done
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
Patch set 12:Code-Review +1
1 comment:
Patch Set #12, Line 15: camer
camera
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
jam@: PTAL content/public/common.
Christian Fremerey uploaded patch set #13 to this change.
[Video Capture Service, ChromeOS] Separate startup of CameraHalDispatcher from instantiation of VideoCaptureDeviceFactory
Separate startup of CameraHalDispatcher from instantiation of
VideoCaptureDeviceFactory by extracting the startup calls from
VideoCaptureDeviceFactoryChromeOS to MediaStreamManager (which is where
VideoCaptureDeviceFactoryChromeOS gets instantiated in case the
video capture service is not enabled).
For ChromeOS builds that use the cros_camera_service for video capture, the
CameraHalDispatcher must be started as part of Chrome startup. This startup has
for now been tied to the instantiation of VideoCaptureDeviceFactoryChromeOS.
With the move to the VideoCaptureService, the instantiation of
VideoCaptureDeviceFactoryChromeOS no longer happens on Chrome startup, but
instead happens on-demand and potentially more than once.
Design Doc: https://docs.google.com/document/d/169LS3U0DD7hHpqZSli0gpCaCqE1eWN4QXFSIGoruPwQ/edit?usp=sharing
Test: See test plan section in design doc.
Bug: 820608
Change-Id: I257a9eaa6368144fd252e532d211dfa716e8c242
---
M content/browser/renderer_host/media/media_stream_manager.cc
M content/browser/renderer_host/media/service_video_capture_provider.cc
M content/browser/renderer_host/media/service_video_capture_provider.h
M content/browser/renderer_host/media/service_video_capture_provider_unittest.cc
M content/browser/service_manager/service_manager_context.cc
M content/public/common/BUILD.gn
M content/public/common/content_features.cc
M media/capture/BUILD.gn
M media/capture/video/android/video_capture_device_factory_android.cc
M media/capture/video/chromeos/camera_device_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_delegate_unittest.cc
A media/capture/video/chromeos/public/BUILD.gn
A media/capture/video/chromeos/public/cros_features.cc
A media/capture/video/chromeos/public/cros_features.h
M media/capture/video/chromeos/video_capture_device_factory_chromeos.cc
M media/capture/video/chromeos/video_capture_device_factory_chromeos.h
M media/capture/video/linux/video_capture_device_factory_linux.cc
M media/capture/video/mac/video_capture_device_factory_mac.mm
M media/capture/video/video_capture_device_factory.cc
M media/capture/video/video_capture_device_factory.h
M media/capture/video/video_capture_device_unittest.cc
M media/capture/video/win/video_capture_device_factory_win.cc
M services/video_capture/device_factory_provider_impl.cc
M services/video_capture/device_factory_provider_impl.h
M services/video_capture/public/mojom/device_factory_provider.mojom
25 files changed, 146 insertions(+), 196 deletions(-)
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
Patch set 13:Code-Review +1
Patch set 13:Commit-Queue +2
Try jobs failed on following builders:
chromium_presubmit on luci.chromium.try (JOB_FAILED, https://ci.chromium.org/p/chromium/builders/luci.chromium.try/chromium_presubmit/153977)
tsepez@: PTAL *.mojom
Just removing stuff from mojom? If so, then LG.
To view, visit change 1107008. To unsubscribe, or for help writing mail filters, visit settings.
Commit Bot merged this change.
[Video Capture Service, ChromeOS] Separate startup of CameraHalDispatcher from instantiation of VideoCaptureDeviceFactory
Separate startup of CameraHalDispatcher from instantiation of
VideoCaptureDeviceFactory by extracting the startup calls from
VideoCaptureDeviceFactoryChromeOS to MediaStreamManager (which is where
VideoCaptureDeviceFactoryChromeOS gets instantiated in case the
video capture service is not enabled).
For ChromeOS builds that use the cros_camera_service for video capture, the
CameraHalDispatcher must be started as part of Chrome startup. This startup has
for now been tied to the instantiation of VideoCaptureDeviceFactoryChromeOS.
With the move to the VideoCaptureService, the instantiation of
VideoCaptureDeviceFactoryChromeOS no longer happens on Chrome startup, but
instead happens on-demand and potentially more than once.
Design Doc: https://docs.google.com/document/d/169LS3U0DD7hHpqZSli0gpCaCqE1eWN4QXFSIGoruPwQ/edit?usp=sharing
Test: See test plan section in design doc.
Bug: 820608
Change-Id: I257a9eaa6368144fd252e532d211dfa716e8c242
Reviewed-on: https://chromium-review.googlesource.com/1107008
Reviewed-by: John Abd-El-Malek <j...@chromium.org>
Reviewed-by: Tom Sepez <tse...@chromium.org>
Reviewed-by: Ricky Liang <jcl...@chromium.org>
Commit-Queue: Christian Fremerey <chfr...@chromium.org>
Cr-Commit-Position: refs/heads/master@{#570542}
---
M content/browser/renderer_host/media/media_stream_manager.cc
M content/browser/renderer_host/media/service_video_capture_provider.cc
M content/browser/renderer_host/media/service_video_capture_provider.h
M content/browser/renderer_host/media/service_video_capture_provider_unittest.cc
M content/browser/service_manager/service_manager_context.cc
M content/public/common/BUILD.gn
M content/public/common/content_features.cc
M media/capture/BUILD.gn
M media/capture/video/android/video_capture_device_factory_android.cc
M media/capture/video/chromeos/camera_device_delegate_unittest.cc
M media/capture/video/chromeos/camera_hal_delegate_unittest.cc
A media/capture/video/chromeos/public/BUILD.gn
A media/capture/video/chromeos/public/cros_features.cc
A media/capture/video/chromeos/public/cros_features.h
M media/capture/video/chromeos/video_capture_device_factory_chromeos.cc
M media/capture/video/chromeos/video_capture_device_factory_chromeos.h
M media/capture/video/linux/video_capture_device_factory_linux.cc
M media/capture/video/mac/video_capture_device_factory_mac.mm
M media/capture/video/video_capture_device_factory.cc
M media/capture/video/video_capture_device_factory.h
M media/capture/video/video_capture_device_unittest.cc
M media/capture/video/win/video_capture_device_factory_win.cc
M services/video_capture/device_factory_provider_impl.cc
M services/video_capture/device_factory_provider_impl.h
M services/video_capture/public/mojom/device_factory_provider.mojom
25 files changed, 146 insertions(+), 196 deletions(-)