Skip to content

Commit

Permalink
πŸ“ Optmize api note
Browse files Browse the repository at this point in the history
  • Loading branch information
javionchen committed Jul 26, 2024
1 parent 9a88a75 commit 4299232
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions lib/src/zego_express_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ class ZegoExpressEngine {
/// When to trigger: After calling the [switchPlayingStream], this callback is triggered when a switch stream request ultimately succeeds or fails.
/// Related callbacks: After the stream switching is successful or failed, you can obtain the current streaming status through the callback function [onPlayerStateUpdate].
///
/// - [streamID] stream ID.
/// - [streamID] The stream ID currently playing.
/// - [errorCode] The error code corresponding to the result of the switch stream, please refer to the error codes document https://docs.zegocloud.com/en/5548.html for details.
static void Function(String streamID, int errorCode)? onPlayerSwitched;

Expand Down Expand Up @@ -1662,7 +1662,7 @@ class ZegoExpressEngine {
static void Function(ZegoScreenCaptureSource source, Rect captureRect)?
onRectChanged;

/// The callback triggered when a screen capture source exception occurred
/// The callback triggered when a screen capture source exception occurred.
///
/// Available since: 3.6.0
/// Description: The callback triggered when the mobile screen capture source exception occurred.
Expand All @@ -1674,7 +1674,7 @@ class ZegoExpressEngine {
static void Function(ZegoScreenCaptureExceptionType exceptionType)?
onMobileScreenCaptureExceptionOccurred;

/// The callback triggered when start screen capture
/// The callback triggered when start screen capture.
///
/// Available since: 3.16.0
/// Description: The callback triggered when calling the start mobile screen capture.
Expand Down
2 changes: 1 addition & 1 deletion lib/src/zego_express_api_device.dart
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ extension ZegoExpressEngineDevice on ZegoExpressEngine {
/// Note: This function is only available in ZegoExpressVideo SDK!
///
/// - [enable] [ZegoVideoSourceTypeCamera] if or not use front camera, `true`: use the front camera, `false`: use the the rear camera.
/// - [channel] Publishing stream channel
/// - [channel] Publishing stream channel.
Future<void> useFrontCamera(bool enable,
{ZegoPublishChannel? channel}) async {
return await ZegoExpressImpl.instance
Expand Down
2 changes: 1 addition & 1 deletion lib/src/zego_express_api_player.dart
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ extension ZegoExpressEnginePlayer on ZegoExpressEngine {
/// Use cases: For the same stream, there may be multiple streams with different resolutions. When the network quality deteriorates, in order to ensure the streaming quality, the streaming end can choose to switch from a high-resolution stream to a low-resolution stream..
/// When to call: After [startPlayingStream].
/// Restrictions: Only supports flv protocol stream.
/// Caution:
/// Related callbacks:
/// 1. The result of the switching request can be obtained through the [onPlayerSwitched] event.
/// 2. When the stream is switched successfully, the current streaming status can be known through the [onPlayerStateUpdate] event.
/// 3. When switching streams fails, there may not necessarily be an [onPlayerStateUpdate] event notification.
Expand Down
8 changes: 4 additions & 4 deletions lib/src/zego_express_defines.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1762,7 +1762,7 @@ enum ZegoVideoSourceType {
/// No capture, i.e. no video data.
None,

/// Video source from camera.
/// The video source comes from the camera (main channel default, and front camera is captured by default). The default is front camera, which can be adjusted to rear via [useFrontCamera].
Camera,

/// Video source from custom capture. The web platform does not currently support.
Expand Down Expand Up @@ -2464,7 +2464,7 @@ class ZegoPublisherConfig {
/// When pushing a flow, review the pattern of the flow. By default, no audit is performed. If you want to use this function, contact ZEGO technical support.
ZegoStreamCensorshipMode? streamCensorshipMode;

/// Inspect flag, works with ZEGO censor SDK. If you want to use this function, contact ZEGO technical support.
/// Inspect flag. If you want to use this function, contact ZEGO technical support.
int? streamCensorFlag;

/// Codec capability negotiation type. By default, no reference to the outcome of the capability negotiation. If you want to use this function, contact ZEGO technical support.
Expand Down Expand Up @@ -2623,10 +2623,10 @@ class ZegoPlayerConfig {
/// Play resource type when stop publish, the default is ZegoStreamResourceTypeDefault. This setting takes effect only if the user sets [resourceMode] to ZegoStreamResourceModeDefaut and [resourceSwitchMode] to ZegoStreamResourceSwitchModeDefault or ZegoStreamResourceSwitchModeSwitchToRTC.
ZegoStreamResourceType? resourceWhenStopPublish;

/// Whether to enable adaptive switching of streams, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
/// Whether to enable adaptive switching of streams, 1 means on, 0 means off. Valid only if [resourceMode] is ZegoStreamResourceModeOnlyL3. Please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
int? adaptiveSwitch;

/// Stream adaptive transcoding template ID list, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
/// Stream adaptive transcoding template ID list. Valid only if [resourceMode] is ZegoStreamResourceModeOnlyL3. Please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
List<int>? adaptiveTemplateIDList;

ZegoPlayerConfig(this.resourceMode,
Expand Down

0 comments on commit 4299232

Please sign in to comment.