commit 4a458a1c9aff0d09ca572c4f4baa02eabbabff1e
parent d5cac86623f5fd9c6fa16b5be54e2d345ed5f06e
Author: Dan Baker <dbaker@mozilla.com>
Date: Tue, 2 Dec 2025 00:18:17 -0700
Bug 2000941 - Vendor libwebrtc from 37ba143ad7
We already cherry-picked this when we vendored fc1cbcf052.
Upstream commit: https://webrtc.googlesource.com/src/+/37ba143ad7d89961d109c91448dd284d16397cbd
Revert "Store a raw_packetization bool in RtpSenderVideo rather than inferring"
This reverts commit fc1cbcf05221bf26b6fa94ecb018a5225060ddb4.
Reason for revert: Reverting while we figure out why the check is triggering downstream
Original change's description:
> Store a raw_packetization bool in RtpSenderVideo rather than inferring
>
> Ensure all calls to SendVideo() use a raw packetizer when they should
> rather than inferring it from the absence of |codec_type| - an issue
> when the caller doesn't know the correct packetization (eg
> RTPSenderVideoFrameTransformerDelegate).
>
> Bug: b/446768451
> Change-Id: Ib628d69ac1697de63cc293c5f4c681d6450f72d9
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/411560
> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> Auto-Submit: Tony Herre <herre@google.com>
> Reviewed-by: Henrik Boström <hbos@webrtc.org>
> Commit-Queue: Henrik Boström <hbos@webrtc.org>
> Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#45724}
Bug: b/446768451
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I456daecded27f9e52e126b8e5760238704f67300
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/411940
Auto-Submit: Tomas Gunnarsson <tommi@webrtc.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#45731}
Diffstat:
5 files changed, 425 insertions(+), 626 deletions(-)
diff --git a/third_party/libwebrtc/README.mozilla.last-vendor b/third_party/libwebrtc/README.mozilla.last-vendor
@@ -1,4 +1,4 @@
# ./mach python dom/media/webrtc/third_party_build/vendor-libwebrtc.py --from-local /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc --commit mozpatches libwebrtc
-libwebrtc updated from /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-12-02T07:15:03.047914+00:00.
+libwebrtc updated from /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-12-02T07:18:04.622295+00:00.
# base of lastest vendoring
-a67950874f
+37ba143ad7
diff --git a/third_party/libwebrtc/moz-patch-stack/37ba143ad7.no-op-cherry-pick-msg b/third_party/libwebrtc/moz-patch-stack/37ba143ad7.no-op-cherry-pick-msg
@@ -1 +0,0 @@
-We already cherry-picked this when we vendored fc1cbcf052.
diff --git a/third_party/libwebrtc/moz-patch-stack/p0001.patch b/third_party/libwebrtc/moz-patch-stack/p0001.patch
@@ -1,200 +1,118 @@
From: Daniel Baker <dbaker@mozilla.com>
-Date: Mon, 1 Dec 2025 23:58:28 -0700
-Subject: (tmp-cherry-pick) Revert "Store a raw_packetization bool in
- RtpSenderVideo rather than inferring" (37ba143ad7)
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
+Date: Mon, 1 Dec 2025 19:31:22 -0700
+Subject: (tmp-cherry-pick) [M142] Revert "Add instructions for removing a
+ Trampoline-wrapped Signal" (29d6eabaf0)
-This reverts commit fc1cbcf05221bf26b6fa94ecb018a5225060ddb4.
+This reverts commit bb6b3aab159ebcd825526cf831f54170ccb2584d.
-Reason for revert: Reverting while we figure out why the check is triggering downstream
+Reason for revert: Need to fix downstream Chromium issues.
Original change's description:
-> Store a raw_packetization bool in RtpSenderVideo rather than inferring
+> Add instructions for removing a Trampoline-wrapped Signal
>
-> Ensure all calls to SendVideo() use a raw packetizer when they should
-> rather than inferring it from the absence of |codec_type| - an issue
-> when the caller doesn't know the correct packetization (eg
-> RTPSenderVideoFrameTransformerDelegate).
+> Also apply the instructions to one Signal.
>
-> Bug: b/446768451
-> Change-Id: Ib628d69ac1697de63cc293c5f4c681d6450f72d9
-> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/411560
-> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
-> Auto-Submit: Tony Herre <herre@google.com>
-> Reviewed-by: Henrik Boström <hbos@webrtc.org>
-> Commit-Queue: Henrik Boström <hbos@webrtc.org>
-> Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
-> Cr-Commit-Position: refs/heads/main@{#45724}
+> Bug: webrtc:42222066
+> Change-Id: I63409d968d27a843b0ac7c61a122a1b685cb7a6f
+> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/408883
+> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
+> Commit-Queue: Harald Alvestrand <hta@webrtc.org>
+> Cr-Commit-Position: refs/heads/main@{#45624}
-Bug: b/446768451
-No-Presubmit: true
-No-Tree-Checks: true
-No-Try: true
-Change-Id: I456daecded27f9e52e126b8e5760238704f67300
-Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/411940
-Auto-Submit: Tomas Gunnarsson <tommi@webrtc.org>
-Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
-Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
-Cr-Commit-Position: refs/heads/main@{#45731}
+(cherry picked from commit 716c8eb942a74ad641bbace8c1db521b4857c636)
+
+Bug: webrtc:42222066, chromium:449225599, chromium:450516559
+No-IWYU: Revert
+Change-Id: I7fdf1694664b11ffcfd91916f1e98ef88254059d
+Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/413923
+Auto-Submit: Harald Alvestrand <hta@webrtc.org>
+Commit-Queue: Harald Alvestrand <hta@webrtc.org>
+Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
+Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
+Cr-Original-Commit-Position: refs/heads/main@{#45840}
+Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/415743
+Commit-Queue: Guido Urdaneta <guidou@webrtc.org>
+Reviewed-by: Harald Alvestrand <hta@webrtc.org>
+Cr-Commit-Position: refs/branch-heads/7444@{#2}
+Cr-Branched-From: f70dc714a073397356f6ed866481da73f90f0b96-refs/heads/main@{#45766}
---
- call/rtp_video_sender.cc | 2 --
- modules/rtp_rtcp/source/rtp_sender_video.cc | 7 +---
- modules/rtp_rtcp/source/rtp_sender_video.h | 3 --
- .../source/rtp_sender_video_unittest.cc | 36 +++----------------
- 4 files changed, 6 insertions(+), 42 deletions(-)
+ p2p/base/ice_transport_internal.cc | 5 +++--
+ p2p/base/ice_transport_internal.h | 9 ++++++---
+ rtc_base/sigslot_trampoline.h | 12 ------------
+ 3 files changed, 9 insertions(+), 17 deletions(-)
-diff --git a/call/rtp_video_sender.cc b/call/rtp_video_sender.cc
-index 78144121d1..25cc81396c 100644
---- a/call/rtp_video_sender.cc
-+++ b/call/rtp_video_sender.cc
-@@ -324,8 +324,6 @@ std::vector<RtpStreamSender> CreateRtpStreamSenders(
- }
- video_config.frame_transformer = frame_transformer;
- video_config.task_queue_factory = &env.task_queue_factory();
-- video_config.raw_packetization = rtp_config.raw_payload;
--
- auto sender_video = std::make_unique<RTPSenderVideo>(video_config);
- rtp_streams.emplace_back(std::move(rtp_rtcp), std::move(sender_video),
- std::move(fec_generator));
-diff --git a/modules/rtp_rtcp/source/rtp_sender_video.cc b/modules/rtp_rtcp/source/rtp_sender_video.cc
-index 64276b00d8..ee7414b582 100644
---- a/modules/rtp_rtcp/source/rtp_sender_video.cc
-+++ b/modules/rtp_rtcp/source/rtp_sender_video.cc
-@@ -177,7 +177,6 @@ RTPSenderVideo::RTPSenderVideo(const Config& config)
- require_frame_encryption_(config.require_frame_encryption),
- generic_descriptor_auth_experiment_(
- !config.field_trials->IsDisabled("WebRTC-GenericDescriptorAuth")),
-- raw_packetization_(config.raw_packetization),
- absolute_capture_time_sender_(config.clock),
- frame_transformer_delegate_(
- config.frame_transformer
-@@ -499,9 +498,6 @@ bool RTPSenderVideo::SendVideo(int payload_type,
- std::vector<uint32_t> csrcs) {
- RTC_CHECK_RUNS_SERIALIZED(&send_checker_);
-
-- // Codec type can only be absent when using raw packetization.
-- RTC_CHECK(raw_packetization_ || codec_type.has_value());
--
- if (video_header.frame_type == VideoFrameType::kEmptyFrame)
- return true;
-
-@@ -678,8 +674,7 @@ bool RTPSenderVideo::SendVideo(int payload_type,
- }
-
- std::unique_ptr<RtpPacketizer> packetizer =
-- RtpPacketizer::Create(raw_packetization_ ? std::nullopt : codec_type,
-- payload, limits, video_header);
-+ RtpPacketizer::Create(codec_type, payload, limits, video_header);
-
- const size_t num_packets = packetizer->NumPackets();
-
-diff --git a/modules/rtp_rtcp/source/rtp_sender_video.h b/modules/rtp_rtcp/source/rtp_sender_video.h
-index 681675e27b..8e300214af 100644
---- a/modules/rtp_rtcp/source/rtp_sender_video.h
-+++ b/modules/rtp_rtcp/source/rtp_sender_video.h
-@@ -90,7 +90,6 @@ class RTPSenderVideo : public RTPVideoFrameSenderInterface {
- const FieldTrialsView* field_trials = nullptr;
- scoped_refptr<FrameTransformerInterface> frame_transformer;
- TaskQueueFactory* task_queue_factory = nullptr;
-- bool raw_packetization = false;
- };
-
- explicit RTPSenderVideo(const Config& config);
-@@ -250,8 +249,6 @@ class RTPSenderVideo : public RTPVideoFrameSenderInterface {
- // Set to true if the generic descriptor should be authenticated.
- const bool generic_descriptor_auth_experiment_;
-
-- const bool raw_packetization_;
--
- AbsoluteCaptureTimeSender absolute_capture_time_sender_
- RTC_GUARDED_BY(send_checker_);
- // Tracks updates to the active decode targets and decides when active decode
-diff --git a/modules/rtp_rtcp/source/rtp_sender_video_unittest.cc b/modules/rtp_rtcp/source/rtp_sender_video_unittest.cc
-index b63bafe34e..9479714d8a 100644
---- a/modules/rtp_rtcp/source/rtp_sender_video_unittest.cc
-+++ b/modules/rtp_rtcp/source/rtp_sender_video_unittest.cc
-@@ -166,14 +166,12 @@ class TestRtpSenderVideo : public RTPSenderVideo {
- public:
- TestRtpSenderVideo(Clock* clock,
- RTPSender* rtp_sender,
-- const FieldTrialsView& field_trials,
-- bool raw_packetization)
-+ const FieldTrialsView& field_trials)
- : RTPSenderVideo([&] {
- Config config;
- config.clock = clock;
- config.rtp_sender = rtp_sender;
- config.field_trials = &field_trials;
-- config.raw_packetization = raw_packetization;
- return config;
- }()) {}
- ~TestRtpSenderVideo() override {}
-@@ -189,7 +187,7 @@ class TestRtpSenderVideo : public RTPSenderVideo {
-
- class RtpSenderVideoTest : public ::testing::Test {
- public:
-- explicit RtpSenderVideoTest(bool raw_packetization = false)
-+ RtpSenderVideoTest()
- : fake_clock_(kStartTime),
- env_(CreateEnvironment(&fake_clock_)),
- retransmission_rate_limiter_(&fake_clock_, 1000),
-@@ -203,8 +201,7 @@ class RtpSenderVideoTest : public ::testing::Test {
- rtp_sender_video_(
- std::make_unique<TestRtpSenderVideo>(&fake_clock_,
- rtp_module_.RtpSender(),
-- env_.field_trials(),
-- raw_packetization)) {
-+ env_.field_trials())) {
- rtp_module_.SetSequenceNumber(kSeqNum);
- rtp_module_.SetStartTimestamp(0);
- }
-@@ -1359,8 +1356,7 @@ TEST_F(RtpSenderVideoTest,
+diff --git a/p2p/base/ice_transport_internal.cc b/p2p/base/ice_transport_internal.cc
+index 7843a8b37d..a4b96db00b 100644
+--- a/p2p/base/ice_transport_internal.cc
++++ b/p2p/base/ice_transport_internal.cc
+@@ -236,7 +236,8 @@ RTCError IceConfig::IsValid() const {
+ }
- TEST_F(RtpSenderVideoTest, AbsoluteCaptureTime) {
- rtp_sender_video_ = std::make_unique<TestRtpSenderVideo>(
-- &fake_clock_, rtp_module_.RtpSender(), env_.field_trials(),
-- /*raw_packetization=*/false);
-+ &fake_clock_, rtp_module_.RtpSender(), env_.field_trials());
+ IceTransportInternal::IceTransportInternal()
+- : role_conflict_trampoline_(this),
++ : candidate_gathered_trampoline_(this),
++ role_conflict_trampoline_(this),
+ ice_transport_state_changed_trampoline_(this),
+ destroyed_trampoline_(this) {}
- constexpr Timestamp kAbsoluteCaptureTimestamp = Timestamp::Millis(12345678);
- uint8_t kFrame[kMaxPacketLength];
-@@ -1526,12 +1522,7 @@ TEST_F(RtpSenderVideoTest, SendGenericVideo) {
- EXPECT_THAT(sent_payload.subview(1), ElementsAreArray(kDeltaPayload));
+@@ -265,7 +266,7 @@ void IceTransportInternal::RemoveGatheringStateCallback(
+ void IceTransportInternal::SubscribeCandidateGathered(
+ absl::AnyInvocable<void(IceTransportInternal*, const Candidate&)>
+ callback) {
+- candidate_gathered_callbacks_.AddReceiver(std::move(callback));
++ candidate_gathered_trampoline_.Subscribe(std::move(callback));
}
--class RtpSenderVideoRawPacketizationTest : public RtpSenderVideoTest {
-- public:
-- RtpSenderVideoRawPacketizationTest() : RtpSenderVideoTest(true) {}
--};
--
--TEST_F(RtpSenderVideoRawPacketizationTest, SendRawVideo) {
-+TEST_F(RtpSenderVideoTest, SendRawVideo) {
- const uint8_t kPayloadTypeRaw = 111;
- const uint8_t kPayload[] = {11, 22, 33, 44, 55};
+ void IceTransportInternal::SubscribeRoleConflict(
+diff --git a/p2p/base/ice_transport_internal.h b/p2p/base/ice_transport_internal.h
+index 9f6722c8ad..c83a7d70d7 100644
+--- a/p2p/base/ice_transport_internal.h
++++ b/p2p/base/ice_transport_internal.h
+@@ -352,9 +352,11 @@ class RTC_EXPORT IceTransportInternal : public PacketTransportInternal {
+ void RemoveGatheringStateCallback(const void* removal_tag);
-@@ -1547,23 +1538,6 @@ TEST_F(RtpSenderVideoRawPacketizationTest, SendRawVideo) {
- EXPECT_THAT(sent_payload, ElementsAreArray(kPayload));
- }
+ // Handles sending and receiving of candidates.
++ sigslot::signal2<IceTransportInternal*, const Candidate&>
++ SignalCandidateGathered;
+ void NotifyCandidateGathered(IceTransportInternal* transport,
+ const Candidate& candidate) {
+- candidate_gathered_callbacks_.Send(transport, candidate);
++ SignalCandidateGathered(transport, candidate);
+ }
+ void SubscribeCandidateGathered(
+ absl::AnyInvocable<void(IceTransportInternal*, const Candidate&)>
+@@ -462,8 +464,9 @@ class RTC_EXPORT IceTransportInternal : public PacketTransportInternal {
+ candidate_pair_change_callback_;
--TEST_F(RtpSenderVideoRawPacketizationTest, SendVideoWithSetCodecTypeStillRaw) {
-- const uint8_t kPayloadTypeRaw = 111;
-- const uint8_t kPayload[] = {11, 22, 33, 44, 55};
--
-- // Send a frame with codectype "generic"
-- RTPVideoHeader video_header;
-- video_header.frame_type = VideoFrameType::kVideoFrameKey;
-- ASSERT_TRUE(rtp_sender_video_->SendVideo(
-- kPayloadTypeRaw, VideoCodecType::kVideoCodecGeneric, 1234,
-- fake_clock_.CurrentTime(), kPayload, sizeof(kPayload), video_header,
-- TimeDelta::PlusInfinity(), {}));
--
-- // Should still be packetized as raw.
-- EXPECT_THAT(transport_.last_sent_packet().payload(),
-- ElementsAreArray(kPayload));
--}
--
- class RtpSenderVideoWithFrameTransformerTest : public ::testing::Test {
- public:
- RtpSenderVideoWithFrameTransformerTest()
+ private:
+- CallbackList<IceTransportInternal*, const Candidate&>
+- candidate_gathered_callbacks_;
++ SignalTrampoline<IceTransportInternal,
++ &IceTransportInternal::SignalCandidateGathered>
++ candidate_gathered_trampoline_;
+ SignalTrampoline<IceTransportInternal,
+ &IceTransportInternal::SignalRoleConflict>
+ role_conflict_trampoline_;
+diff --git a/rtc_base/sigslot_trampoline.h b/rtc_base/sigslot_trampoline.h
+index a399e4177f..590e73d97b 100644
+--- a/rtc_base/sigslot_trampoline.h
++++ b/rtc_base/sigslot_trampoline.h
+@@ -51,18 +51,6 @@ namespace webrtc {
+ // my_class_object.SubscibeMyNamedEvent(
+ // SafeInvocable(target.safety_flag_.flag(),
+ // [target] { target.function(); }
+-// WHEN REMOVING THE SIGNAL
+-// Make a CL that will:
+-// - Delete the SignalMyNamedEvent signal
+-// - Change my_named_event_trampoline_ to my_named_event_callbacks,
+-// of type CallbackList<function arguments>
+-// - Change SubscribeMyNamedEvent to call my_named_event_callbacks.AddReceiver
+-// - Change NotifyMyNamedEvent to call my_named_event_callbacks_.Send
+-// - If UnsubscribeMyNamedEvent exists, change that also.
+-// - Delete the initialization of my_named_event_trampoline_ from the
+-// relevant constructor.
+-// Sending this through the bots will flush out remaining references to
+-// SignalMyNamedEvent.
+ namespace internal {
+ template <typename MemberPtrT>
+ struct member_pointer_traits;
diff --git a/third_party/libwebrtc/moz-patch-stack/p0002.patch b/third_party/libwebrtc/moz-patch-stack/p0002.patch
@@ -1,118 +1,331 @@
-From: Daniel Baker <dbaker@mozilla.com>
-Date: Mon, 1 Dec 2025 19:31:22 -0700
-Subject: (tmp-cherry-pick) [M142] Revert "Add instructions for removing a
- Trampoline-wrapped Signal" (29d6eabaf0)
+From: Palak Agarwal <agpalak@google.com>
+Date: Tue, 7 Oct 2025 13:45:52 +0200
+Subject: (cherry-pick-branch-heads/7390) [M141] Add logging while creating
+ {Window|Screen}Capturer
-This reverts commit bb6b3aab159ebcd825526cf831f54170ccb2584d.
+(cherry picked from commit 6908505ae0eba5d530ad0bb4b37d4654a4f36c95)
-Reason for revert: Need to fix downstream Chromium issues.
-
-Original change's description:
-> Add instructions for removing a Trampoline-wrapped Signal
->
-> Also apply the instructions to one Signal.
->
-> Bug: webrtc:42222066
-> Change-Id: I63409d968d27a843b0ac7c61a122a1b685cb7a6f
-> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/408883
-> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
-> Commit-Queue: Harald Alvestrand <hta@webrtc.org>
-> Cr-Commit-Position: refs/heads/main@{#45624}
-
-(cherry picked from commit 716c8eb942a74ad641bbace8c1db521b4857c636)
-
-Bug: webrtc:42222066, chromium:449225599, chromium:450516559
-No-IWYU: Revert
-Change-Id: I7fdf1694664b11ffcfd91916f1e98ef88254059d
-Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/413923
-Auto-Submit: Harald Alvestrand <hta@webrtc.org>
-Commit-Queue: Harald Alvestrand <hta@webrtc.org>
-Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
-Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
-Cr-Original-Commit-Position: refs/heads/main@{#45840}
-Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/415743
-Commit-Queue: Guido Urdaneta <guidou@webrtc.org>
+Fixed: chromium:450184498
+Bug: chromium:448881311
+Change-Id: I0f043f58bf831e6822451cac99a8972a054ffdf7
+Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/414800
+Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
-Cr-Commit-Position: refs/branch-heads/7444@{#2}
-Cr-Branched-From: f70dc714a073397356f6ed866481da73f90f0b96-refs/heads/main@{#45766}
+Commit-Queue: Palak Agarwal <agpalak@google.com>
+Cr-Original-Commit-Position: refs/heads/main@{#45856}
+Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/415420
+Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
+Cr-Commit-Position: refs/branch-heads/7390@{#3}
+Cr-Branched-From: 2f553bf8d573c90176d51559b76dfc836996c8f5-refs/heads/main@{#45520}
---
- p2p/base/ice_transport_internal.cc | 5 +++--
- p2p/base/ice_transport_internal.h | 9 ++++++---
- rtc_base/sigslot_trampoline.h | 12 ------------
- 3 files changed, 9 insertions(+), 17 deletions(-)
+ modules/desktop_capture/desktop_capturer.cc | 15 +++++++++++++++
+ .../linux/x11/screen_capturer_x11.cc | 6 ++++++
+ .../linux/x11/window_capturer_x11.cc | 4 ++++
+ modules/desktop_capture/screen_capturer_darwin.mm | 7 +++++++
+ .../desktop_capture/screen_capturer_fuchsia.cc | 3 +++
+ modules/desktop_capture/screen_capturer_linux.cc | 4 ++++
+ modules/desktop_capture/screen_capturer_null.cc | 4 ++++
+ modules/desktop_capture/screen_capturer_win.cc | 6 ++++++
+ modules/desktop_capture/window_capturer_linux.cc | 4 ++++
+ modules/desktop_capture/window_capturer_mac.mm | 2 ++
+ modules/desktop_capture/window_capturer_null.cc | 3 +++
+ modules/desktop_capture/window_capturer_win.cc | 7 +++++++
+ 12 files changed, 65 insertions(+)
-diff --git a/p2p/base/ice_transport_internal.cc b/p2p/base/ice_transport_internal.cc
-index 7843a8b37d..a4b96db00b 100644
---- a/p2p/base/ice_transport_internal.cc
-+++ b/p2p/base/ice_transport_internal.cc
-@@ -236,7 +236,8 @@ RTCError IceConfig::IsValid() const {
+diff --git a/modules/desktop_capture/desktop_capturer.cc b/modules/desktop_capture/desktop_capturer.cc
+index ae9aba26ee..bf63f73178 100644
+--- a/modules/desktop_capture/desktop_capturer.cc
++++ b/modules/desktop_capture/desktop_capturer.cc
+@@ -21,6 +21,7 @@
+ #include "modules/desktop_capture/desktop_capturer_differ_wrapper.h"
+ #include "modules/desktop_capture/desktop_geometry.h"
+ #include "modules/desktop_capture/shared_memory.h"
++#include "rtc_base/logging.h"
+ #include "system_wrappers/include/metrics.h"
+
+ #if defined(WEBRTC_WIN)
+@@ -81,18 +82,26 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateWindowCapturer(
+ #if defined(RTC_ENABLE_WIN_WGC)
+ if (options.allow_wgc_window_capturer() &&
+ IsWgcSupported(CaptureType::kWindow)) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateWindowCapturer "
++ "creates DesktopCapturer of type WgcCapturerWin";
+ return WgcCapturerWin::CreateRawWindowCapturer(options);
+ }
+ #endif // defined(RTC_ENABLE_WIN_WGC)
+
+ #if defined(WEBRTC_WIN)
+ if (options.allow_cropping_window_capturer()) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateWindowCapturer "
++ "creates DesktopCapturer of type CroppingWindowCapturerWin";
+ return CroppingWindowCapturer::CreateCapturer(options);
+ }
+ #endif // defined(WEBRTC_WIN)
+
+ std::unique_ptr<DesktopCapturer> capturer = CreateRawWindowCapturer(options);
+ if (capturer && options.detect_updated_region()) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateWindowCapturer "
++ "creates DesktopCapturer of type "
++ "DesktopCapturerDifferWrapper over a base capturer";
+ capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
+ }
+
+@@ -105,12 +114,18 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateScreenCapturer(
+ #if defined(RTC_ENABLE_WIN_WGC)
+ if (options.allow_wgc_screen_capturer() &&
+ IsWgcSupported(CaptureType::kScreen)) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateScreenCapturer "
++ "creates DesktopCapturer of type WgcCapturerWin";
+ return WgcCapturerWin::CreateRawScreenCapturer(options);
+ }
+ #endif // defined(RTC_ENABLE_WIN_WGC)
+
+ std::unique_ptr<DesktopCapturer> capturer = CreateRawScreenCapturer(options);
+ if (capturer && options.detect_updated_region()) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateScreenCapturer creates "
++ "DesktopCapturer of type DesktopCapturerDifferWrapper over a base "
++ "capturer";
+ capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
+ }
+
+diff --git a/modules/desktop_capture/linux/x11/screen_capturer_x11.cc b/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
+index 90dd797cb3..f10dcabc7e 100644
+--- a/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
++++ b/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
+@@ -511,8 +511,14 @@ std::unique_ptr<DesktopCapturer> ScreenCapturerX11::CreateRawScreenCapturer(
+ if (!options.x_display())
+ return nullptr;
+
++ RTC_LOG(LS_INFO)
++ << "video capture: ScreenCapturerX11::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type ScreenCapturerX11";
+ std::unique_ptr<ScreenCapturerX11> capturer(new ScreenCapturerX11());
+ if (!capturer->Init(options)) {
++ RTC_LOG(LS_INFO)
++ << "video capture: ScreenCapturerX11::CreateRawScreenCapturer "
++ "DesktopCapturer is null because it can not be initiated";
+ return nullptr;
+ }
+
+diff --git a/modules/desktop_capture/linux/x11/window_capturer_x11.cc b/modules/desktop_capture/linux/x11/window_capturer_x11.cc
+index 8e592ff2d9..9505205b76 100644
+--- a/modules/desktop_capture/linux/x11/window_capturer_x11.cc
++++ b/modules/desktop_capture/linux/x11/window_capturer_x11.cc
+@@ -247,6 +247,10 @@ std::unique_ptr<DesktopCapturer> WindowCapturerX11::CreateRawWindowCapturer(
+ const DesktopCaptureOptions& options) {
+ if (!options.x_display())
+ return nullptr;
++
++ RTC_LOG(LS_INFO)
++ << "video capture: WindowCapturerX11::CreateRawWindowCapturer creates "
++ "DesktopCapturer of type WindowCapturerX11";
+ return std::unique_ptr<DesktopCapturer>(new WindowCapturerX11(options));
}
- IceTransportInternal::IceTransportInternal()
-- : role_conflict_trampoline_(this),
-+ : candidate_gathered_trampoline_(this),
-+ role_conflict_trampoline_(this),
- ice_transport_state_changed_trampoline_(this),
- destroyed_trampoline_(this) {}
-
-@@ -265,7 +266,7 @@ void IceTransportInternal::RemoveGatheringStateCallback(
- void IceTransportInternal::SubscribeCandidateGathered(
- absl::AnyInvocable<void(IceTransportInternal*, const Candidate&)>
- callback) {
-- candidate_gathered_callbacks_.AddReceiver(std::move(callback));
-+ candidate_gathered_trampoline_.Subscribe(std::move(callback));
+diff --git a/modules/desktop_capture/screen_capturer_darwin.mm b/modules/desktop_capture/screen_capturer_darwin.mm
+index 95a877c45d..3f14ddfe58 100644
+--- a/modules/desktop_capture/screen_capturer_darwin.mm
++++ b/modules/desktop_capture/screen_capturer_darwin.mm
+@@ -12,6 +12,7 @@
+
+ #include "modules/desktop_capture/mac/screen_capturer_mac.h"
+ #include "modules/desktop_capture/mac/screen_capturer_sck.h"
++#include "rtc_base/logging.h"
+
+ namespace webrtc {
+
+@@ -27,10 +28,16 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ std::unique_ptr<DesktopCapturer> sck_capturer =
+ CreateScreenCapturerSck(options);
+ if (sck_capturer) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type ScreenCapturerSck";
+ return sck_capturer;
+ }
+ }
+
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type ScreenCapturerMac";
+ auto capturer =
+ std::make_unique<ScreenCapturerMac>(options.configuration_monitor(),
+ options.detect_updated_region(),
+diff --git a/modules/desktop_capture/screen_capturer_fuchsia.cc b/modules/desktop_capture/screen_capturer_fuchsia.cc
+index c3f51ef0fc..2a6c5e753d 100644
+--- a/modules/desktop_capture/screen_capturer_fuchsia.cc
++++ b/modules/desktop_capture/screen_capturer_fuchsia.cc
+@@ -56,6 +56,9 @@ size_t RoundUpToMultiple(size_t value, size_t multiple) {
+
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type ScreenCapturerFuchsia";
+ std::unique_ptr<ScreenCapturerFuchsia> capturer(new ScreenCapturerFuchsia());
+ return capturer;
+ }
+diff --git a/modules/desktop_capture/screen_capturer_linux.cc b/modules/desktop_capture/screen_capturer_linux.cc
+index 94726750c5..f25e08fb59 100644
+--- a/modules/desktop_capture/screen_capturer_linux.cc
++++ b/modules/desktop_capture/screen_capturer_linux.cc
+@@ -13,6 +13,7 @@
+ #include "modules/desktop_capture/desktop_capture_options.h"
+ #include "modules/desktop_capture/desktop_capture_types.h"
+ #include "modules/desktop_capture/desktop_capturer.h"
++#include "rtc_base/logging.h"
+
+ #if defined(WEBRTC_USE_PIPEWIRE)
+ #include "modules/desktop_capture/linux/wayland/base_capturer_pipewire.h"
+@@ -29,6 +30,9 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ const DesktopCaptureOptions& options) {
+ #if defined(WEBRTC_USE_PIPEWIRE)
+ if (options.allow_pipewire() && BaseCapturerPipeWire::IsSupported()) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type BaseCapturerPipeWire";
+ return std::make_unique<BaseCapturerPipeWire>(options,
+ CaptureType::kScreen);
+ }
+diff --git a/modules/desktop_capture/screen_capturer_null.cc b/modules/desktop_capture/screen_capturer_null.cc
+index aa6d4991a0..21b2f46c4d 100644
+--- a/modules/desktop_capture/screen_capturer_null.cc
++++ b/modules/desktop_capture/screen_capturer_null.cc
+@@ -11,12 +11,16 @@
+ #include <memory>
+
+ #include "modules/desktop_capture/desktop_capturer.h"
++#include "rtc_base/logging.h"
+
+ namespace webrtc {
+
+ // static
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates null "
++ "DesktopCapturer";
+ return nullptr;
}
- void IceTransportInternal::SubscribeRoleConflict(
-diff --git a/p2p/base/ice_transport_internal.h b/p2p/base/ice_transport_internal.h
-index 9f6722c8ad..c83a7d70d7 100644
---- a/p2p/base/ice_transport_internal.h
-+++ b/p2p/base/ice_transport_internal.h
-@@ -352,9 +352,11 @@ class RTC_EXPORT IceTransportInternal : public PacketTransportInternal {
- void RemoveGatheringStateCallback(const void* removal_tag);
-
- // Handles sending and receiving of candidates.
-+ sigslot::signal2<IceTransportInternal*, const Candidate&>
-+ SignalCandidateGathered;
- void NotifyCandidateGathered(IceTransportInternal* transport,
- const Candidate& candidate) {
-- candidate_gathered_callbacks_.Send(transport, candidate);
-+ SignalCandidateGathered(transport, candidate);
+diff --git a/modules/desktop_capture/screen_capturer_win.cc b/modules/desktop_capture/screen_capturer_win.cc
+index a5f2052979..6620888f18 100644
+--- a/modules/desktop_capture/screen_capturer_win.cc
++++ b/modules/desktop_capture/screen_capturer_win.cc
+@@ -19,6 +19,7 @@
+ #include "modules/desktop_capture/win/dxgi_duplicator_controller.h"
+ #include "modules/desktop_capture/win/screen_capturer_win_directx.h"
+ #include "modules/desktop_capture/win/screen_capturer_win_gdi.h"
++#include "rtc_base/logging.h"
+
+ namespace webrtc {
+
+@@ -26,6 +27,9 @@ namespace {
+
+ std::unique_ptr<DesktopCapturer> CreateScreenCapturerWinDirectx(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
++ "DesktopCapturer of type ScreenCapturerWinDirectx";
+ std::unique_ptr<DesktopCapturer> capturer(
+ new ScreenCapturerWinDirectx(options));
+ capturer.reset(new BlankDetectorDesktopCapturerWrapper(
+@@ -39,6 +43,8 @@ std::unique_ptr<DesktopCapturer> CreateScreenCapturerWinDirectx(
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ const DesktopCaptureOptions& options) {
+ // Default capturer if no options are enabled is GDI.
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawScreenCapturer "
++ "creates DesktopCapturer of type ScreenCapturerWinGdi";
+ std::unique_ptr<DesktopCapturer> capturer(new ScreenCapturerWinGdi(options));
+
+ // If DirectX is enabled use it as main capturer with GDI as fallback.
+diff --git a/modules/desktop_capture/window_capturer_linux.cc b/modules/desktop_capture/window_capturer_linux.cc
+index f621a63e72..87ea3d5721 100644
+--- a/modules/desktop_capture/window_capturer_linux.cc
++++ b/modules/desktop_capture/window_capturer_linux.cc
+@@ -13,6 +13,7 @@
+ #include "modules/desktop_capture/desktop_capture_options.h"
+ #include "modules/desktop_capture/desktop_capture_types.h"
+ #include "modules/desktop_capture/desktop_capturer.h"
++#include "rtc_base/logging.h"
+
+ #if defined(WEBRTC_USE_PIPEWIRE)
+ #include "modules/desktop_capture/linux/wayland/base_capturer_pipewire.h"
+@@ -29,6 +30,9 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
+ const DesktopCaptureOptions& options) {
+ #if defined(WEBRTC_USE_PIPEWIRE)
+ if (options.allow_pipewire() && BaseCapturerPipeWire::IsSupported()) {
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawWindowCapturer creates "
++ "DesktopCapturer of type BaseCapturerPipeWire";
+ return std::make_unique<BaseCapturerPipeWire>(options,
+ CaptureType::kWindow);
}
- void SubscribeCandidateGathered(
- absl::AnyInvocable<void(IceTransportInternal*, const Candidate&)>
-@@ -462,8 +464,9 @@ class RTC_EXPORT IceTransportInternal : public PacketTransportInternal {
- candidate_pair_change_callback_;
-
- private:
-- CallbackList<IceTransportInternal*, const Candidate&>
-- candidate_gathered_callbacks_;
-+ SignalTrampoline<IceTransportInternal,
-+ &IceTransportInternal::SignalCandidateGathered>
-+ candidate_gathered_trampoline_;
- SignalTrampoline<IceTransportInternal,
- &IceTransportInternal::SignalRoleConflict>
- role_conflict_trampoline_;
-diff --git a/rtc_base/sigslot_trampoline.h b/rtc_base/sigslot_trampoline.h
-index a399e4177f..590e73d97b 100644
---- a/rtc_base/sigslot_trampoline.h
-+++ b/rtc_base/sigslot_trampoline.h
-@@ -51,18 +51,6 @@ namespace webrtc {
- // my_class_object.SubscibeMyNamedEvent(
- // SafeInvocable(target.safety_flag_.flag(),
- // [target] { target.function(); }
--// WHEN REMOVING THE SIGNAL
--// Make a CL that will:
--// - Delete the SignalMyNamedEvent signal
--// - Change my_named_event_trampoline_ to my_named_event_callbacks,
--// of type CallbackList<function arguments>
--// - Change SubscribeMyNamedEvent to call my_named_event_callbacks.AddReceiver
--// - Change NotifyMyNamedEvent to call my_named_event_callbacks_.Send
--// - If UnsubscribeMyNamedEvent exists, change that also.
--// - Delete the initialization of my_named_event_trampoline_ from the
--// relevant constructor.
--// Sending this through the bots will flush out remaining references to
--// SignalMyNamedEvent.
- namespace internal {
- template <typename MemberPtrT>
- struct member_pointer_traits;
+diff --git a/modules/desktop_capture/window_capturer_mac.mm b/modules/desktop_capture/window_capturer_mac.mm
+index a1e6157b87..731090d3fb 100644
+--- a/modules/desktop_capture/window_capturer_mac.mm
++++ b/modules/desktop_capture/window_capturer_mac.mm
+@@ -217,6 +217,8 @@ void WindowCapturerMac::CaptureFrame() {
+ // static
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
++ "creates DesktopCapturer of type WindowCapturerMac";
+ return std::unique_ptr<DesktopCapturer>(new WindowCapturerMac(
+ options.full_screen_window_detector(), options.configuration_monitor()));
+ }
+diff --git a/modules/desktop_capture/window_capturer_null.cc b/modules/desktop_capture/window_capturer_null.cc
+index 2061dc5248..384e186d20 100644
+--- a/modules/desktop_capture/window_capturer_null.cc
++++ b/modules/desktop_capture/window_capturer_null.cc
+@@ -12,6 +12,7 @@
+
+ #include "modules/desktop_capture/desktop_capturer.h"
+ #include "rtc_base/checks.h"
++#include "rtc_base/logging.h"
+
+ namespace webrtc {
+
+@@ -65,6 +66,8 @@ void WindowCapturerNull::CaptureFrame() {
+ // static
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
++ "creates DesktopCapturer of type WindowCapturerNull";
+ return std::unique_ptr<DesktopCapturer>(new WindowCapturerNull());
+ }
+
+diff --git a/modules/desktop_capture/window_capturer_win.cc b/modules/desktop_capture/window_capturer_win.cc
+index 115bc7d9b0..15ed7f5121 100644
+--- a/modules/desktop_capture/window_capturer_win.cc
++++ b/modules/desktop_capture/window_capturer_win.cc
+@@ -15,6 +15,7 @@
+ #include "modules/desktop_capture/desktop_capturer.h"
+ #include "modules/desktop_capture/rgba_color.h"
+ #include "modules/desktop_capture/win/window_capturer_win_gdi.h"
++#include "rtc_base/logging.h"
+
+ #if defined(RTC_ENABLE_WIN_WGC)
+ #include "modules/desktop_capture/blank_detector_desktop_capturer_wrapper.h"
+@@ -28,6 +29,8 @@ namespace webrtc {
+ // static
+ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
+ const DesktopCaptureOptions& options) {
++ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
++ "creates DesktopCapturer of type WindowCapturerWinGdi";
+ std::unique_ptr<DesktopCapturer> capturer(
+ WindowCapturerWinGdi::CreateRawWindowCapturer(options));
+ #if defined(RTC_ENABLE_WIN_WGC)
+@@ -36,6 +39,10 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
+ // BlankDectector capturer will send an error when it detects a failed
+ // GDI rendering, then Fallback capturer will try to capture it again with
+ // WGC.
++ RTC_LOG(LS_INFO)
++ << "video capture: DesktopCapturer::CreateRawWindowCapturer creates "
++ "DesktopCapturer of type FallbackDesktopCapturerWrapper which has a "
++ "fallback capturer of type WgcCapturerWin";
+ capturer = std::make_unique<BlankDetectorDesktopCapturerWrapper>(
+ std::move(capturer), RgbaColor(0, 0, 0, 0),
+ /*check_per_capture*/ true);
diff --git a/third_party/libwebrtc/moz-patch-stack/p0003.patch b/third_party/libwebrtc/moz-patch-stack/p0003.patch
@@ -1,331 +0,0 @@
-From: Palak Agarwal <agpalak@google.com>
-Date: Tue, 7 Oct 2025 13:45:52 +0200
-Subject: (cherry-pick-branch-heads/7390) [M141] Add logging while creating
- {Window|Screen}Capturer
-
-(cherry picked from commit 6908505ae0eba5d530ad0bb4b37d4654a4f36c95)
-
-Fixed: chromium:450184498
-Bug: chromium:448881311
-Change-Id: I0f043f58bf831e6822451cac99a8972a054ffdf7
-Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/414800
-Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
-Reviewed-by: Harald Alvestrand <hta@webrtc.org>
-Commit-Queue: Palak Agarwal <agpalak@google.com>
-Cr-Original-Commit-Position: refs/heads/main@{#45856}
-Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/415420
-Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
-Cr-Commit-Position: refs/branch-heads/7390@{#3}
-Cr-Branched-From: 2f553bf8d573c90176d51559b76dfc836996c8f5-refs/heads/main@{#45520}
----
- modules/desktop_capture/desktop_capturer.cc | 15 +++++++++++++++
- .../linux/x11/screen_capturer_x11.cc | 6 ++++++
- .../linux/x11/window_capturer_x11.cc | 4 ++++
- modules/desktop_capture/screen_capturer_darwin.mm | 7 +++++++
- .../desktop_capture/screen_capturer_fuchsia.cc | 3 +++
- modules/desktop_capture/screen_capturer_linux.cc | 4 ++++
- modules/desktop_capture/screen_capturer_null.cc | 4 ++++
- modules/desktop_capture/screen_capturer_win.cc | 6 ++++++
- modules/desktop_capture/window_capturer_linux.cc | 4 ++++
- modules/desktop_capture/window_capturer_mac.mm | 2 ++
- modules/desktop_capture/window_capturer_null.cc | 3 +++
- modules/desktop_capture/window_capturer_win.cc | 7 +++++++
- 12 files changed, 65 insertions(+)
-
-diff --git a/modules/desktop_capture/desktop_capturer.cc b/modules/desktop_capture/desktop_capturer.cc
-index ae9aba26ee..bf63f73178 100644
---- a/modules/desktop_capture/desktop_capturer.cc
-+++ b/modules/desktop_capture/desktop_capturer.cc
-@@ -21,6 +21,7 @@
- #include "modules/desktop_capture/desktop_capturer_differ_wrapper.h"
- #include "modules/desktop_capture/desktop_geometry.h"
- #include "modules/desktop_capture/shared_memory.h"
-+#include "rtc_base/logging.h"
- #include "system_wrappers/include/metrics.h"
-
- #if defined(WEBRTC_WIN)
-@@ -81,18 +82,26 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateWindowCapturer(
- #if defined(RTC_ENABLE_WIN_WGC)
- if (options.allow_wgc_window_capturer() &&
- IsWgcSupported(CaptureType::kWindow)) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateWindowCapturer "
-+ "creates DesktopCapturer of type WgcCapturerWin";
- return WgcCapturerWin::CreateRawWindowCapturer(options);
- }
- #endif // defined(RTC_ENABLE_WIN_WGC)
-
- #if defined(WEBRTC_WIN)
- if (options.allow_cropping_window_capturer()) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateWindowCapturer "
-+ "creates DesktopCapturer of type CroppingWindowCapturerWin";
- return CroppingWindowCapturer::CreateCapturer(options);
- }
- #endif // defined(WEBRTC_WIN)
-
- std::unique_ptr<DesktopCapturer> capturer = CreateRawWindowCapturer(options);
- if (capturer && options.detect_updated_region()) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateWindowCapturer "
-+ "creates DesktopCapturer of type "
-+ "DesktopCapturerDifferWrapper over a base capturer";
- capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
- }
-
-@@ -105,12 +114,18 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateScreenCapturer(
- #if defined(RTC_ENABLE_WIN_WGC)
- if (options.allow_wgc_screen_capturer() &&
- IsWgcSupported(CaptureType::kScreen)) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateScreenCapturer "
-+ "creates DesktopCapturer of type WgcCapturerWin";
- return WgcCapturerWin::CreateRawScreenCapturer(options);
- }
- #endif // defined(RTC_ENABLE_WIN_WGC)
-
- std::unique_ptr<DesktopCapturer> capturer = CreateRawScreenCapturer(options);
- if (capturer && options.detect_updated_region()) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateScreenCapturer creates "
-+ "DesktopCapturer of type DesktopCapturerDifferWrapper over a base "
-+ "capturer";
- capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
- }
-
-diff --git a/modules/desktop_capture/linux/x11/screen_capturer_x11.cc b/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
-index 90dd797cb3..f10dcabc7e 100644
---- a/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
-+++ b/modules/desktop_capture/linux/x11/screen_capturer_x11.cc
-@@ -511,8 +511,14 @@ std::unique_ptr<DesktopCapturer> ScreenCapturerX11::CreateRawScreenCapturer(
- if (!options.x_display())
- return nullptr;
-
-+ RTC_LOG(LS_INFO)
-+ << "video capture: ScreenCapturerX11::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type ScreenCapturerX11";
- std::unique_ptr<ScreenCapturerX11> capturer(new ScreenCapturerX11());
- if (!capturer->Init(options)) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: ScreenCapturerX11::CreateRawScreenCapturer "
-+ "DesktopCapturer is null because it can not be initiated";
- return nullptr;
- }
-
-diff --git a/modules/desktop_capture/linux/x11/window_capturer_x11.cc b/modules/desktop_capture/linux/x11/window_capturer_x11.cc
-index 8e592ff2d9..9505205b76 100644
---- a/modules/desktop_capture/linux/x11/window_capturer_x11.cc
-+++ b/modules/desktop_capture/linux/x11/window_capturer_x11.cc
-@@ -247,6 +247,10 @@ std::unique_ptr<DesktopCapturer> WindowCapturerX11::CreateRawWindowCapturer(
- const DesktopCaptureOptions& options) {
- if (!options.x_display())
- return nullptr;
-+
-+ RTC_LOG(LS_INFO)
-+ << "video capture: WindowCapturerX11::CreateRawWindowCapturer creates "
-+ "DesktopCapturer of type WindowCapturerX11";
- return std::unique_ptr<DesktopCapturer>(new WindowCapturerX11(options));
- }
-
-diff --git a/modules/desktop_capture/screen_capturer_darwin.mm b/modules/desktop_capture/screen_capturer_darwin.mm
-index 95a877c45d..3f14ddfe58 100644
---- a/modules/desktop_capture/screen_capturer_darwin.mm
-+++ b/modules/desktop_capture/screen_capturer_darwin.mm
-@@ -12,6 +12,7 @@
-
- #include "modules/desktop_capture/mac/screen_capturer_mac.h"
- #include "modules/desktop_capture/mac/screen_capturer_sck.h"
-+#include "rtc_base/logging.h"
-
- namespace webrtc {
-
-@@ -27,10 +28,16 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
- std::unique_ptr<DesktopCapturer> sck_capturer =
- CreateScreenCapturerSck(options);
- if (sck_capturer) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type ScreenCapturerSck";
- return sck_capturer;
- }
- }
-
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type ScreenCapturerMac";
- auto capturer =
- std::make_unique<ScreenCapturerMac>(options.configuration_monitor(),
- options.detect_updated_region(),
-diff --git a/modules/desktop_capture/screen_capturer_fuchsia.cc b/modules/desktop_capture/screen_capturer_fuchsia.cc
-index c3f51ef0fc..2a6c5e753d 100644
---- a/modules/desktop_capture/screen_capturer_fuchsia.cc
-+++ b/modules/desktop_capture/screen_capturer_fuchsia.cc
-@@ -56,6 +56,9 @@ size_t RoundUpToMultiple(size_t value, size_t multiple) {
-
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type ScreenCapturerFuchsia";
- std::unique_ptr<ScreenCapturerFuchsia> capturer(new ScreenCapturerFuchsia());
- return capturer;
- }
-diff --git a/modules/desktop_capture/screen_capturer_linux.cc b/modules/desktop_capture/screen_capturer_linux.cc
-index 94726750c5..f25e08fb59 100644
---- a/modules/desktop_capture/screen_capturer_linux.cc
-+++ b/modules/desktop_capture/screen_capturer_linux.cc
-@@ -13,6 +13,7 @@
- #include "modules/desktop_capture/desktop_capture_options.h"
- #include "modules/desktop_capture/desktop_capture_types.h"
- #include "modules/desktop_capture/desktop_capturer.h"
-+#include "rtc_base/logging.h"
-
- #if defined(WEBRTC_USE_PIPEWIRE)
- #include "modules/desktop_capture/linux/wayland/base_capturer_pipewire.h"
-@@ -29,6 +30,9 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
- const DesktopCaptureOptions& options) {
- #if defined(WEBRTC_USE_PIPEWIRE)
- if (options.allow_pipewire() && BaseCapturerPipeWire::IsSupported()) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type BaseCapturerPipeWire";
- return std::make_unique<BaseCapturerPipeWire>(options,
- CaptureType::kScreen);
- }
-diff --git a/modules/desktop_capture/screen_capturer_null.cc b/modules/desktop_capture/screen_capturer_null.cc
-index aa6d4991a0..21b2f46c4d 100644
---- a/modules/desktop_capture/screen_capturer_null.cc
-+++ b/modules/desktop_capture/screen_capturer_null.cc
-@@ -11,12 +11,16 @@
- #include <memory>
-
- #include "modules/desktop_capture/desktop_capturer.h"
-+#include "rtc_base/logging.h"
-
- namespace webrtc {
-
- // static
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates null "
-+ "DesktopCapturer";
- return nullptr;
- }
-
-diff --git a/modules/desktop_capture/screen_capturer_win.cc b/modules/desktop_capture/screen_capturer_win.cc
-index a5f2052979..6620888f18 100644
---- a/modules/desktop_capture/screen_capturer_win.cc
-+++ b/modules/desktop_capture/screen_capturer_win.cc
-@@ -19,6 +19,7 @@
- #include "modules/desktop_capture/win/dxgi_duplicator_controller.h"
- #include "modules/desktop_capture/win/screen_capturer_win_directx.h"
- #include "modules/desktop_capture/win/screen_capturer_win_gdi.h"
-+#include "rtc_base/logging.h"
-
- namespace webrtc {
-
-@@ -26,6 +27,9 @@ namespace {
-
- std::unique_ptr<DesktopCapturer> CreateScreenCapturerWinDirectx(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawScreenCapturer creates "
-+ "DesktopCapturer of type ScreenCapturerWinDirectx";
- std::unique_ptr<DesktopCapturer> capturer(
- new ScreenCapturerWinDirectx(options));
- capturer.reset(new BlankDetectorDesktopCapturerWrapper(
-@@ -39,6 +43,8 @@ std::unique_ptr<DesktopCapturer> CreateScreenCapturerWinDirectx(
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
- const DesktopCaptureOptions& options) {
- // Default capturer if no options are enabled is GDI.
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawScreenCapturer "
-+ "creates DesktopCapturer of type ScreenCapturerWinGdi";
- std::unique_ptr<DesktopCapturer> capturer(new ScreenCapturerWinGdi(options));
-
- // If DirectX is enabled use it as main capturer with GDI as fallback.
-diff --git a/modules/desktop_capture/window_capturer_linux.cc b/modules/desktop_capture/window_capturer_linux.cc
-index f621a63e72..87ea3d5721 100644
---- a/modules/desktop_capture/window_capturer_linux.cc
-+++ b/modules/desktop_capture/window_capturer_linux.cc
-@@ -13,6 +13,7 @@
- #include "modules/desktop_capture/desktop_capture_options.h"
- #include "modules/desktop_capture/desktop_capture_types.h"
- #include "modules/desktop_capture/desktop_capturer.h"
-+#include "rtc_base/logging.h"
-
- #if defined(WEBRTC_USE_PIPEWIRE)
- #include "modules/desktop_capture/linux/wayland/base_capturer_pipewire.h"
-@@ -29,6 +30,9 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
- const DesktopCaptureOptions& options) {
- #if defined(WEBRTC_USE_PIPEWIRE)
- if (options.allow_pipewire() && BaseCapturerPipeWire::IsSupported()) {
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawWindowCapturer creates "
-+ "DesktopCapturer of type BaseCapturerPipeWire";
- return std::make_unique<BaseCapturerPipeWire>(options,
- CaptureType::kWindow);
- }
-diff --git a/modules/desktop_capture/window_capturer_mac.mm b/modules/desktop_capture/window_capturer_mac.mm
-index a1e6157b87..731090d3fb 100644
---- a/modules/desktop_capture/window_capturer_mac.mm
-+++ b/modules/desktop_capture/window_capturer_mac.mm
-@@ -217,6 +217,8 @@ void WindowCapturerMac::CaptureFrame() {
- // static
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
-+ "creates DesktopCapturer of type WindowCapturerMac";
- return std::unique_ptr<DesktopCapturer>(new WindowCapturerMac(
- options.full_screen_window_detector(), options.configuration_monitor()));
- }
-diff --git a/modules/desktop_capture/window_capturer_null.cc b/modules/desktop_capture/window_capturer_null.cc
-index 2061dc5248..384e186d20 100644
---- a/modules/desktop_capture/window_capturer_null.cc
-+++ b/modules/desktop_capture/window_capturer_null.cc
-@@ -12,6 +12,7 @@
-
- #include "modules/desktop_capture/desktop_capturer.h"
- #include "rtc_base/checks.h"
-+#include "rtc_base/logging.h"
-
- namespace webrtc {
-
-@@ -65,6 +66,8 @@ void WindowCapturerNull::CaptureFrame() {
- // static
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
-+ "creates DesktopCapturer of type WindowCapturerNull";
- return std::unique_ptr<DesktopCapturer>(new WindowCapturerNull());
- }
-
-diff --git a/modules/desktop_capture/window_capturer_win.cc b/modules/desktop_capture/window_capturer_win.cc
-index 115bc7d9b0..15ed7f5121 100644
---- a/modules/desktop_capture/window_capturer_win.cc
-+++ b/modules/desktop_capture/window_capturer_win.cc
-@@ -15,6 +15,7 @@
- #include "modules/desktop_capture/desktop_capturer.h"
- #include "modules/desktop_capture/rgba_color.h"
- #include "modules/desktop_capture/win/window_capturer_win_gdi.h"
-+#include "rtc_base/logging.h"
-
- #if defined(RTC_ENABLE_WIN_WGC)
- #include "modules/desktop_capture/blank_detector_desktop_capturer_wrapper.h"
-@@ -28,6 +29,8 @@ namespace webrtc {
- // static
- std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
- const DesktopCaptureOptions& options) {
-+ RTC_LOG(LS_INFO) << "video capture: DesktopCapturer::CreateRawWindowCapturer "
-+ "creates DesktopCapturer of type WindowCapturerWinGdi";
- std::unique_ptr<DesktopCapturer> capturer(
- WindowCapturerWinGdi::CreateRawWindowCapturer(options));
- #if defined(RTC_ENABLE_WIN_WGC)
-@@ -36,6 +39,10 @@ std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawWindowCapturer(
- // BlankDectector capturer will send an error when it detects a failed
- // GDI rendering, then Fallback capturer will try to capture it again with
- // WGC.
-+ RTC_LOG(LS_INFO)
-+ << "video capture: DesktopCapturer::CreateRawWindowCapturer creates "
-+ "DesktopCapturer of type FallbackDesktopCapturerWrapper which has a "
-+ "fallback capturer of type WgcCapturerWin";
- capturer = std::make_unique<BlankDetectorDesktopCapturerWrapper>(
- std::move(capturer), RgbaColor(0, 0, 0, 0),
- /*check_per_capture*/ true);