From d491744961adccf95ab262434eab06fe35cb5238 Mon Sep 17 00:00:00 2001 From: "duanweiwei1982@gmail.com" Date: Fri, 13 Oct 2023 11:39:24 +0800 Subject: [PATCH] fix: VP9 svc screenshare. --- lib/src/participant/local.dart | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/src/participant/local.dart b/lib/src/participant/local.dart index d39e0108..23a37989 100644 --- a/lib/src/participant/local.dart +++ b/lib/src/participant/local.dart @@ -153,6 +153,14 @@ class LocalParticipant extends Participant { scalabilityMode: 'L3T3_KEY', ); } + + // vp9 svc with screenshare has problem to encode, always use L1T3 here + if (track.source == TrackSource.screenShareVideo && + publishOptions.videoCodec.toLowerCase() == 'vp9') { + publishOptions = publishOptions.copyWith( + scalabilityMode: 'L1T3', + ); + } } // use constraints passed to getUserMedia by default