From 321829d9324f7b82ef362ccc85f6dd053865080c Mon Sep 17 00:00:00 2001 From: gxalpha Date: Tue, 29 Aug 2023 14:41:32 +0200 Subject: [PATCH] mac-avcapture: Log if portrait or studio light effects are active These effects can remain enabled between devices (so enabling it on one device can mean it's later also enabled on another device), leading to cases of capture cards getting blurred. Logging that the effects are enabled should make it easier to spot this in support. --- plugins/mac-avcapture/av-capture.mm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/plugins/mac-avcapture/av-capture.mm b/plugins/mac-avcapture/av-capture.mm index 8266ddd8f..d70378d2d 100644 --- a/plugins/mac-avcapture/av-capture.mm +++ b/plugins/mac-avcapture/av-capture.mm @@ -1118,6 +1118,18 @@ static void capture_device(av_capture *capture, AVCaptureDevice *dev, obs_data_t obs_data_set_string(settings, "device_name", name); obs_data_set_string(settings, "device", dev.uniqueID.UTF8String); AVLOG(LOG_INFO, "Selected device '%s'", name); + if (@available(macOS 12.0, *)) { + if ([dev isPortraitEffectActive]) + AVLOG(LOG_WARNING, "Portrait effect is active on selected device"); + } + if (@available(macOS 12.3, *)) { + if ([dev isCenterStageActive]) + AVLOG(LOG_WARNING, "Center Stage effect is active on selected device"); + } + if (@available(macOS 13.0, *)) { + if ([dev isStudioLightActive]) + AVLOG(LOG_WARNING, "Studio Light effect is active on selected device"); + } if ((capture->use_preset = obs_data_get_bool(settings, "use_preset"))) { if (!init_preset(capture, dev, settings))