mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 16:22:00 +00:00
Bug 1915562 - For the SCK backend, Add a pref to allow enumerating displays with the CG backend. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D220565
This commit is contained in:
parent
4b478f1f10
commit
ebbda8290c
@ -112,8 +112,15 @@ std::shared_ptr<VideoCaptureModule::DeviceInfo>
|
||||
DesktopCaptureImpl::CreateDeviceInfo(const int32_t aId,
|
||||
const CaptureDeviceType aType) {
|
||||
if (aType == CaptureDeviceType::Screen) {
|
||||
return CreateDesktopDeviceInfo(
|
||||
aId, CreateScreenCaptureInfo(CreateDesktopCaptureOptions()));
|
||||
auto options = CreateDesktopCaptureOptions();
|
||||
#ifdef XP_MACOSX
|
||||
options.set_allow_sck_capturer(
|
||||
mozilla::StaticPrefs::
|
||||
media_getdisplaymedia_screencapturekit_enabled_AtStartup() &&
|
||||
mozilla::StaticPrefs::
|
||||
media_getdisplaymedia_screencapturekit_enumeration_enabled_AtStartup());
|
||||
#endif
|
||||
return CreateDesktopDeviceInfo(aId, CreateScreenCaptureInfo(options));
|
||||
}
|
||||
if (aType == CaptureDeviceType::Window) {
|
||||
return CreateDesktopDeviceInfo(
|
||||
|
@ -11389,6 +11389,16 @@
|
||||
type: bool
|
||||
value: false
|
||||
mirror: once
|
||||
|
||||
# Use the libwebrtc ScreenCaptureKit desktop capture backend on Mac for screen
|
||||
# enumeration when enabled.
|
||||
# When this is false and the backend is used (see above), the older CoreGraphics
|
||||
# backend is used to enumerate CGDirectDisplayIDs, which the ScreenCaptureKit
|
||||
# backend understand as well.
|
||||
- name: media.getdisplaymedia.screencapturekit.enumeration.enabled
|
||||
type: bool
|
||||
value: false
|
||||
mirror: once
|
||||
#endif
|
||||
|
||||
# Turn off any cameras (but not mics) while in the background. This is desirable
|
||||
|
Loading…
Reference in New Issue
Block a user