From 9a2618efece786d3c360400969a064debf51bf71 Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Tue, 1 Sep 2026 15:29:33 +0800 Subject: [PATCH 1/5] feat: upgrade to libwebrtc m150. --- android/build.gradle | 2 +- ios/livekit_client.podspec | 2 +- macos/livekit_client.podspec | 2 +- pubspec.yaml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/android/build.gradle b/android/build.gradle index 5a671d109..1df4a933d 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -60,7 +60,7 @@ android { dependencies { testImplementation("org.jetbrains.kotlin:kotlin-test") testImplementation("org.mockito:mockito-core:5.0.0") - implementation 'io.github.webrtc-sdk:android:144.7559.09' + implementation 'io.github.webrtc-sdk:android:150.7871.01' implementation 'io.livekit:noise:2.0.0' // Audio device/focus/mode routing. Pinned to the same revision used by // the LiveKit Android SDK (AudioSwitchHandler). diff --git a/ios/livekit_client.podspec b/ios/livekit_client.podspec index 31f817fb4..e5cee430e 100644 --- a/ios/livekit_client.podspec +++ b/ios/livekit_client.podspec @@ -16,6 +16,6 @@ Pod::Spec.new do |s| s.static_framework = true s.dependency 'Flutter' - s.dependency 'WebRTC-SDK', '144.7559.09' + s.dependency 'WebRTC-SDK', '150.7871.01' s.dependency 'flutter_webrtc' end diff --git a/macos/livekit_client.podspec b/macos/livekit_client.podspec index bccde255c..19a179eaf 100644 --- a/macos/livekit_client.podspec +++ b/macos/livekit_client.podspec @@ -16,6 +16,6 @@ Pod::Spec.new do |s| s.static_framework = true s.dependency 'FlutterMacOS' - s.dependency 'WebRTC-SDK', '144.7559.09' + s.dependency 'WebRTC-SDK', '150.7871.01' s.dependency 'flutter_webrtc' end diff --git a/pubspec.yaml b/pubspec.yaml index 1fb555319..fd9d6688d 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -54,7 +54,7 @@ dependencies: json_annotation: ^4.12.0 # Fix version to avoid version conflicts between WebRTC-SDK pods, which both this package and flutter_webrtc depend on. - flutter_webrtc: 1.6.0 + flutter_webrtc: 1.6.1 dart_webrtc: ^1.8.0 dev_dependencies: From bbc640431a4c358eb749830d5d28a0557809462c Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Mon, 7 Sep 2026 22:20:07 +0800 Subject: [PATCH 2/5] bump version for flutter-webrtc. --- lib/src/livekit.dart | 4 ++++ lib/src/support/webrtc_initialize_options.dart | 4 ++++ pubspec.yaml | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/src/livekit.dart b/lib/src/livekit.dart index c8f5e2fc6..bc6fce639 100644 --- a/lib/src/livekit.dart +++ b/lib/src/livekit.dart @@ -51,6 +51,8 @@ class LiveKitClient { static Future initialize({ bool bypassVoiceProcessing = false, AudioSessionOptions? initialAudioSessionOptions, + bool enableWARP = false, + bool zeroPlayoutDelay = false, }) async { if (lkPlatformIsMobile()) { // bypassVoiceProcessing controls only WebRTC voice processing. Android @@ -62,6 +64,8 @@ class LiveKitClient { bypassVoiceProcessing: bypassVoiceProcessing, initialAudioSessionOptions: initialAudioSessionOptions, includeAndroidAudioConfiguration: lkPlatformIs(PlatformType.android), + enableWARP: enableWARP, + zeroPlayoutDelay: zeroPlayoutDelay, ), ); if (lkPlatformIs(PlatformType.android) && initialAudioSessionOptions != null) { diff --git a/lib/src/support/webrtc_initialize_options.dart b/lib/src/support/webrtc_initialize_options.dart index 7c655fe71..8e1c2812c 100644 --- a/lib/src/support/webrtc_initialize_options.dart +++ b/lib/src/support/webrtc_initialize_options.dart @@ -22,8 +22,12 @@ Map liveKitWebRTCInitializeOptions({ required bool bypassVoiceProcessing, required AudioSessionOptions? initialAudioSessionOptions, required bool includeAndroidAudioConfiguration, + required bool enableWARP, + required bool zeroPlayoutDelay, }) => { if (bypassVoiceProcessing) 'bypassVoiceProcessing': bypassVoiceProcessing, if (includeAndroidAudioConfiguration && initialAudioSessionOptions != null) 'androidAudioConfiguration': androidAudioSessionConfigurationToMap(initialAudioSessionOptions.android), + if (enableWARP) 'enableWARP': enableWARP, + if (zeroPlayoutDelay) 'zeroPlayoutDelay': zeroPlayoutDelay, }; diff --git a/pubspec.yaml b/pubspec.yaml index fd9d6688d..78d266c75 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -54,7 +54,7 @@ dependencies: json_annotation: ^4.12.0 # Fix version to avoid version conflicts between WebRTC-SDK pods, which both this package and flutter_webrtc depend on. - flutter_webrtc: 1.6.1 + flutter_webrtc: 1.6.2 dart_webrtc: ^1.8.0 dev_dependencies: From 317acef5eb3c0be6ec2bf8596f49899673671022 Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Mon, 7 Sep 2026 22:23:59 +0800 Subject: [PATCH 3/5] fix tests. --- lib/src/support/webrtc_initialize_options.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/support/webrtc_initialize_options.dart b/lib/src/support/webrtc_initialize_options.dart index 8e1c2812c..ebcba96e9 100644 --- a/lib/src/support/webrtc_initialize_options.dart +++ b/lib/src/support/webrtc_initialize_options.dart @@ -22,8 +22,8 @@ Map liveKitWebRTCInitializeOptions({ required bool bypassVoiceProcessing, required AudioSessionOptions? initialAudioSessionOptions, required bool includeAndroidAudioConfiguration, - required bool enableWARP, - required bool zeroPlayoutDelay, + bool enableWARP = false, + bool zeroPlayoutDelay = false, }) => { if (bypassVoiceProcessing) 'bypassVoiceProcessing': bypassVoiceProcessing, if (includeAndroidAudioConfiguration && initialAudioSessionOptions != null) From 8c549cf46095f15e640cae8e15b48b35da68a604 Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Tue, 8 Sep 2026 09:05:52 +0800 Subject: [PATCH 4/5] add .changes file. --- .changes/bump-libwebrtc-to-m150 | 1 + 1 file changed, 1 insertion(+) create mode 100644 .changes/bump-libwebrtc-to-m150 diff --git a/.changes/bump-libwebrtc-to-m150 b/.changes/bump-libwebrtc-to-m150 new file mode 100644 index 000000000..b94f81f9c --- /dev/null +++ b/.changes/bump-libwebrtc-to-m150 @@ -0,0 +1 @@ +minor type="changed" "Bump libwebrtc to m150(flutter-webrtc 1.6.2), added `enableWARP` and `zeroPlayoutDelay` options to LiveKitClient.initialize" \ No newline at end of file From 2198c1afd6577c3caf129da0f4713f332b4c8388 Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Tue, 8 Sep 2026 09:30:01 +0800 Subject: [PATCH 5/5] Add rtc.WebRTC.initialize calls for Desktop. --- lib/src/livekit.dart | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/lib/src/livekit.dart b/lib/src/livekit.dart index b3acc784b..ab215be67 100644 --- a/lib/src/livekit.dart +++ b/lib/src/livekit.dart @@ -17,7 +17,7 @@ import 'package:flutter_webrtc/flutter_webrtc.dart' as rtc; import 'audio/audio_manager.dart'; import 'audio/audio_session.dart'; import 'support/native.dart'; -import 'support/platform.dart' show PlatformType, lkPlatformIs, lkPlatformIsMobile; +import 'support/platform.dart' show PlatformType, lkPlatformIs, lkPlatformIsMobile, lkPlatformIsDesktop; import 'support/webrtc_initialize_options.dart'; /// Main entry point to connect to a room. @@ -71,6 +71,16 @@ class LiveKitClient { if (lkPlatformIs(PlatformType.android) && initialAudioSessionOptions != null) { AudioManager.instance.setInitialAudioSessionOptions(initialAudioSessionOptions); } + } else if (lkPlatformIsDesktop()) { + await rtc.WebRTC.initialize( + options: liveKitWebRTCInitializeOptions( + bypassVoiceProcessing: false, + initialAudioSessionOptions: null, + includeAndroidAudioConfiguration: false, + enableWARP: enableWARP, + zeroPlayoutDelay: zeroPlayoutDelay, + ), + ); } } }