Skip to content

Commit 52ebdc9

Browse files
authored
chore: upgrade sdk to 4.2.6.163 (#2331)
1 parent 38cd44d commit 52ebdc9

File tree

5 files changed

+60
-4
lines changed

5 files changed

+60
-4
lines changed

lib/src/agora_rtc_engine.dart

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1326,7 +1326,8 @@ class ChannelMediaOptions {
13261326
this.publishRhythmPlayerTrack,
13271327
this.isInteractiveAudience,
13281328
this.customVideoTrackId,
1329-
this.isAudioFilterable});
1329+
this.isAudioFilterable,
1330+
this.parameters});
13301331

13311332
/// Whether to publish the video captured by the camera: true : Publish the video captured by the camera. false : Do not publish the video captured by the camera.
13321333
@JsonKey(name: 'publishCameraTrack')
@@ -1480,6 +1481,10 @@ class ChannelMediaOptions {
14801481
@JsonKey(name: 'isAudioFilterable')
14811482
final bool? isAudioFilterable;
14821483

1484+
/// Provides the technical preview functionalities or special customizations by configuring the SDK with JSON options. Pointer to the set parameters in a JSON string.
1485+
@JsonKey(name: 'parameters')
1486+
final String? parameters;
1487+
14831488
/// @nodoc
14841489
factory ChannelMediaOptions.fromJson(Map<String, dynamic> json) =>
14851490
_$ChannelMediaOptionsFromJson(json);

lib/src/agora_rtc_engine.g.dart

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/src/impl/agora_rtc_engine_impl.dart

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -970,6 +970,55 @@ class RtcEngineImpl extends rtc_engine_ex_binding.RtcEngineExImpl
970970
return streamIdResult as int;
971971
}
972972

973+
@override
974+
Future<int> createDataStreamEx(
975+
{required DataStreamConfig config,
976+
required RtcConnection connection}) async {
977+
final apiType = 'RtcEngineEx_createDataStreamEx2';
978+
final param = createParams(
979+
{'config': config.toJson(), 'connection': connection.toJson()});
980+
final List<Uint8List> buffers = [];
981+
buffers.addAll(config.collectBufferList());
982+
buffers.addAll(connection.collectBufferList());
983+
final callApiResult = await irisMethodChannel.invokeMethod(
984+
IrisMethodCall(apiType, jsonEncode(param), buffers: buffers));
985+
if (callApiResult.irisReturnCode < 0) {
986+
throw AgoraRtcException(code: callApiResult.irisReturnCode);
987+
}
988+
final rm = callApiResult.data;
989+
final result = rm['result'];
990+
if (result < 0) {
991+
throw AgoraRtcException(code: result);
992+
}
993+
final streamIdResult = rm['streamId'];
994+
return streamIdResult as int;
995+
}
996+
997+
@override
998+
Future<void> leaveChannelEx(
999+
{required RtcConnection connection, LeaveChannelOptions? options}) async {
1000+
final apiType = options == null
1001+
? 'RtcEngineEx_leaveChannelEx'
1002+
: 'RtcEngineEx_leaveChannelEx2';
1003+
final param = createParams(
1004+
{'connection': connection.toJson(), 'options': options?.toJson()});
1005+
final List<Uint8List> buffers = [];
1006+
buffers.addAll(connection.collectBufferList());
1007+
if (options != null) {
1008+
buffers.addAll(options.collectBufferList());
1009+
}
1010+
final callApiResult = await irisMethodChannel.invokeMethod(
1011+
IrisMethodCall(apiType, jsonEncode(param), buffers: buffers));
1012+
if (callApiResult.irisReturnCode < 0) {
1013+
throw AgoraRtcException(code: callApiResult.irisReturnCode);
1014+
}
1015+
final rm = callApiResult.data;
1016+
final result = rm['result'];
1017+
if (result < 0) {
1018+
throw AgoraRtcException(code: result);
1019+
}
1020+
}
1021+
9731022
@override
9741023
Future<void> addVideoWatermark(
9751024
{required String watermarkUrl, required WatermarkOptions options}) async {

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: agora_rtc_engine
22
description: >-
33
Flutter plugin of Agora RTC SDK, allow you to simply integrate Agora Video
44
Calling or Live Video Streaming to your app with just a few lines of code.
5-
version: 6.2.6-sp.426160
5+
version: 6.2.6-sp.426163
66
homepage: https://www.agora.io
77
repository: https://github.com/AgoraIO-Extensions/Agora-Flutter-SDK/tree/main
88
environment:

windows/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ project(${PROJECT_NAME} LANGUAGES CXX)
1212
# not be changed
1313
set(PLUGIN_NAME "agora_rtc_engine_plugin")
1414

15-
set(IRIS_SDK_DOWNLOAD_URL "https://download.agora.io/sdk/release/iris_4.2.6.160-build.2_DCG_Windows_Video_20250425_0632.zip")
16-
set(IRIS_SDK_DOWNLOAD_NAME "iris_4.2.6.160-build.2_DCG_Windows")
15+
set(IRIS_SDK_DOWNLOAD_URL "https://download.agora.io/sdk/release/iris_4.2.6.163-build.1_DCG_Windows_Video_20250605_1036.zip")
16+
set(IRIS_SDK_DOWNLOAD_NAME "iris_4.2.6.163-build.1_DCG_Windows")
1717
set(RTC_SDK_DOWNLOAD_NAME "Agora_Native_SDK_for_Windows_FULL")
1818
set(IRIS_SDK_VERSION "v3_6_2_fix.1")
1919

0 commit comments

Comments
 (0)