Skip to content

Commit

Permalink
Merge pull request #1815 from 100mslive/develop
Browse files Browse the repository at this point in the history
Release 1.10.6: Develop to main
  • Loading branch information
ygit authored Sep 17, 2024
2 parents 85a1d95 + 761841e commit 0a2d2e3
Show file tree
Hide file tree
Showing 49 changed files with 950 additions and 382 deletions.
2 changes: 1 addition & 1 deletion .java-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
openjdk64-17.0.11
17.0.12
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
[![Discord](https://img.shields.io/discord/843749923060711464?label=Join%20on%20Discord)](https://100ms.live/discord)
[![Firebase](https://img.shields.io/badge/Download%20Android-Firebase-green)](https://appdistribution.firebase.dev/i/b623e5310929ab70)
[![TestFlight](https://img.shields.io/badge/Download%20iOS-TestFlight-blue)](https://testflight.apple.com/join/Uhzebmut)
[![Activity](https://img.shields.io/github/commit-activity/m/100mslive/100ms-flutter.svg)](https://github.com/100mslive/100ms-flutter/projects?type=classic)
[![Register](https://img.shields.io/badge/Contact-Know%20More-blue)](https://dashboard.100ms.live/register)

# 100ms Flutter SDK 🎉
Expand Down
46 changes: 46 additions & 0 deletions packages/hms_room_kit/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,52 @@
| hmssdk_flutter | [![Pub Version](https://img.shields.io/pub/v/hmssdk_flutter)](https://pub.dev/packages/hmssdk_flutter) |
| hms_video_plugin | [![Pub Version](https://img.shields.io/pub/v/hms_video_plugin)](https://pub.dev/packages/hms_video_plugin) |

# 1.10.6 - 2024-09-17

| Package | Version |
| ----------------------------| ------ |
| hms_room_kit | 1.1.6 |
| hmssdk_flutter | 1.10.6 |

### Breaking Changes in hms_room_kit

- Removed Noise Cancellation dependency from Prebuilt on Android

Noise Cancellation dependency is removed from Prebuilt on Android.
Users will have to add the dependency manually in their Android project to use Noise Cancellation.
This change is made to reduce the size of the Prebuilt package.
Refer to the [Noise Cancellation](https://www.100ms.live/docs/flutter/v2/how-to-guides/extend-capabilities/noise-cancellation) documentation for more details.


### hmssdk_flutter

- Added Camera Zoom Controls in `HMSCameraControls`

Users can now control the camera zoom using the `HMSCameraControls` class. The `setZoom` method can be used to set the zoom level of the camera.

Learn more about Camera Zoom Controls [here](https://www.100ms.live/docs/flutter/v2/how-to-guides/configure-your-device/camera/camera-controls).

### hms_room_kit

- Added support to control Automatic Gain Control and Noise Suppresion in Prebuilt

Prebuilt now supports toggling Automatic Gain Control (AGC) and Noise Suppresion for better audio quality. Users can enable or disable AGC and Noise Suppresion from the prebuilt interface.

- Resolved an issue where the Prebuilt UI was not updating on performing End Session

- Hand Raise sorting based on Time

Hand Raise list is now sorted based on the time of raising the hand. Refer to the [Hand Raise](https://www.100ms.live/docs/flutter/v2/how-to-guides/interact-with-room/peer/large-room) documentation for more details.

- Added support to perform Switch Role of any user on Prebuilt

Users can now switch the role of any user, if they have necessary permissions, from the Prebuilt interface. Refer to the [Change Role](https://www.100ms.live/docs/flutter/v2/how-to-guides/interact-with-room/peer/change-role) documentation for more details.

Uses Android SDK 2.9.67 & iOS SDK 1.16.1

**Full Changelog**: [1.10.5...1.10.6](https://github.com/100mslive/100ms-flutter/compare/1.10.5...1.10.6)


## 1.1.5 - 2024-07-25

| Package | Version |
Expand Down
1 change: 0 additions & 1 deletion packages/hms_room_kit/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
[![Discord](https://img.shields.io/discord/843749923060711464?label=Join%20on%20Discord)](https://100ms.live/discord)
[![Firebase](https://img.shields.io/badge/Download%20Android-Firebase-green)](https://appdistribution.firebase.dev/i/b623e5310929ab70)
[![TestFlight](https://img.shields.io/badge/Download%20iOS-TestFlight-blue)](https://testflight.apple.com/join/Uhzebmut)
[![Activity](https://img.shields.io/github/commit-activity/m/100mslive/100ms-flutter.svg)](https://github.com/100mslive/100ms-flutter/projects/1)
[![Register](https://img.shields.io/badge/Contact-Know%20More-blue)](https://dashboard.100ms.live/register)

<p align="center" width="100%">
Expand Down
36 changes: 27 additions & 9 deletions packages/hms_room_kit/example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5,37 +5,46 @@ PODS:
- HMSHLSPlayerSDK (0.0.2):
- HMSAnalyticsSDK (= 0.0.2)
- HMSNoiseCancellationModels (1.0.0)
- HMSSDK (1.9.0):
- HMSSDK (1.16.1):
- HMSAnalyticsSDK (= 0.0.2)
- HMSWebRTC (= 1.0.6168)
- hmssdk_flutter (1.10.1):
- HMSWebRTC (= 1.0.6171)
- hmssdk_flutter (1.10.6):
- Flutter
- HMSBroadcastExtensionSDK (= 0.0.9)
- HMSHLSPlayerSDK (= 0.0.2)
- HMSNoiseCancellationModels (= 1.0.0)
- HMSSDK (= 1.9.0)
- HMSWebRTC (1.0.6168)
- HMSSDK (= 1.16.1)
- HMSWebRTC (1.0.6171)
- image_picker_ios (0.0.1):
- Flutter
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
- permission_handler_apple (9.1.1):
- Flutter
- pointer_interceptor_ios (0.0.1):
- Flutter
- share_plus (0.0.1):
- Flutter
- shared_preferences_foundation (0.0.1):
- Flutter
- FlutterMacOS
- url_launcher_ios (0.0.1):
- Flutter
- webview_flutter_wkwebview (0.0.1):
- Flutter

DEPENDENCIES:
- Flutter (from `Flutter`)
- hmssdk_flutter (from `.symlinks/plugins/hmssdk_flutter/ios`)
- image_picker_ios (from `.symlinks/plugins/image_picker_ios/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
- pointer_interceptor_ios (from `.symlinks/plugins/pointer_interceptor_ios/ios`)
- share_plus (from `.symlinks/plugins/share_plus/ios`)
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
- webview_flutter_wkwebview (from `.symlinks/plugins/webview_flutter_wkwebview/ios`)

SPEC REPOS:
trunk:
Expand All @@ -51,31 +60,40 @@ EXTERNAL SOURCES:
:path: Flutter
hmssdk_flutter:
:path: ".symlinks/plugins/hmssdk_flutter/ios"
image_picker_ios:
:path: ".symlinks/plugins/image_picker_ios/ios"
path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/darwin"
permission_handler_apple:
:path: ".symlinks/plugins/permission_handler_apple/ios"
pointer_interceptor_ios:
:path: ".symlinks/plugins/pointer_interceptor_ios/ios"
share_plus:
:path: ".symlinks/plugins/share_plus/ios"
shared_preferences_foundation:
:path: ".symlinks/plugins/shared_preferences_foundation/darwin"
url_launcher_ios:
:path: ".symlinks/plugins/url_launcher_ios/ios"
webview_flutter_wkwebview:
:path: ".symlinks/plugins/webview_flutter_wkwebview/ios"

SPEC CHECKSUMS:
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7
HMSAnalyticsSDK: 4d2a88a729b1eb42f3d25f217c28937ec318a5b7
HMSBroadcastExtensionSDK: d80fe325f6c928bd8e5176290b5a4b7ae15d6fbb
HMSHLSPlayerSDK: 6a54ad4d12f3dc2270d1ecd24019d71282a4f6a3
HMSNoiseCancellationModels: a3bda1405a16015632f4bcabd46ce48f35103b02
HMSSDK: 96bdafc1c610aabfecd1155ad7e3c1bc45b3a6cb
hmssdk_flutter: c2ad70779ed9355577afbbe1047fb20f862820ac
HMSWebRTC: a302f0d6c94f7bee94f3265adb7bb1c6569e7ee5
HMSSDK: 31e779fbf9c95335d88475a7f9f42fb077692e30
hmssdk_flutter: da118bf9558b0556b609cdc14540dca5514291ac
HMSWebRTC: f6f4f02a665fda6d9d8a5b223272045c3d9486fb
image_picker_ios: 99dfe1854b4fa34d0364e74a78448a0151025425
path_provider_foundation: 3784922295ac71e43754bd15e0653ccfd36a147c
permission_handler_apple: e76247795d700c14ea09e3a2d8855d41ee80a2e6
pointer_interceptor_ios: 9280618c0b2eeb80081a343924aa8ad756c21375
share_plus: c3fef564749587fc939ef86ffb283ceac0baf9f5
shared_preferences_foundation: b4c3b4cddf1c21f02770737f147a3f5da9d39695
url_launcher_ios: bbd758c6e7f9fd7b5b1d4cde34d2b95fcce5e812
webview_flutter_wkwebview: 4f3e50f7273d31e5500066ed267e3ae4309c5ae4

PODFILE CHECKSUM: cc1f88378b4bfcf93a6ce00d2c587857c6008d3b

Expand Down
6 changes: 3 additions & 3 deletions packages/hms_room_kit/example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -238,15 +238,15 @@ packages:
path: ".."
relative: true
source: path
version: "1.1.5"
version: "1.1.6"
hmssdk_flutter:
dependency: transitive
description:
name: hmssdk_flutter
sha256: "2da8500708d8a8ebfa3d3ffb2f1deafd0ff23828dfaff6fdd1b4367da6337cf0"
sha256: "0097739f0005593738021d8c3d56179aee3ae46fa704a0d0be419b4ece4c350d"
url: "https://pub.dev"
source: hosted
version: "1.10.5"
version: "1.10.6"
http:
dependency: transitive
description:
Expand Down
2 changes: 1 addition & 1 deletion packages/hms_room_kit/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ publish_to: "none" # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.1.5
version: 1.1.6

environment:
sdk: ">=3.0.0 <4.0.0"
Expand Down
13 changes: 13 additions & 0 deletions packages/hms_room_kit/lib/src/assets/icons/peer_settings.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 5 additions & 1 deletion packages/hms_room_kit/lib/src/common/utility_functions.dart
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,8 @@ class Utilities {
required bool joinWithMutedAudio,
required bool isSoftwareDecoderDisabled,
required bool isNoiseCancellationEnabled,
required bool isAutomaticGainControlEnabled,
required bool isNoiseSuppressionEnabled,
HMSAudioMode? audioMode,
}) {
return HMSTrackSetting(
Expand All @@ -414,7 +416,9 @@ class Utilities {
? HMSTrackInitState.MUTED
: HMSTrackInitState.UNMUTED,
audioMode: audioMode,
enableNoiseCancellation: isNoiseCancellationEnabled),
enableNoiseCancellation: isNoiseCancellationEnabled,
enableAutomaticGainControl: isAutomaticGainControlEnabled,
enableNoiseSupression: isNoiseSuppressionEnabled),
videoTrackSetting: HMSVideoTrackSetting(
trackInitialState: joinWithMutedVideo
? HMSTrackInitState.MUTED
Expand Down
14 changes: 12 additions & 2 deletions packages/hms_room_kit/lib/src/hms_prebuilt_options.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,25 @@ class HMSPrebuiltOptions {
final HMSIOSScreenshareConfig? iOSScreenshareConfig;

///To enable noise cancellation in prebuilt.
///Default value is true
///Default value is false
final bool enableNoiseCancellation;

///To enable automatic gain control in prebuilt.
///Default value is false
final bool isAutomaticGainControlEnabled;

///To enable noise suppression in prebuilt.
///Default value is false
final bool isNoiseSuppressionEnabled;

///[HMSPrebuiltOptions] is a class that is used to pass the options to the prebuilt
HMSPrebuiltOptions(
{this.userName,
this.userId,
this.endPoints,
this.debugInfo = false,
this.iOSScreenshareConfig,
this.enableNoiseCancellation = false});
this.enableNoiseCancellation = false,
this.isAutomaticGainControlEnabled = false,
this.isNoiseSuppressionEnabled = false});
}
8 changes: 6 additions & 2 deletions packages/hms_room_kit/lib/src/hmssdk_interactor.dart
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ class HMSSDKInteractor {
bool isAudioMixerDisabled = true,
HMSAudioMode audioMode = HMSAudioMode.VOICE,
bool isPrebuilt = false,
bool isNoiseCancellationEnabled = false}) {
bool isNoiseCancellationEnabled = false,
bool isAutomaticGainControlEnabled = false,
bool isNoiseSuppressionEnabled = false}) {
HMSLogSettings hmsLogSettings = HMSLogSettings(
maxDirSizeInBytes: 1000000,
isLogStorageEnabled: true,
Expand All @@ -50,7 +52,9 @@ class HMSSDKInteractor {
joinWithMutedAudio: joinWithMutedAudio,
isSoftwareDecoderDisabled: isSoftwareDecoderDisabled,
audioMode: audioMode,
isNoiseCancellationEnabled: isNoiseCancellationEnabled);
isNoiseCancellationEnabled: isNoiseCancellationEnabled,
isAutomaticGainControlEnabled: isAutomaticGainControlEnabled,
isNoiseSuppressionEnabled: isNoiseSuppressionEnabled);

hmsSDK = HMSSDK(
iOSScreenshareConfig: iOSScreenshareConfig,
Expand Down
34 changes: 33 additions & 1 deletion packages/hms_room_kit/lib/src/meeting/meeting_store.dart
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,6 @@ class MeetingStore extends ChangeNotifier
void endRoom(bool lock, String? reason) {
isEndRoomCalled = true;
_hmsSDKInteractor.endRoom(lock, reason ?? "", this);
_hmsSDKInteractor.destroy();
}

void removePeerFromRoom(HMSPeer peer) {
Expand Down Expand Up @@ -666,16 +665,45 @@ class MeetingStore extends ChangeNotifier
void toggleLocalPeerHandRaise() {
if (isRaisedHand) {
_hmsSDKInteractor.lowerLocalPeerHand(hmsActionResultListener: this);
resetTimestampWhenHandDown();
} else {
_hmsSDKInteractor.raiseLocalPeerHand(hmsActionResultListener: this);
setTimestampWhenHandRaise();
}
}

void setTimestampWhenHandRaise() {
int currentTime = DateTime.now().millisecondsSinceEpoch;

_hmsSDKInteractor.changeMetadata(
metadata:
"{\"isBRBOn\":false,\"prevRole\":\"$previousRole\",\"handRaisedAt\":${currentTime}}",
hmsActionResultListener: this);
}

void resetTimestampWhenHandDown() {
_hmsSDKInteractor.changeMetadata(
metadata: "{\"isBRBOn\":false,\"prevRole\":\"$previousRole\"}",
hmsActionResultListener: this);
}

void lowerRemotePeerHand(HMSPeer forPeer) {
_hmsSDKInteractor.lowerRemotePeerHand(
forPeer: forPeer, hmsActionResultListener: this);
}

int _getTimestampFromPeerMetadata(String? metadata) {
if (metadata == null) {
return 0;
}
try {
Map<String, dynamic> metadataMap = jsonDecode(metadata);
return metadataMap["handRaisedAt"];
} catch (e) {
return 0;
}
}

bool isBRB = false;

void changeMetadataBRB() {
Expand Down Expand Up @@ -1604,6 +1632,10 @@ class MeetingStore extends ChangeNotifier
(handDownPeer) => handDownPeer.peer.peerId == peer.peerId);
participantsInMeetingMap[peer.role.name]?[index].updatePeer(peer);
}
participantsInMeetingMap["Hand Raised"]?.sort((a, b) {
return _getTimestampFromPeerMetadata(a.peer.metadata)
.compareTo(_getTimestampFromPeerMetadata(b.peer.metadata));
});
notifyListeners();
} else if (peerUpdate == HMSPeerUpdate.metadataChanged) {
participantsInMeetingMap[peer.role.name]?[index].updatePeer(peer);
Expand Down
7 changes: 1 addition & 6 deletions packages/hms_room_kit/lib/src/meeting_screen_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,7 @@ class _MeetingScreenControllerState extends State<MeetingScreenController> {
_meetingStore = MeetingStore(hmsSDKInteractor: widget.hmsSDKInteractor);
_setInitValues();
_joinMeeting();

///If the role is hlsStreaming we set the HLS Player store
if (HMSRoomLayout.roleLayoutData?.screens?.conferencing?.hlsLiveStreaming !=
null) {
_setHLSPlayerStore();
}
_setHLSPlayerStore();
}

///This function joins the room only if the name is not empty
Expand Down
4 changes: 3 additions & 1 deletion packages/hms_room_kit/lib/src/preview_meeting_flow.dart
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ class _PreviewMeetingFlowState extends State<PreviewMeetingFlow> {
Widget build(BuildContext context) {
return HMSRoomLayout.skipPreview
? MeetingScreenController(
user: widget.prebuiltOptions?.userId ?? "",
user: widget.prebuiltOptions?.userName ??
widget.prebuiltOptions?.userId ??
"",
localPeerNetworkQuality: null,
options: widget.prebuiltOptions,
tokenData: widget.tokenData,
Expand Down
4 changes: 4 additions & 0 deletions packages/hms_room_kit/lib/src/screen_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,10 @@ class _ScreenControllerState extends State<ScreenController> {
isAudioMixerDisabled: AppDebugConfig.isAudioMixerDisabled,
isNoiseCancellationEnabled:
widget.options?.enableNoiseCancellation ?? false,
isAutomaticGainControlEnabled:
widget.options?.isAutomaticGainControlEnabled ?? false,
isNoiseSuppressionEnabled:
widget.options?.isNoiseSuppressionEnabled ?? false,
isPrebuilt: true);
await _hmsSDKInteractor.build();

Expand Down
2 changes: 0 additions & 2 deletions packages/hms_room_kit/lib/src/service/app_debug_config.dart
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ class AppDebugConfig {
Setting these values to defaults and can be toggled from the application
This will not be shipped with the ui_kit package and only used for internal testing
*/
static bool skipPreview = false;
static bool mirrorCamera = true;
static bool showStats = false;
static bool isSoftwareDecoderDisabled = true;
Expand All @@ -25,7 +24,6 @@ class AppDebugConfig {

/// Resets the debug configuration to default values
static void resetToDefault() {
skipPreview = false;
mirrorCamera = true;
showStats = false;
isSoftwareDecoderDisabled = true;
Expand Down
Loading

0 comments on commit 0a2d2e3

Please sign in to comment.