diff --git a/dita/RTC-NG/API/api_imediaplayer_enableautoswitchagoracdn.dita b/dita/RTC-NG/API/api_imediaplayer_enableautoswitchagoracdn.dita index 22c34baf497..3908b285946 100644 --- a/dita/RTC-NG/API/api_imediaplayer_enableautoswitchagoracdn.dita +++ b/dita/RTC-NG/API/api_imediaplayer_enableautoswitchagoracdn.dita @@ -1,12 +1,12 @@ - + - <ph keyref="enableAutoSwitchAgoraCDN" /> + <ph keyref="enableAutoSwitchAgoraCDN"/> 开启/关闭自动切换媒体资源的 CDN 线路。 - + @@ -14,20 +14,27 @@

int enableAutoSwitchAgoraCDN(boolean enable); - + - (int)enableAutoSwitchAgoraCDN:(BOOL)enable; virtual int enableAutoSwitchAgoraCDN(bool enable) = 0; abstract enableAutoSwitchAgoraCDN(enable: boolean): number; public abstract int EnableAutoSwitchAgoraCDN(bool enable); abstract enableAutoSwitchAgoraCDN(enable: boolean): number; Future<void> enableAutoSwitchAgoraCDN(bool enable); -

+

详情 +
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该方法自 v4.6.0 版本废弃。
+
+

如果你想设置 SDK 根据网络情况自动切换媒体资源 CDN 线路,你可以调用该方法。

-

请在 前调用该方法。

+

请在 前调用该方法。

参数 @@ -37,17 +44,17 @@ 设置是否开启自动切换媒体资源的 CDN 线路:
    -
  • :开启自动切换媒体资源的 CDN 线路。
  • -
  • :(默认) 关闭自动切换媒体资源的 CDN 线路。
  • +
  • :开启自动切换媒体资源的 CDN 线路。
  • +
  • :(默认) 关闭自动切换媒体资源的 CDN 线路。
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_getagoracdnlinecount.dita b/dita/RTC-NG/API/api_imediaplayer_getagoracdnlinecount.dita index e382ba44c66..8676d608847 100644 --- a/dita/RTC-NG/API/api_imediaplayer_getagoracdnlinecount.dita +++ b/dita/RTC-NG/API/api_imediaplayer_getagoracdnlinecount.dita @@ -1,12 +1,12 @@ - + - <ph keyref="getAgoraCDNLineCount" /> + <ph keyref="getAgoraCDNLineCount"/> 获取媒体资源的 CDN 线路数量。 - + @@ -14,15 +14,24 @@

int getAgoraCDNLineCount(); - + - (int)getAgoraCDNLineCount; virtual int getAgoraCDNLineCount() = 0; abstract getAgoraCDNLineCount(): number; public abstract int GetAgoraCDNLineCount(); abstract getAgoraCDNLineCount(): number; Future<int> getAgoraCDNLineCount(); -

+

+
+ 详情 +
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
+
+
返回值
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_getcurrentagoracdnindex.dita b/dita/RTC-NG/API/api_imediaplayer_getcurrentagoracdnindex.dita index a2345607b8d..ad58034c727 100644 --- a/dita/RTC-NG/API/api_imediaplayer_getcurrentagoracdnindex.dita +++ b/dita/RTC-NG/API/api_imediaplayer_getcurrentagoracdnindex.dita @@ -1,12 +1,12 @@ - + - <ph keyref="getCurrentAgoraCDNIndex" /> + <ph keyref="getCurrentAgoraCDNIndex"/> 获取当前使用的媒体资源的 CDN 线路索引。 - + @@ -14,20 +14,30 @@

int getCurrentAgoraCDNIndex(); - + - (int)getCurrentAgoraCDNIndex; virtual int getCurrentAgoraCDNIndex() = 0; abstract getCurrentAgoraCDNIndex(): number; public abstract int GetCurrentAgoraCDNIndex(); abstract getCurrentAgoraCDNIndex(): number; Future<int> getCurrentAgoraCDNIndex(); -

+

+
+ 详情 +
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该方法自 v4.6.0 版本废弃。
+
+
+
返回值
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_openwithagoracdnsrc.dita b/dita/RTC-NG/API/api_imediaplayer_openwithagoracdnsrc.dita index 811886b82ee..e0ba9862d41 100644 --- a/dita/RTC-NG/API/api_imediaplayer_openwithagoracdnsrc.dita +++ b/dita/RTC-NG/API/api_imediaplayer_openwithagoracdnsrc.dita @@ -1,12 +1,12 @@ - + - <ph keyref="openWithAgoraCDNSrc" /> + <ph keyref="openWithAgoraCDNSrc"/> 打开媒体资源,并通过自研调度中心请求媒体资源的所有 CDN 线路。 - + @@ -15,7 +15,7 @@

int openWithAgoraCDNSrc(String src, long startPos); - + - (int)openWithAgoraCDNSrc:(NSString *)src startPos:(NSInteger)startPos; virtual int openWithAgoraCDNSrc(const char* src, int64_t startPos) = 0; @@ -25,13 +25,20 @@ abstract openWithAgoraCDNSrc(src: string, startPos: number): number; Future<void> openWithAgoraCDNSrc( {required String src, required int startPos}); -

+

详情 - -

调用该方法后,声网会打开媒体资源并通过自研调度中心请求媒体资源的所有 CDN 线路。默认使用第一个线路,你也可以通过 自行切换线路。

-

如果你希望保障连接和播放媒体资源的安全性,你可以协商鉴权字段 (sign) 和鉴权过期时间 (ts)。确定字段后,请将其作为 URL 的 query parameter 以更新媒体资源的网路路径。例如: +

+ +
弃用:
+
该方法自 v4.6.0 版本废弃。
+
该 API 自 v4.6.0 版本废弃。
+
+
+ +

调用该方法后,声网会打开媒体资源并通过自研调度中心请求媒体资源的所有 CDN 线路。默认使用第一个线路,你也可以通过 自行切换线路。

+

如果你希望保障连接和播放媒体资源的安全性,你可以协商鉴权字段 (sign) 和鉴权过期时间 (ts)。确定字段后,请将其作为 URL 的 query parameter 以更新媒体资源的网路路径。例如:

  • 媒体资源网络路径为 rtmp://$domain/$appName/$streamName
  • 通过鉴权信息更新过的媒体资源网络路径为 rtmp://$domain/$appName/$streamName?ts=$ts&sign=$sign
  • @@ -39,7 +46,7 @@

    鉴权信息说明:

      -
    • sign : 通过 authKey + appName + streamName + ts 进行 md5 算法加密得出的鉴权字段。你需要咨询你的 authKey 字段内容。
    • +
    • sign : 通过 authKey + appName + streamName + ts 进行 md5 算法加密得出的鉴权字段。你需要咨询你的 authKey 字段内容。
    • ts : 鉴权过期时间。你可以指定再过多久鉴权过期。例如, 24h1h30m20s

    @@ -59,9 +66,9 @@
    <ph keyref="return-section-title"/>

    方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

    -
      +
      • 0: 方法调用成功。
      • < 0: 方法调用失败。详见了解详情和解决建议。
    - \ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_renewagoracdnsrctoken.dita b/dita/RTC-NG/API/api_imediaplayer_renewagoracdnsrctoken.dita index 69b874e3511..aebca85222b 100644 --- a/dita/RTC-NG/API/api_imediaplayer_renewagoracdnsrctoken.dita +++ b/dita/RTC-NG/API/api_imediaplayer_renewagoracdnsrctoken.dita @@ -1,12 +1,12 @@ - + - <ph keyref="renewAgoraCDNSrcToken" /> + <ph keyref="renewAgoraCDNSrcToken"/> 更新媒体资源网络路径的鉴权信息。 - + @@ -15,7 +15,7 @@

    int renewAgoraCDNSrcToken(String token, long ts); - + - (int)renewAgoraCDNSrcToken:(NSString *)token ts:(NSInteger)ts; virtual int renewAgoraCDNSrcToken(const char* token, int64_t ts) = 0; @@ -24,14 +24,20 @@ public abstract int RenewAgoraCDNSrcToken(string token, Int64 ts); abstract renewAgoraCDNSrcToken(token: string, ts: number): number; Future<void> renewAgoraCDNSrcToken({required String token, required int ts}); -

    +

详情 -

当鉴权信息过期(超出 ts 时间)时,你可以调用 重新打开或切换媒体资源,并传入带新鉴权信息(如更新 ts 字段内容)的媒体资源网络路径。

-

如果你在切换媒体资源线路 () 时遇到鉴权信息过期,你需要调用该方法并传入新的鉴权信息,以更新该媒体资源网络路径的鉴权信息。更新鉴权信息后,你还需调用 才能完成线路切换。

+
+ +
弃用:
+
该方法自 v4.6.0 版本废弃。
+
+
+

当鉴权信息过期(超出 ts 时间)时,你可以调用 重新打开或切换媒体资源,并传入带新鉴权信息(如更新 ts 字段内容)的媒体资源网络路径。

+

如果你在切换媒体资源线路 () 时遇到鉴权信息过期,你需要调用该方法并传入新的鉴权信息,以更新该媒体资源网络路径的鉴权信息。更新鉴权信息后,你还需调用 才能完成线路切换。

-

为避免鉴权信息频繁过期,请务必根据场景需求设置合适的 ts 字段内容或

+

为避免鉴权信息频繁过期,请务必根据场景需求设置合适的 ts 字段内容或

参数 @@ -48,9 +54,9 @@
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
- \ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_switchagoracdnlinebyindex.dita b/dita/RTC-NG/API/api_imediaplayer_switchagoracdnlinebyindex.dita index 17a7e68afa2..349cdd51c6a 100644 --- a/dita/RTC-NG/API/api_imediaplayer_switchagoracdnlinebyindex.dita +++ b/dita/RTC-NG/API/api_imediaplayer_switchagoracdnlinebyindex.dita @@ -1,12 +1,12 @@ - + - <ph keyref="switchAgoraCDNLineByIndex" /> + <ph keyref="switchAgoraCDNLineByIndex"/> 切换媒体资源的 CDN 线路。 - + @@ -15,7 +15,7 @@

int switchAgoraCDNLineByIndex(int index); - + - (int)switchAgoraCDNLineByIndex:(int)index; virtual int switchAgoraCDNLineByIndex(int index) = 0; @@ -24,18 +24,25 @@ public abstract int SwitchAgoraCDNLineByIndex(int index); abstract switchAgoraCDNLineByIndex(index: number): number; Future<void> switchAgoraCDNLineByIndex(int index); -

+

详情 -

通过 打开媒体资源后,如果你想切换媒体资源 CDN 线路,你可以调用该方法。 +

+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该方法自 v4.6.0 版本废弃。
+
+
+

通过 打开媒体资源后,如果你想切换媒体资源 CDN 线路,你可以调用该方法。

    -
  • 请在 后调用该方法。
  • -
  • 该方法在 前后均可调用。如果你在 前调用该方法,切换不会立即生效。SDK 会等待播放完成后再切换媒体资源的 CDN 线路。
  • +
  • 请在 后调用该方法。
  • +
  • 该方法在 前后均可调用。如果你在 前调用该方法,切换不会立即生效。SDK 会等待播放完成后再切换媒体资源的 CDN 线路。

@@ -49,9 +56,9 @@
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
- \ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayer_switchagoracdnsrc.dita b/dita/RTC-NG/API/api_imediaplayer_switchagoracdnsrc.dita index e04933332c1..0e8c7db9e88 100644 --- a/dita/RTC-NG/API/api_imediaplayer_switchagoracdnsrc.dita +++ b/dita/RTC-NG/API/api_imediaplayer_switchagoracdnsrc.dita @@ -1,12 +1,12 @@ - + - <ph keyref="switchAgoraCDNSrc" /> + <ph keyref="switchAgoraCDNSrc"/> 切换媒体资源。 - + @@ -15,7 +15,7 @@

int switchAgoraCDNSrc(String src, boolean syncPts); - + - (int)switchAgoraCDNSrc:(NSString *)src syncPts:(BOOL)syncPts; virtual int switchAgoraCDNSrc(const char* src, bool syncPts = false) = 0; @@ -24,19 +24,25 @@ public abstract int SwitchAgoraCDNSrc(string src, bool syncPts = false); abstract switchAgoraCDNSrc(src: string, syncPts?: boolean): number; Future<void> switchAgoraCDNSrc({required String src, bool syncPts = false}); -

+

详情 -

如果用户需要自定义播放线路,你可以调用该方法实现媒体资源切换。声网会通过自研调度中心支持调度线路,提升观看用户体验。如果用户不需要自定义播放线路,你可以调用 实现媒体资源切换。 +

+ +
弃用:
+
该方法自 v4.6.0 版本废弃。
+
+
+

如果用户需要自定义播放线路,你可以调用该方法实现媒体资源切换。声网会通过自研调度中心支持调度线路,提升观看用户体验。如果用户不需要自定义播放线路,你可以调用 实现媒体资源切换。

    -
  • 请在 后调用该方法。
  • -
  • 该方法在 前后均可调用。如果你在 前调用该方法,SDK 会等你调用 后再完成线路切换。 +
  • 请在 后调用该方法。
  • +
  • 该方法在 前后均可调用。如果你在 前调用该方法,SDK 会等你调用 后再完成线路切换。
-

+

参数 @@ -51,19 +57,19 @@
    -
  • :同步。
  • -
  • :(默认) 不同步。
  • +
  • :同步。
  • +
  • :(默认) 不同步。
-

如果媒体资源为直播流,你只能将该参数设置为 ,否则 SDK 切换媒体资源会失败。如果媒体资源为点播流,你可以根据场景需求对该参数赋值。

+

如果媒体资源为直播流,你只能将该参数设置为 ,否则 SDK 切换媒体资源会失败。如果媒体资源为点播流,你可以根据场景需求对该参数赋值。

<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_imediaplayersourceobserver_onagoracdntokenwillexpire.dita b/dita/RTC-NG/API/api_imediaplayersourceobserver_onagoracdntokenwillexpire.dita new file mode 100644 index 00000000000..5fe17ce042f --- /dev/null +++ b/dita/RTC-NG/API/api_imediaplayersourceobserver_onagoracdntokenwillexpire.dita @@ -0,0 +1,48 @@ + + + + <ph keyref="onAgoraCDNTokenWillExpire"/> + 声网 CDN Token 即将过期时触发的回调。 + + + + + + + + +
+

+ @Deprecated @CalledByNative void onAgoraCDNTokenWillExpire(); + + - (void)onAgoraCDNTokenWillExpire NS_SWIFT_NAME(onAgoraCDNTokenWillExpire()); + virtual void onAgoraCDNTokenWillExpire() = 0; + + + + +

+
+
+
+ +
自从
+
v
+
+
+

该回调表示声网 CDN Token 即将过期。你需要调用 方法重新设置 Token。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_addvideowatermark3.dita b/dita/RTC-NG/API/api_irtcengine_addvideowatermark3.dita new file mode 100644 index 00000000000..f83c4f8bf1a --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_addvideowatermark3.dita @@ -0,0 +1,91 @@ + + + + <ph keyref="addVideoWatermark3"/> + 向本地视频中添加水印图像。 + + + + + + + + +
+

+ @Deprecated public abstract int addVideoWatermark(String watermarkUrl, WatermarkOptions options); + + - (int)addVideoWatermark:(AgoraImage * _Nonnull)watermark NS_SWIFT_NAME(addVideoWatermark(_:)) __deprecated_msg(&quot;use addVideoWatermarkWithConfig:config instead.&quot;); + virtual int addVideoWatermark(const WatermarkConfig&amp; configs) = 0; + + + + +

+
+
+
+ +
自从
+
v
+
+
+

你可以使用该方法在本地视频流中叠加水印图像,并通过 配置水印的位置、大小和在预览中的可见性。 + +该方法在直播场景中向本地视频流添加 PNG 格式的水印图像。频道中的所有观众(包括 CDN 观众)以及采集设备都可以看到并捕捉到该水印图像。 + +该方法仅支持添加一个水印图像,新添加的图像会替换之前的图像。 + +水印图像的位置取决于 方法中的设置: +

    +
  • 如果编码视频的方向模式为 ,或 中的横屏模式,则水印使用横屏方向。
  • +
  • 如果编码视频的方向模式为 ,或 中的竖屏模式,则水印使用竖屏方向。
  • +
  • 设置水印位置时,区域必须小于 方法中设置的尺寸,否则水印图像会被裁剪。
  • +
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + config + configs + 水印配置。详见 + + + watermark + 水印图像。详见 + + + url + 要添加的水印图像的本地文件路径。如果水印图像位于项目文件中,你需要在 Xcode 属性中将图像的 Type 从 PNG image 更改为 Data,否则声网 Native SDK 无法识别该图像。 + + + watermarkUrl + 要添加的水印图像的本地文件路径。支持从本地文件路径或 assets 文件路径添加水印图像。如果使用 assets 文件路径,填写该参数时需以 /assets/ 开头。 + + + options + 水印图像的相关设置。详见 + 水印图像的选项,详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_addvideowatermarkwithconfig.dita b/dita/RTC-NG/API/api_irtcengine_addvideowatermarkwithconfig.dita new file mode 100644 index 00000000000..8cedb558ac2 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_addvideowatermarkwithconfig.dita @@ -0,0 +1,61 @@ + + + + <ph keyref="addVideoWatermarkWithConfig"/> + 向本地视频添加带有水印配置的水印图像。 + + + + + + + + +
+

+ + + - (int)addVideoWatermarkWithConfig:(WatermarkConfig* _Nonnull)config NS_SWIFT_NAME(addVideoWatermark(_:)); + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

你可以使用该方法在本地视频流上叠加水印图像。通过 结构体可以配置水印的位置、大小以及在预览中的可见性。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + config + 水印图像的配置。详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_createvideoeffectobject.dita b/dita/RTC-NG/API/api_irtcengine_createvideoeffectobject.dita new file mode 100644 index 00000000000..1331afbec9f --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_createvideoeffectobject.dita @@ -0,0 +1,75 @@ + + + + <ph keyref="createVideoEffectObject"/> + 创建一个视频特效对象。 + + + + + + + + +
+

+ public abstract IVideoEffectObject createVideoEffectObject(String bundlePath, Constants.MediaSourceType sourceType); + + - (id&lt;AgoraVideoEffectObject&gt; _Nullable)createVideoEffectObjectWithBundlePath:(NSString * _Nonnull)bundlePath sourceType:(AgoraMediaSourceType)sourceType NS_SWIFT_NAME(createVideoEffectObject(bundlePath:sourceType:)); + virtual agora_refptr&lt;IVideoEffectObject&gt; createVideoEffectObject(const char* bundlePath, agora::media::MEDIA_SOURCE_TYPE type = agora::media::PRIMARY_CAMERA_SOURCE) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

创建一个 IVideoEffectObject 视频特效对象并返回其指针。

+ 调用该方法前需先调用 方法。该方法适用于 Android 4.4 或更高版本。 +
+
+ 调用限制 +

无。

+
+
+ 参数 + + + bundlePath + bundlePath + 视频特效资源包的路径。 + 视频特效 bundle 的路径。 + + + sourceType + sourceType + type + 媒体源类型,例如 。详见 + 媒体源类型,例如 。详见 + 媒体源类型,详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 方法调用成功,返回 IVideoEffectObject 对象指针。
  • +
  • 方法调用失败,返回空指针。
  • +
+

+

方法调用成功,返回 AgoraVideoEffectObject 对象。方法调用失败,返回空指针。

+

方法调用成功,返回 IVideoEffectObject 对象。 +方法调用失败,返回 null。

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_destroy.dita b/dita/RTC-NG/API/api_irtcengine_destroy.dita new file mode 100644 index 00000000000..68cb97228e8 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_destroy.dita @@ -0,0 +1,69 @@ + + + + <ph keyref="destroy"/> + 释放声网 SDK 使用的所有资源。 + + + + + + + + +
+

+ public static synchronized void destroy(@Nullable IRtcEngineReleaseCallback callback) + + + (void)destroy:(void (^ _Nullable)(void))engineReleasedBlock NS_SWIFT_NAME(destroy(_:)); + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该方法适用于偶尔进行语音通话或视频通话的应用程序,在不通话时释放资源以供其他操作使用。一旦调用该方法销毁已创建的 实例,SDK 中的其他方法将无法使用,也不会再触发任何回调。若需重新开始通信,请调用 sharedEngineWithAppId 方法重新创建实例。

+ 不要在 SDK 生成的任何回调中调用此方法,否则可能导致死锁。 +
+
+ 调用限制 +

无。

+
+
+ 参数 + + + callback + engineReleasedBlock + 可选的回调实例。用于决定该方法是否为同步调用: +
    +
  • 非 null:该方法为异步调用。即使 对象资源尚未释放,方法也会立即返回,并在引擎资源释放后触发 回调。
  • +
  • null:该方法为同步调用,方法返回时 对象资源已释放。请勿在 SDK 生成的任何回调中调用该方法,否则可能导致死锁。详见 IRtcEngineReleaseCallback
  • +
+
+ 被销毁时触发的回调 block。该参数决定该方法是同步调用还是异步调用。 +
    +
  • 非空:该方法为异步调用,即使 实例的资源尚未释放,该方法也会立即返回,并在资源释放后触发 engineReleasedBlock
  • +
  • 空:该方法为同步调用,即该方法在 实例资源释放后才返回。
  • +
+
+
+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_destroyvideoeffectobject.dita b/dita/RTC-NG/API/api_irtcengine_destroyvideoeffectobject.dita new file mode 100644 index 00000000000..8e4dd9c708e --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_destroyvideoeffectobject.dita @@ -0,0 +1,64 @@ + + + + <ph keyref="destroyVideoEffectObject"/> + 销毁一个视频特效对象。 + + + + + + + + +
+

+ public abstract int destroyVideoEffectObject(IVideoEffectObject videoEffectObject); + + - (int)destroyVideoEffectObject:(id&lt;AgoraVideoEffectObject&gt; _Nullable)videoEffectObject NS_SWIFT_NAME(destroyVideoEffectObject(_:)); + virtual int destroyVideoEffectObject(agora_refptr&lt;IVideoEffectObject&gt; videoEffectObject) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+ 调用该方法前需先调用 方法。该方法适用于 Android 4.4 或更高版本。 +
+
+ 调用限制 +

无。

+
+
+ 参数 + + + videoEffectObject + 要销毁的视频特效对象。详见 IVideoEffectObject + 要销毁的 AgoraVideoEffectObject 实例的指针。详见 AgoraVideoEffectObject + 待销毁的视频特效对象。详见 IVideoEffectObject + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_queryhdrcapability.dita b/dita/RTC-NG/API/api_irtcengine_queryhdrcapability.dita new file mode 100644 index 00000000000..ec362d69f29 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_queryhdrcapability.dita @@ -0,0 +1,62 @@ + + + + <ph keyref="queryHDRCapability"/> + 查询视频模块的 HDR 能力。 + + + + + + + + +
+

+ public abstract int queryHDRCapability(Constants.VIDEO_MODULE_TYPE moduleType); + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于查询指定视频模块的 HDR 能力。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + moduleType + 视频模块的类型。详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:不支持。
  • +
  • 1:支持。
  • +
  • < 0:未知。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_removevideowatermark.dita b/dita/RTC-NG/API/api_irtcengine_removevideowatermark.dita new file mode 100644 index 00000000000..109ad07cf12 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengine_removevideowatermark.dita @@ -0,0 +1,63 @@ + + + + <ph keyref="removeVideoWatermark"/> + 从本地视频中移除水印图像。 + + + + + + + + +
+

+ public abstract int removeVideoWatermark(String id); + + - (int)removeVideoWatermark:(NSString* _Nonnull)id NS_SWIFT_NAME(removeVideoWatermark(_:)); + virtual int removeVideoWatermark(const char* id) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该方法通过指定的唯一 ID,从本地视频流中移除之前添加的水印图像。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + id + 要移除的水印图像的 ID。 + 要移除的水印的标识符。 + 要移除的水印 ID。该值应与添加水印时使用的 ID 保持一致。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengine_renewtoken.dita b/dita/RTC-NG/API/api_irtcengine_renewtoken.dita index d73d36817ce..d3ab079745c 100644 --- a/dita/RTC-NG/API/api_irtcengine_renewtoken.dita +++ b/dita/RTC-NG/API/api_irtcengine_renewtoken.dita @@ -1,4 +1,4 @@ - + <ph keyref="renewToken"/> @@ -14,54 +14,60 @@

public abstract int renewToken(String token); - public abstract renewToken(token: string): number; - - (int)renewToken:(NSString * _Nonnull)token; + + - (int)renewToken:(NSString * _Nonnull)token NS_SWIFT_NAME(renewToken(_:)); virtual int renewToken(const char* token) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") - int RenewToken(const FString & token); - abstract renewToken(token: string): number; - public abstract int RenewToken(string token); - abstract renewToken(token: string): number; - Future<void> renewToken(String token); -

+ + + + +

-

该方法用于更新 Token。Token 会在一定时间后失效,此时 SDK 将无法和服务器建立连接。

-
-
- 调用时机 -

在以下任意一种情况下,声网推荐你在你的服务端重新生成 Token,然后调用该方法传入新的 Token: -

+

在启用并使用 Token 后,Token 会在一段时间后过期。 + +在以下情况下,请在你的服务器上生成一个新的 Token,并调用该方法进行更新。否则,SDK 将与服务器断开连接: +

+

调用限制

无。

-
+ +
参数 - - token - 新生成的 Token。 + + token + 新的 Token。
-
+
<ph keyref="return-section-title"/> -

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    -
  • 0: 方法调用成功。
  • -
  • < 0: 方法调用失败。详见了解详情和解决建议。 -
      -
    • -2:传入的参数无效。例如,Token 为空。
    • -
    • -7: 对象尚未初始化。你需要在调用该方法前成功初始化 对象。
    • -
    • -110:Token 无效。请确保: -
        -
      • 生成 Token 时指定的用户 ID 与加入频道时使用的用户 ID 一致,
      • -
      • 生成的 Token 和加入频道使用的 Token 一致。
    • -
  • -
+

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
diff --git a/dita/RTC-NG/API/api_irtcengine_setavsyncsource.dita b/dita/RTC-NG/API/api_irtcengine_setavsyncsource.dita index 37512da81b3..18a411f1714 100644 --- a/dita/RTC-NG/API/api_irtcengine_setavsyncsource.dita +++ b/dita/RTC-NG/API/api_irtcengine_setavsyncsource.dita @@ -1,52 +1,59 @@ - + - <ph keyref="setAVSyncSource" /> - 设置发流端音画同步。 + <ph keyref="setAVSyncSource"/> + 将本地用户与远端用户绑定为音视频同步组。 - +

- public abstract int setAVSyncSource(String channelId, int uid); - - - (int) setAVSyncSource:(NSString* _Nonnull)channelId uid:(NSUInteger)uid; + + + virtual int setAVSyncSource(const char* channelId, uid_t uid) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") - int SetAVSyncSource(const FString& channelId, int64 uid); - abstract setAVSyncSource(channelId: string, uid: number): number; - public abstract int SetAVSyncSource(string channelId, uint uid); - abstract setAVSyncSource(channelId: string, uid: number): number; - Future<void> setAVSyncSource({required String channelId, required int uid}); -

+ + + + +

-
- 详情 -

同一用户可能使用两个设备分别发送音频流和视频流,为保证接收端听到和看到的音频和视频的时间同步性,你可以在视频发送端调用该方法,并传入音频发送端的频道名、用户 ID。 SDK 会以发送的音频流的时间戳为基准进行自动调节发送的视频流,以保证即使在两个发送端的上行网络情况不一致(如分别使用 Wi-Fi 和 4G 网络)的情况下,也能让接收到的音视频具有时间同步性。

- 建议你在加入频道前调用该方法。
-
+
+

你可以通过该方法将本地用户与指定远端用户绑定为一个音视频同步组。远端用户由频道 ID 和用户 ID 唯一标识。使用限制:本地用户必须为视频流发送端。在接收端,同一同步组中的媒体流将进行时间同步。

+
+
+ 调用限制 +

无。

+
+
参数 - - channelId - 标识音频发送端所在频道的频道名。 + + channelId + 频道 ID。 - - uid - 音频发送端的用户 ID。 + + uid + 要与本地用户绑定的远端用户 ID。
-
+
<ph keyref="return-section-title"/> -

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    -
  • 0: 方法调用成功。
  • -
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • -
- - \ No newline at end of file +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+ + diff --git a/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingaudioconfiguration.dita b/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingaudioconfiguration.dita index 3cec0b74a6c..559e75fd6af 100644 --- a/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingaudioconfiguration.dita +++ b/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingaudioconfiguration.dita @@ -1,12 +1,12 @@ - + - <ph keyref="setDirectCdnStreamingAudioConfiguration" /> + <ph keyref="setDirectCdnStreamingAudioConfiguration"/> 设置主播端直接向 CDN 推流时的音频编码属性。 - + @@ -14,10 +14,10 @@

public abstract int setDirectCdnStreamingAudioConfiguration(int profile); - + - (int)setDirectCdnStreamingAudioConfiguration:(AgoraAudioProfile)profile; virtual int setDirectCdnStreamingAudioConfiguration(AUDIO_PROFILE_TYPE profile) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") + UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") int SetDirectCdnStreamingAudioConfiguration(EAUDIO_PROFILE_TYPE profile); abstract setDirectCdnStreamingAudioConfiguration( profile: AudioProfileType @@ -28,27 +28,34 @@ ): number; Future<void> setDirectCdnStreamingAudioConfiguration( AudioProfileType profile); -

-
-
-

该方法仅对麦克风采集或自采集的音频有效,即对在 中设置 publishMicrophoneTrackpublishCustomAudioTrack 时所采集的音频有效。

+

+
+

该方法仅对麦克风采集或自采集的音频有效,即对在 中设置 publishMicrophoneTrackpublishCustomAudioTrack 时所采集的音频有效。

+
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该方法自 v4.6.0 版本废弃。
+
+
+
参数 profile -

+

<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingvideoconfiguration.dita b/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingvideoconfiguration.dita index 897bd47451c..a5715573883 100644 --- a/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingvideoconfiguration.dita +++ b/dita/RTC-NG/API/api_irtcengine_setdirectcdnstreamingvideoconfiguration.dita @@ -1,4 +1,4 @@ - + <ph keyref="setDirectCdnStreamingVideoConfiguration"/> @@ -14,12 +14,12 @@

public abstract int setDirectCdnStreamingVideoConfiguration(VideoEncoderConfiguration config); - + - (int)setDirectCdnStreamingVideoConfiguration:(AgoraVideoEncoderConfiguration * _Nonnull)config; virtual int setDirectCdnStreamingVideoConfiguration(const VideoEncoderConfiguration& config) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") + UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") int SetDirectCdnStreamingVideoConfiguration(const FVideoEncoderConfiguration& config); abstract setDirectCdnStreamingVideoConfiguration( config: VideoEncoderConfiguration @@ -28,12 +28,20 @@ abstract setDirectCdnStreamingVideoConfiguration( config: VideoEncoderConfiguration ): number; - Future<void> setDirectCdnStreamingVideoConfiguration( + Future<void> setDirectCdnStreamingVideoConfiguration( VideoEncoderConfiguration config); -

+

详情 +
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该方法自 v4.6.0 版本废弃,请改用其他替代方案。
+
该方法自 v4.6.0 版本废弃。
+
+

该方法仅对摄像头采集、屏幕共享或自采集的视频有效。即对在 中设置 publishCameraTrackpublishCustomVideoTrack 时所采集的视频有效。

如果你设置的视频分辨率超出你的摄像头设备支持的范围,SDK 会根据你的设置进行自适应,取最接近、且长宽比与你设置的分辨率一致的值进行采集、编码、推流。你可以通过 回调了解推送的视频流的实际分辨率。

@@ -49,7 +57,7 @@
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
    diff --git a/dita/RTC-NG/API/api_irtcengine_setplaybackaudioframebeforemixingparameters.dita b/dita/RTC-NG/API/api_irtcengine_setplaybackaudioframebeforemixingparameters.dita index 420f72f7254..c67b8022eb9 100644 --- a/dita/RTC-NG/API/api_irtcengine_setplaybackaudioframebeforemixingparameters.dita +++ b/dita/RTC-NG/API/api_irtcengine_setplaybackaudioframebeforemixingparameters.dita @@ -1,67 +1,95 @@ - + - <ph keyref="setPlaybackAudioFrameBeforeMixingParameters" /> - 设置混音前的原始音频播放数据格式。 + <ph keyref="setPlaybackAudioFrameBeforeMixingParameters"/> + 设置 回调中音频数据的播放格式。 - +

    - public abstract int setPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel); - public abstract setPlaybackAudioFrameBeforeMixingParameters(sampleRate:number,channel:number):number; - - (int)setPlaybackAudioFrameBeforeMixingParametersWithSampleRate:(NSInteger)sampleRate - channel:(NSInteger)channel; - virtual int setPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|IRtcEngine") - int SetPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel); - abstract setPlaybackAudioFrameBeforeMixingParameters( - sampleRate: number, - channel: number - ): number; - public abstract int SetPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel); - abstract setPlaybackAudioFrameBeforeMixingParameters( - sampleRate: number, - channel: number - ): number; - Future<void> setPlaybackAudioFrameBeforeMixingParameters( - {required int sampleRate, required int channel}); -

    + public abstract int setPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel, int samplesPerCall); + + - (int)setPlaybackAudioFrameBeforeMixingParametersWithSampleRate:(NSInteger)sampleRate channel:(NSInteger)channel samplesPerCall:(NSInteger)samplesPerCall NS_SWIFT_NAME(setPlaybackAudioFrameBeforeMixingParametersWithSampleRate(_:channel:samplesPerCall:)); + virtual int setPlaybackAudioFrameBeforeMixingParameters(int sampleRate, int channel, int samplesPerCall) = 0; + + + + +

    -

    SDK 会根据该采样间隔触发 回调。

    +

    用于设置 回调中返回的音频数据的采样率、声道数和每次回调的采样点数。

    -
    - 调用时机 -

    该方法需要在加入频道前调用。

    -
    调用限制

    无。

    -
    +
    参数 - - - + + sampleRate + sampleRate + 设置 回调中返回的采样率(samplesPerSec)。可设置为以下值: +
      +
    • 8000。
    • +
    • 16000。
    • +
    • 32000。
    • +
    • 44100。
    • +
    • 48000(单位:Hz)。
    • +
    +
    + 输入参数,在 回调中包含的采样率(Hz)。你可以设置为 8000、16000、32000、44100 或 48000。 + 回调中返回的音频数据采样率(Hz)。可设置为 8000、16000、32000、44100 或 48000。
    - - - + + channel + channel + 设置 回调中返回的音频数据的声道数。可设置为: +
      +
    • 1:单声道。
    • +
    • 2:立体声。
    • +
    +
    + 输入参数,在 回调中包含的声道数。 +
      +
    • 1:单声道。
    • +
    • 2:立体声。
    • +
    +
    + 回调中返回的音频数据声道数。可设置为: +
      +
    • 1:单声道。
    • +
    • 2:立体声。
    • +
    +
    +
    + + samplesPerCall + samplesPerCall + 设置 回调返回的采样点数。在 RTMP 推流场景中,建议设置为 1024。 + 输入参数,在 回调中返回的数据中的采样点数。例如,对于推流场景,通常设置为 1024。 + 回调中每次返回的采样点数。例如,推流时通常设置为 1024。
    -
    +
    <ph keyref="return-section-title"/> -

    方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

    -
      -
    • 0: 方法调用成功。
    • -
    • < 0: 方法调用失败。详见了解详情和解决建议。
    • -
    +

    方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

    +
      +
    • 0: 方法调用成功。
    • +
    • < 0: 方法调用失败。详见了解详情和解决建议。
    • +
    +

      +
    • 0:方法调用成功。
    • +
    • < 0:方法调用失败。
    • +
    +

    +
    diff --git a/dita/RTC-NG/API/api_irtcengine_startdirectcdnstreaming.dita b/dita/RTC-NG/API/api_irtcengine_startdirectcdnstreaming.dita index 6b1b206cc09..839e264f746 100644 --- a/dita/RTC-NG/API/api_irtcengine_startdirectcdnstreaming.dita +++ b/dita/RTC-NG/API/api_irtcengine_startdirectcdnstreaming.dita @@ -1,12 +1,12 @@ - + - <ph keyref="startDirectCdnStreaming" /> + <ph keyref="startDirectCdnStreaming"/> 设置主播端开始直接向 CDN 推流。 - + @@ -14,11 +14,11 @@

    public abstract int startDirectCdnStreaming(IDirectCdnStreamingEventHandler eventHandler, String publishUrl, DirectCdnStreamingMediaOptions options); - + - (int)startDirectCdnStreaming:(id<AgoraDirectCdnStreamingEventDelegate> _Nonnull)delegate publishUrl:(NSString * _Nonnull)publishUrl mediaOptions:(AgoraDirectCdnStreamingMediaOptions * _Nonnull)options; virtual int startDirectCdnStreaming(IDirectCdnStreamingEventHandler* eventHandler, const char* publishUrl, const DirectCdnStreamingMediaOptions& options) = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|RtcEngineProxy") + UFUNCTION(BlueprintCallable, Category = "Agora|RtcEngineProxy") int StartDirectCdnStreaming(UIDirectCdnStreamingEventHandler* eventHandler, FString publishUrl, FDirectCdnStreamingMediaOptions& options); abstract startDirectCdnStreaming( eventHandler: IDirectCdnStreamingEventHandler, @@ -31,34 +31,40 @@ publishUrl: string, options: DirectCdnStreamingMediaOptions ): number; - Future<void> startDirectCdnStreaming( + Future<void> startDirectCdnStreaming( {required DirectCdnStreamingEventHandler eventHandler, required String publishUrl, required DirectCdnStreamingMediaOptions options}); -

    +

详情 +
+ +
弃用:
+
该方法自 v4.6.0 版本废弃。
+
+

SDK 不支持同一时间向同一个 URL 重复推流。

媒体选项说明

-

SDK 不支持 publishCameraTrackpublishCustomVideoTrack 同时为 ,也不支持 publishMicrophoneTrackpublishCustomAudioTrack 同时为 。你可以根据场景需求设置媒体选项 ()。示例如下:

+

SDK 不支持 publishCameraTrackpublishCustomVideoTrack 同时为 ,也不支持 publishMicrophoneTrackpublishCustomAudioTrack 同时为 。你可以根据场景需求设置媒体选项 ()。示例如下:

如果你想推送主播端自定义采集的音视频流,请将媒体选项进行如下设置:

    -
  • publishCustomAudioTrack 设为 并调用
  • -
  • publishCustomAudioTrack 设为 并调用
  • -
  • publishCustomVideoTrack 设为 并调用
  • -
  • 确保 publishCameraTrack (默认值)
  • -
  • 确保 publishMicrophoneTrack (默认值)
  • +
  • publishCustomAudioTrack 设为 并调用
  • +
  • publishCustomAudioTrack 设为 并调用
  • +
  • publishCustomVideoTrack 设为 并调用
  • +
  • 确保 publishCameraTrack (默认值)
  • +
  • 确保 publishMicrophoneTrack (默认值)
-

自 v4.2.0 起,SDK 支持推送纯音频流。你可以在 中将 publishCustomAudioTrack 或者 publishMicrophoneTrack 设为 ,并调用 即可推送纯音频流。 +

自 v4.2.0 起,SDK 支持推送纯音频流。你可以在 中将 publishCustomAudioTrack 或者 publishMicrophoneTrack 设为 ,并调用 即可推送纯音频流。 自 v4.2.0 起,SDK 支持推送纯音频流。你可以在 中将 publishCustomAudioTrack 或者 publishMicrophoneTrack 设为 ,并调用 即可推送纯音频流。 在向 CDN 直接推流时,SDK 目前仅支持推送一路音频流及视频流,或一路纯音频流。

参数 - - eventHandler - delegate - 详见 + + eventHandler + delegate + 详见 publishUrl @@ -66,13 +72,13 @@ options - 主播端的媒体选项。详见 + 主播端的媒体选项。详见
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
diff --git a/dita/RTC-NG/API/api_irtcengine_stopdirectcdnstreaming.dita b/dita/RTC-NG/API/api_irtcengine_stopdirectcdnstreaming.dita index a5ef6450675..9fea7511553 100644 --- a/dita/RTC-NG/API/api_irtcengine_stopdirectcdnstreaming.dita +++ b/dita/RTC-NG/API/api_irtcengine_stopdirectcdnstreaming.dita @@ -1,33 +1,44 @@ - + - <ph keyref="stopDirectCdnStreaming" /> + <ph keyref="stopDirectCdnStreaming"/> 设置主播端停止直接向 CDN 推流。 - +
public abstract int stopDirectCdnStreaming(); - + - (int)stopDirectCdnStreaming; virtual int stopDirectCdnStreaming() = 0; - UFUNCTION(BlueprintCallable, Category = "Agora|RtcEngineProxy") + UFUNCTION(BlueprintCallable, Category = "Agora|RtcEngineProxy") int StopDirectCdnStreaming(); abstract stopDirectCdnStreaming(): number; public abstract int StopDirectCdnStreaming(); abstract stopDirectCdnStreaming(): number; Future<void> stopDirectCdnStreaming();
+
+ 详情 +
+ +
弃用:
+
该 API 自 v4.6.0 版本废弃。
+
该 API 自 v4.6.0 版本废弃,请改用其他方法。
+
该方法自 v4.6.0 版本废弃。
+
+
+
<ph keyref="return-section-title"/>

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

-
    +
    • 0: 方法调用成功。
    • < 0: 方法调用失败。详见了解详情和解决建议。
-
\ No newline at end of file +
diff --git a/dita/RTC-NG/API/api_irtcengine_updatedirectcdnstreamingmediaoptions.dita b/dita/RTC-NG/API/api_irtcengine_updatedirectcdnstreamingmediaoptions.dita index 410f3e60c44..6630dece4b3 100644 --- a/dita/RTC-NG/API/api_irtcengine_updatedirectcdnstreamingmediaoptions.dita +++ b/dita/RTC-NG/API/api_irtcengine_updatedirectcdnstreamingmediaoptions.dita @@ -1,42 +1,50 @@ - + updateDirectCdnStreamingMediaOptions - + - +

- - - - - - - + + + + + + + There are no corresponding names available -

+

详情 -

+

+ +
弃用:
+
该方法自 v4.6.0 起废弃。
+
该方法自 v4.6.0 版本废弃。
+
该 API 自 v4.6.0 版本废弃。
+
+
+

参数 - - + +
返回值
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/api_irtcengineeventhandler_onmultipathstats.dita b/dita/RTC-NG/API/api_irtcengineeventhandler_onmultipathstats.dita new file mode 100644 index 00000000000..34b9af30468 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineeventhandler_onmultipathstats.dita @@ -0,0 +1,70 @@ + + + + <ph keyref="onMultipathStats"/> + 多路径传输统计信息的回调。 + + + + + + + + +
+

+ public void onMultipathStats(MultipathStats stats) {} + + - (void)rtcEngine:(AgoraRtcEngineKit * _Nonnull)engine multiPathStats:(AgoraMultipathStats * _Nonnull)stats NS_SWIFT_NAME(rtcEngine(_:multiPathStats:)); + virtual void onMultipathStats(const MultipathStats&amp; stats) + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该回调在你将 enableMultipath 设置为 以启用多路径传输后触发。

+
+
+ 调用时机 +

在你将 enableMultipath 设置为 以启用多路径传输后触发该回调。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + stats + stats + 多路径传输统计信息。详见 + 多路径传输统计数据,详见 + + + connection + 对象。详见 + + + engine + 实例。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengineeventhandler_onrenewtokenresult.dita b/dita/RTC-NG/API/api_irtcengineeventhandler_onrenewtokenresult.dita new file mode 100644 index 00000000000..79d5f6007fd --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineeventhandler_onrenewtokenresult.dita @@ -0,0 +1,71 @@ + + + + <ph keyref="onRenewTokenResult"/> + 调用结果回调。 + + + + + + + + +
+

+ public void onRenewTokenResult(String token, Constants.RenewTokenErrorCode code) {} + + - (void)rtcEngine:(AgoraRtcEngineKit * _Nonnull)engine renewTokenResult:(NSString *_Nonnull)token code:(AgoraRenewTokenErrorCode)code NS_SWIFT_NAME(rtcEngine(_:renewTokenResult:code:)); + virtual void onRenewTokenResult(const char* token, RENEW_TOKEN_ERROR_CODE code) + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该回调在用户调用 方法更新 Token 后触发,用于通知应用调用结果。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + token + 用于鉴权的 Token。 + Token。 + + + code + 错误码,详见 RenewTokenErrorCode + 错误码,详见 AgoraRenewTokenErrorCode。 + 错误码,详见 + + + connection + 连接信息。详见 RtcConnection。 + + + engine + 声网引擎对象。详见 AgoraRtcEngineKit。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengineex_addvideowatermarkex1.dita b/dita/RTC-NG/API/api_irtcengineex_addvideowatermarkex1.dita new file mode 100644 index 00000000000..452f957bab3 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineex_addvideowatermarkex1.dita @@ -0,0 +1,94 @@ + + + + <ph keyref="addVideoWatermarkEx1"/> + 向本地视频添加水印图像。 + + + + + + + + +
+

+ public abstract int addVideoWatermarkEx(String watermarkUrl, WatermarkOptions options, RtcConnection connection); + + - (int)addVideoWatermarkEx:(NSURL* _Nonnull)url options:(WatermarkOptions* _Nonnull)options connection:(AgoraRtcConnection * _Nonnull)connection NS_SWIFT_NAME(addVideoWatermarkEx(_:options:connection:)) __deprecated_msg(&quot;use addVideoWatermarkWithConfig:config connection instead.&quot;); + virtual int addVideoWatermarkEx(const WatermarkConfig&amp; config, const RtcConnection&amp; connection) = 0; + + + + +

+
+
+
+ +
自从
+
v
+
+
+

该方法在直播中向本地视频流添加 PNG 格式的水印图像。频道中的所有观众(包括 CDN 观众)以及采集设备都可以看到并捕捉到该水印图像。 + +声网仅支持在本地视频中添加一个水印图像,新添加的图像会替换之前的图像。 + +水印图像的位置取决于 方法中的设置: +

    +
  • 如果编码视频的方向模式为 ,或为 中的横屏模式,则水印使用横屏方向。
  • +
  • 如果编码视频的方向模式为 ,或为 中的竖屏模式,则水印使用竖屏方向。
  • +
  • 设置水印位置时,区域必须小于 方法中设置的尺寸,否则水印图像会被裁剪。
  • +
+

+
+
+ 适用场景 +

该方法适用于多频道场景。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + config + configs + 水印配置。详见 + 水印图像的配置。详见 + + + connection + 用于控制不同连接实例。详见 + 连接信息,包括频道 ID 和用户 ID。详见 + 对象。详见 + + + watermarkUrl + url + 要添加的水印图像的本地文件路径。支持从本地文件路径或 assets 文件路径添加水印图像。如果使用 assets 文件路径,填写该参数时需以 /assets/ 开头。 + 要添加的水印图像的本地文件路径。如果要添加的水印图像在项目文件中,需要将图像的类型从 PNG image 更改为 Xcode 属性中的 Data,否则声网 Native SDK 无法识别该图像。 + + + options + 水印图像的相关设置。详见 + 水印图像的选项,详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengineex_playeffectex.dita b/dita/RTC-NG/API/api_irtcengineex_playeffectex.dita new file mode 100644 index 00000000000..d65d8dc4c5d --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineex_playeffectex.dita @@ -0,0 +1,163 @@ + + + + <ph keyref="playEffectEx"/> + 播放指定音效文件。 + + + + + + + + +
+

+ public int playEffectEx(RtcConnection connection, int soundId, String filePath, int loopCount, double pitch, double pan, double gain, boolean publish); + + - (int)playEffectEx:(AgoraRtcConnection* _Nonnull)connection soundId:(int)soundId filePath:(NSString* _Nonnull)filePath loopCount:(NSInteger)loopCount pitch:(double)pitch pan:(double)pan gain:(NSInteger)gain startPos:(int)startPos NS_SWIFT_NAME(playEffectEx(_:soundId:filePath:loopCount:pitch:pan:gain:startPos:)); + virtual int playEffectEx(const RtcConnection&amp; connection, int soundId, const char* filePath, int loopCount, double pitch, double pan, int gain, bool publish = false, int startPos = 0) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

调用 预加载音效后,可以调用该方法将指定音效播放给频道内的所有用户。每次调用该方法只能播放一个音效。如需同时播放多个音效,请多次调用该方法。

+ 该方法适用于多频道场景。如果你通过 方法将音效文件预加载到内存中,请确保 soundId 的值与 中设置的值一致。 +
    +
  • 该方法适用于多频道场景。
  • +
  • 声网建议同时播放的音效不超过三个。
  • +
  • 此方法中的音效 ID 和文件路径必须与调用 时保持一致。
  • +
+
+
+
+ 适用场景 +

该方法适用于多频道场景。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + connection + 连接信息。详见 + 连接对象。详见 + 连接对象。详见 + + + soundId + 音效的 ID。 + 音效 ID。 + + + filePath + 本地音效文件的绝对路径或在线音效文件的 URL。支持的音频格式包括 mp3、mp4、m4a、aac、3gp、mkv 和 wav。 + 音效文件的路径。 + + + loopCount + 音效的循环播放次数: +
    +
  • -1:无限循环播放,直到调用
  • +
  • 0:播放一次。
  • +
  • 1:播放两次。
  • +
+
+ 设置音效的循环次数。 +
    +
  • 0:音效播放一次。
  • +
  • 1:音效播放两次。
  • +
  • -1:音效无限循环,直到你调用 方法停止播放。
  • +
+
+
+ + pitch + 音效的音调。取值范围为 0.5 到 2.0,默认值为 1.0(原始音调)。值越小,音调越低。 + 设置音效的音调。取值范围为 0.5 到 2,默认值为 1(不变调)。值越小,音调越低。 + + + pan + 音效的空间位置。取值范围为 -1.0 到 1.0: +
    +
  • -1.0:音效出现在左侧。
  • +
  • 0.0:音效出现在正前方。
  • +
  • 1.0:音效出现在右侧。
  • +
+
+ 设置音效的空间位置。取值范围为 -1.0 到 1.0。 +
    +
  • 0.0:音效位于前方。
  • +
  • 1.0:音效位于右侧。
  • +
  • -1.0:音效位于左侧。
  • +
+
+ 音效的空间位置。取值范围为 -1.0 到 1.0: +
    +
  • -1.0:定位在左侧。
  • +
  • 0.0:定位在正前方。
  • +
  • 1.0:定位在右侧。
  • +
+
+
+ + gain + 音效的音量。取值范围为 0.0 到 100.0,默认值为 100(原始音量)。值越小,音量越低。 + 设置音效的音量。取值范围为 0 到 100,默认值为 100。值越小,音量越低。 + 音效的音量。取值范围为 0 到 100,默认值为 100(原始音量)。值越小,音量越低。 + + + publish + publish + 是否在频道中发布该音效: +
    +
  • :在频道中发布音效,远端用户可以听到。
  • +
  • :不在频道中发布音效。
  • +
+
+ 是否在频道中发布该音效: +
    +
  • :在频道中发布音效,远端用户可以听到。
  • +
  • :不在频道中发布音效。
  • +
+
+ 是否在频道中发布该音效: +
    +
  • :在频道中发布,远端用户可以听到。
  • +
  • :(默认)不在频道中发布。
  • +
+
+
+ + startPos + 音效文件的播放起始位置,单位为毫秒。 + 音效文件的播放起始位置(单位为毫秒)。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengineex_preloadeffectex.dita b/dita/RTC-NG/API/api_irtcengineex_preloadeffectex.dita new file mode 100644 index 00000000000..8df7f0614a1 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineex_preloadeffectex.dita @@ -0,0 +1,94 @@ + + + + <ph keyref="preloadEffectEx"/> + 预加载指定音效到指定频道。 + + + + + + + + +
+

+ public int preloadEffectEx(RtcConnection connection, int soundId, String filePath); + + - (int)preloadEffectEx:(AgoraRtcConnection* _Nonnull)connection soundId:(int)soundId filePath:(NSString* _Nonnull)filePath NS_SWIFT_NAME(preloadEffectEx(_:soundId:filePath:)); + virtual int preloadEffectEx(const RtcConnection&amp; connection, int soundId, const char* filePath, int startPos = 0) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该方法每次调用仅将一个指定音效预加载到内存中。若需预加载多个音效,请多次调用该方法。 + +预加载完成后,你可以调用 播放已预加载的音效,或调用 播放所有已预加载的音效。

+
    +
  • 该方法适用于多频道场景。
  • +
  • 为确保通信流畅,请限制音效文件的大小。
  • +
  • 声网建议在加入频道前调用该方法。
  • +
+
+
    +
  • 该方法适用于多频道场景。
  • +
  • 为确保通信顺畅,请限制音效文件的大小。
  • +
  • 声网建议你在加入频道前调用该方法。
  • +
+
+
+
+ 适用场景 +

该方法适用于多频道场景。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + connection + 连接信息。详见 + 连接对象。详见 + 对象。详见 + + + soundId + 音效的 ID。 + + + filePath + 本地音效文件的绝对路径或在线音效文件的 URL。支持的音频格式包括:mp3、mp4、m4a、aac、3gp、mkv 和 wav。 + + + startPos + 音效文件的播放起始位置(单位为毫秒)。 + 音效文件的播放起始位置(毫秒)。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcengineex_removevideowatermarkex.dita b/dita/RTC-NG/API/api_irtcengineex_removevideowatermarkex.dita new file mode 100644 index 00000000000..ad6b8656ce0 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcengineex_removevideowatermarkex.dita @@ -0,0 +1,73 @@ + + + + <ph keyref="removeVideoWatermarkEx"/> + 从本地或远端视频流中移除指定的水印图像。 + + + + + + + + +
+

+ public abstract int removeVideoWatermarkEx(String id, RtcConnection connection); + + - (int)removeVideoWatermarkEx:(NSString* _Nonnull)id connection:(AgoraRtcConnection * _Nonnull)connection NS_SWIFT_NAME(removeVideoWatermarkEx(_:connection:)); + virtual int removeVideoWatermarkEx(const char* id, const RtcConnection&amp; connection) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该方法适用于多频道场景。

+
+
+ 适用场景 +

该方法适用于多频道场景。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + id + 要移除的水印图像的 ID。 + 要移除的水印的标识符。 + 水印 ID。 + + + connection + 用于控制不同连接实例的参数。详见 + 连接信息,包括频道 ID 和用户 ID。详见 + 对象。详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_irtcenginereleasecallback_onenginereleased.dita b/dita/RTC-NG/API/api_irtcenginereleasecallback_onenginereleased.dita new file mode 100644 index 00000000000..ad9820aad16 --- /dev/null +++ b/dita/RTC-NG/API/api_irtcenginereleasecallback_onenginereleased.dita @@ -0,0 +1,46 @@ + + + + <ph keyref="onEngineReleased"/> + 被释放时触发的回调。 + + + + + + + + +
+

+ @CalledByNative void onEngineReleased(); + + + + + + + +

+
+
+

该回调在调用 方法以异步释放 对象时被触发。

+
+
+ 调用时机 +

该回调在调用 方法以异步释放 对象时被触发。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectboolparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectboolparam.dita new file mode 100644 index 00000000000..53f46369c5f --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectboolparam.dita @@ -0,0 +1,78 @@ + + + + <ph keyref="getVideoEffectBoolParam"/> + 获取视频特效中的布尔参数。 + + + + + + + + +
+

+ boolean getVideoEffectBoolParam(String option, String key); + + - (BOOL)getVideoEffectBoolParamWithOption:(NSString *)option key:(NSString *)key NS_SWIFT_NAME(getVideoEffectBoolParam(option:key:)); + virtual bool getVideoEffectBoolParam(const char* option, const char* key) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + 参数类别的标识符。 + 参数的类别标识符。 + 参数所属的选项类别。 + + + key + 参数的键名。 + 参数的键值。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • :参数已启用。
  • +
  • :参数未启用或不存在。
  • +
+

+

    +
  • :参数已启用。
  • +
  • :参数未启用或不存在。
  • +
+

+

    +
  • :获取参数成功。
  • +
  • :获取参数失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectfloatparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectfloatparam.dita new file mode 100644 index 00000000000..5217482a606 --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectfloatparam.dita @@ -0,0 +1,78 @@ + + + + <ph keyref="getVideoEffectFloatParam"/> + 获取视频特效中的 float 类型参数。 + + + + + + + + +
+

+ float getVideoEffectFloatParam(String option, String key); + + - (float)getVideoEffectFloatParamWithOption:(NSString *)option key:(NSString *)key NS_SWIFT_NAME(getVideoEffectFloatParam(option:key:)); + virtual float getVideoEffectFloatParam(const char* option, const char* key) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取视频特效中指定选项和键名对应的 float 类型参数值。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + option + 参数类别的标识符。 + 参数选项的类别。 + 参数所属的选项类别。 + + + key + 参数的键名。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 参数存在时,返回对应的 float 类型值。
  • +
  • 参数不存在或发生错误时,返回 0.0f。
  • +
+

+

    +
  • 参数存在时,返回对应的浮点型参数值。
  • +
  • 参数不存在或发生错误时,返回 0.0f。
  • +
+

+

    +
  • 方法调用成功,返回当前参数值。
  • +
  • 方法调用失败,返回 0.0f。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectintparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectintparam.dita new file mode 100644 index 00000000000..468795eb5c3 --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_getvideoeffectintparam.dita @@ -0,0 +1,80 @@ + + + + <ph keyref="getVideoEffectIntParam"/> + 获取视频特效中的整数参数。 + + + + + + + + +
+

+ int getVideoEffectIntParam(String option, String key); + + - (int)getVideoEffectIntParamWithOption:(NSString *)option key:(NSString *)key NS_SWIFT_NAME(getVideoEffectIntParam(option:key:)); + virtual int getVideoEffectIntParam(const char* option, const char* key) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取视频特效中的整数类型参数。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + option + 参数类别的标识符。 + 参数的类别标识符。 + 参数的选项类别。 + + + key + key + 参数的键名。 + 参数的键值。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 参数存在时,返回对应的整数值。
  • +
  • 参数不存在或发生错误时,返回 0。
  • +
+

+

    +
  • 方法调用成功,返回对应参数的整数值。
  • +
  • 方法调用失败或参数不存在时,返回 0。
  • +
+

+

    +
  • 方法调用成功,返回当前参数值。
  • +
  • 方法调用失败,返回 0。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_performvideoeffectaction.dita b/dita/RTC-NG/API/api_ivideoeffectobject_performvideoeffectaction.dita new file mode 100644 index 00000000000..81fccd98448 --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_performvideoeffectaction.dita @@ -0,0 +1,69 @@ + + + + <ph keyref="performVideoEffectAction"/> + 对指定的视频特效节点执行操作。 + + + + + + + + +
+

+ int performVideoEffectAction(int nodeId, VIDEO_EFFECT_ACTION actionId); + + - (int)performVideoEffectActionWithNodeId:(NSUInteger)nodeId actionId:(AgoraVideoEffectAction)actionId NS_SWIFT_NAME(performVideoEffectAction(nodeId:actionId:)); + virtual int performVideoEffectAction(uint32_t nodeId, VIDEO_EFFECT_ACTION actionId) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + nodeId + nodeId + 视频特效节点的唯一标识符。 + + + actionId + actionId + 要在视频特效节点上执行的操作,详见 + 要在视频特效上执行的操作。详见 AgoraVideoEffectAction + 要执行的操作,详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_removevideoeffect.dita b/dita/RTC-NG/API/api_ivideoeffectobject_removevideoeffect.dita new file mode 100644 index 00000000000..b50406c3fff --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_removevideoeffect.dita @@ -0,0 +1,64 @@ + + + + <ph keyref="removeVideoEffect"/> + 移除指定节点 ID 的视频特效。 + + + + + + + + +
+

+ int removeVideoEffect(int nodeId); + + - (int)removeVideoEffectWithNodeId:(NSUInteger)nodeId + virtual int removeVideoEffect(uint32_t nodeId) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + nodeId + nodeId + 要移除的视频特效节点的唯一标识符。 + 要移除的视频特效节点的唯一标识符,详见 AgoraVideoEffectNodeId + 要移除的视频特效节点的唯一标识符,详见 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectboolparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectboolparam.dita new file mode 100644 index 00000000000..2e73c7653da --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectboolparam.dita @@ -0,0 +1,90 @@ + + + + <ph keyref="setVideoEffectBoolParam"/> + 设置视频特效的布尔参数。 + + + + + + + + +
+

+ int setVideoEffectBoolParam(String option, String key, boolean value); + + - (int)setVideoEffectBoolParamWithOption:(NSString *)option key:(NSString *)key boolValue:(BOOL)boolValue NS_SWIFT_NAME(setVideoEffectBoolParam(option:key:boolValue:)); + virtual int setVideoEffectBoolParam(const char* option, const char* key, bool param) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + option + 参数类别的标识符。 + 参数选项的类别。 + 参数所属的选项类别。 + + + key + 参数的键名。 + + + param + 要设置的布尔值。 +
    +
  • :启用该选项。
  • +
  • :禁用该选项。
  • +
+
+
+ + boolValue + 要设置的布尔值。 +
    +
  • :设置为开启状态。
  • +
  • :设置为关闭状态。
  • +
+
+
+ + value + 要设置的布尔值。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectfloatparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectfloatparam.dita new file mode 100644 index 00000000000..92a94981534 --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectfloatparam.dita @@ -0,0 +1,80 @@ + + + + <ph keyref="setVideoEffectFloatParam"/> + 设置视频特效的浮点参数。 + + + + + + + + +
+

+ int setVideoEffectFloatParam(String option, String key, float value); + + - (int)setVideoEffectFloatParamWithOption:(NSString *)option key:(NSString *)key floatValue:(float)floatValue NS_SWIFT_NAME(setVideoEffectFloatParam(option:key:floatValue:)); + virtual int setVideoEffectFloatParam(const char* option, const char* key, float param) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + option + 参数类别的标识符。 + 参数选项的类别。 + 参数的选项类别。 + + + key + 参数的键名。 + + + param + 要设置的浮点值。 + + + floatValue + 要设置的浮点值。 + + + value + 要设置的浮点型参数值。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectintparam.dita b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectintparam.dita new file mode 100644 index 00000000000..842b019f8a9 --- /dev/null +++ b/dita/RTC-NG/API/api_ivideoeffectobject_setvideoeffectintparam.dita @@ -0,0 +1,80 @@ + + + + <ph keyref="setVideoEffectIntParam"/> + 设置视频特效的整数参数。 + + + + + + + + +
+

+ int setVideoEffectIntParam(String option, String key, int value); + + - (int)setVideoEffectIntParamWithOption:(NSString *)option key:(NSString *)key intValue:(int)intValue NS_SWIFT_NAME(setVideoEffectIntParam(option:key:intValue:)); + virtual int setVideoEffectIntParam(const char* option, const char* key, int param) = 0; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + option + option + 参数类别的标识符。 + 参数选项的类别。 + 参数所属的选项类别。 + + + key + 参数的键名。 + + + param + 要设置的整数参数值。 + + + intValue + 要设置的整数值。 + + + value + 要设置的整数值。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • 0:方法调用成功。
  • +
  • < 0:方法调用失败。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkbuffer_getbuffer.dita b/dita/RTC-NG/API/api_watermarkbuffer_getbuffer.dita new file mode 100644 index 00000000000..1f181f6d536 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkbuffer_getbuffer.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getBuffer"/> + 获取水印图像的缓冲区。 + + + + + + + + +
+

+ public ByteBuffer getBuffer() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

该方法用于获取水印图像的缓冲区或水印图像数据缓冲区。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功时,返回包含水印图像数据的 ByteBuffer 对象。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkbuffer_getformat.dita b/dita/RTC-NG/API/api_watermarkbuffer_getformat.dita new file mode 100644 index 00000000000..6f72a2e0702 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkbuffer_getformat.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getFormat"/> + 获取水印图像的格式。 + + + + + + + + +
+

+ public int getFormat() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取水印图像的格式。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回水印图像缓冲区的格式。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkbuffer_getheight.dita b/dita/RTC-NG/API/api_watermarkbuffer_getheight.dita new file mode 100644 index 00000000000..797877e78b3 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkbuffer_getheight.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getHeight"/> + 获取水印图像的高度。 + + + + + + + + +
+

+ public int getHeight() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取水印图像的高度。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回水印图像的高度,单位为像素。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkbuffer_getid.dita b/dita/RTC-NG/API/api_watermarkbuffer_getid.dita new file mode 100644 index 00000000000..8fc79e7b929 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkbuffer_getid.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getId"/> + 获取水印的唯一 ID。 + + + + + + + + +
+

+ public String getId() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于从 实例中获取水印的唯一标识符。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功时,返回水印的唯一 ID。方法调用失败时,返回空字符串。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkbuffer_getwidth.dita b/dita/RTC-NG/API/api_watermarkbuffer_getwidth.dita new file mode 100644 index 00000000000..4b64cd996f3 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkbuffer_getwidth.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getWidth"/> + 获取水印图像的宽度。 + + + + + + + + +
+

+ public int getWidth() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取水印图像的宽度。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回水印图像的宽度,单位为像素。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkconfig_getimageurl.dita b/dita/RTC-NG/API/api_watermarkconfig_getimageurl.dita new file mode 100644 index 00000000000..defe6e0a99b --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkconfig_getimageurl.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getImageUrl"/> + 获取水印图像的 URL。 + + + + + + + + +
+

+ public String getImageUrl() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功时,返回水印图像的 URL。方法调用失败时,返回空字符串。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkconfig_getoptions.dita b/dita/RTC-NG/API/api_watermarkconfig_getoptions.dita new file mode 100644 index 00000000000..98923004df5 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkconfig_getoptions.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getOptions"/> + 获取水印显示选项。 + + + + + + + + +
+

+ public WatermarkOptions getOptions() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取当前配置的水印显示选项。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回 对象。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkconfig_gettype.dita b/dita/RTC-NG/API/api_watermarkconfig_gettype.dita new file mode 100644 index 00000000000..daa58c8e27d --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkconfig_gettype.dita @@ -0,0 +1,54 @@ + + + + <ph keyref="getType"/> + 获取水印的类型。 + + + + + + + + +
+

+ public int getType() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取当前水印配置中的类型信息。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回水印类型。 +

    +
  • WATERMARK_TYPE_IMAGE:图片类型水印。
  • +
  • WATERMARK_TYPE_BUFFER:缓冲区类型水印。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkoptions_getpositioninlandscapemode.dita b/dita/RTC-NG/API/api_watermarkoptions_getpositioninlandscapemode.dita new file mode 100644 index 00000000000..ea4eccf34ee --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkoptions_getpositioninlandscapemode.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getPositionInLandscapeMode"/> + 获取横屏模式下水印的位置。 + + + + + + + + +
+

+ public int[] getPositionInLandscapeMode() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

获取横屏模式下水印的位置。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回一个包含四个元素的整数数组,表示水印矩形的 x、y、宽度和高度。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkoptions_getpositioninportraitmode.dita b/dita/RTC-NG/API/api_watermarkoptions_getpositioninportraitmode.dita new file mode 100644 index 00000000000..8786665a127 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkoptions_getpositioninportraitmode.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getPositionInPortraitMode"/> + 获取竖屏模式下水印的位置。 + + + + + + + + +
+

+ public int[] getPositionInPortraitMode() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

获取竖屏模式下水印的位置。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回一个包含四个元素的整数数组,表示水印矩形的 x、y、宽度和高度。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkoptions_getzorder.dita b/dita/RTC-NG/API/api_watermarkoptions_getzorder.dita new file mode 100644 index 00000000000..5c32ce29a47 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkoptions_getzorder.dita @@ -0,0 +1,49 @@ + + + + <ph keyref="getzOrder"/> + 获取水印图像的 Z 轴顺序索引。 + + + + + + + + +
+

+ public int getzOrder() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于获取水印图像在 Z 轴上的绘制顺序索引。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

方法调用成功,返回水印图像的 Z 轴顺序索引。

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkoptions_isvisibleinpreview.dita b/dita/RTC-NG/API/api_watermarkoptions_isvisibleinpreview.dita new file mode 100644 index 00000000000..1ccc862c978 --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkoptions_isvisibleinpreview.dita @@ -0,0 +1,53 @@ + + + + <ph keyref="isVisibleInPreview"/> + 检查水印在本地视频预览中是否可见。 + + + + + + + + +
+

+ public boolean isVisibleInPreview() + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

检查水印在本地视频预览中是否可见。

+
+
+ 调用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+

    +
  • :水印在本地视频预览中可见。
  • +
  • :水印在本地视频预览中不可见。
  • +
+

+
+
+
diff --git a/dita/RTC-NG/API/api_watermarkoptions_zorder.dita b/dita/RTC-NG/API/api_watermarkoptions_zorder.dita new file mode 100644 index 00000000000..e00b644913a --- /dev/null +++ b/dita/RTC-NG/API/api_watermarkoptions_zorder.dita @@ -0,0 +1,56 @@ + + + + <ph keyref="zOrder"/> + 水印图像在视频中相对于其他叠加层的堆叠顺序。 + + + + + + + + +
+

+ public int zOrder = 0; + + + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

水印图像在视频中相对于其他叠加层的堆叠顺序。

+
+
+ 调用限制 +

无。

+
+
+ 参数 + + + zOrder + 水印图像在视频中相对于其他叠加层的堆叠顺序。 + +
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。详见了解详情和解决建议。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
+
+
diff --git a/dita/RTC-NG/API/callback_imediaplayersourceobserver_onagoracdntokenwillexpire.dita b/dita/RTC-NG/API/callback_imediaplayersourceobserver_onagoracdntokenwillexpire.dita index 36b33df2ffd..fe5bced3ba6 100644 --- a/dita/RTC-NG/API/callback_imediaplayersourceobserver_onagoracdntokenwillexpire.dita +++ b/dita/RTC-NG/API/callback_imediaplayersourceobserver_onagoracdntokenwillexpire.dita @@ -1,33 +1,49 @@ - + - <ph keyref="onAgoraCDNTokenWillExpire" /> - 提示鉴权信息即将过期。 + <ph keyref="onAgoraCDNTokenWillExpire"/> + 声网 CDN Token 即将过期时触发的回调。 - +

- void onAgoraCDNTokenWillExpire(); - - - - (void)onAgoraCDNTokenWillExpire; - - virtual void onAgoraCDNTokenWillExpire() = 0; - - onAgoraCDNTokenWillExpire?(): void; - public virtual void OnAgoraCDNTokenWillExpire() {} - onAgoraCDNTokenWillExpire?(): void; - final void Function()? onAgoraCDNTokenWillExpire; -

+ @Deprecated @CalledByNative void onAgoraCDNTokenWillExpire(); + + - (void)onAgoraCDNTokenWillExpire NS_SWIFT_NAME(onAgoraCDNTokenWillExpire()); + virtual void onAgoraCDNTokenWillExpire() = 0; + + + + + +

-
-

当你调用 切换媒体资源的时候,如果 ts 过期,该回调会被触发,提示你更新鉴权信息。你需要调用 传入新的鉴权信息,以更新该媒体资源网络路径的鉴权信息。更新鉴权信息后,你还需要调用 才能完成线路切换。

+
+
+ +
自从
+
v
+
+
+

该回调表示声网 CDN Token 即将过期。你需要调用 方法重新设置 Token。

+
+ 使用限制 +

无。

+
+
+ <ph keyref="return-section-title"/> +

方法成功调用时,无返回值;方法调用失败时,会抛出 异常,你需要捕获异常并进行处理。

+
    +
  • 0: 方法调用成功。
  • +
  • < 0: 方法调用失败。详见了解详情和解决建议。
  • +
+
- \ No newline at end of file + diff --git a/dita/RTC-NG/API/class_cameracapturerconfiguration.dita b/dita/RTC-NG/API/class_cameracapturerconfiguration.dita index d9c1edaefcf..441d514b91a 100644 --- a/dita/RTC-NG/API/class_cameracapturerconfiguration.dita +++ b/dita/RTC-NG/API/class_cameracapturerconfiguration.dita @@ -1,8 +1,8 @@ - + <ph keyref="CameraCapturerConfiguration"/> - 摄像头采集配置。 + 配置摄像头采集参数。

@@ -18,7 +18,7 @@ value = v; } - @CalledByNative("CAMERA_DIRECTION") + @CalledByNative(&quot;CAMERA_DIRECTION&quot;) public int getValue() { return this.value; } @@ -36,7 +36,7 @@ value = v; } - @CalledByNative("CAMERA_FOCAL_LENGTH_TYPE") + @CalledByNative(&quot;CAMERA_FOCAL_LENGTH_TYPE&quot;) public int getValue() { return this.value; } @@ -65,25 +65,25 @@ this.fps = 15; } - @CalledByNative("CaptureFormat") + @CalledByNative(&quot;CaptureFormat&quot;) public int getHeight() { return height; } - @CalledByNative("CaptureFormat") + @CalledByNative(&quot;CaptureFormat&quot;) public int getWidth() { return width; } - @CalledByNative("CaptureFormat") + @CalledByNative(&quot;CaptureFormat&quot;) public int getFps() { return fps; } @Override public String toString() { - return "CaptureFormat{" - + "width=" + width + ", height=" + height + ", fps=" + fps + '}'; + return &quot;CaptureFormat{&quot; + + &quot;width=&quot; + width + &quot;, height=&quot; + height + &quot;, fps=&quot; + fps + '}'; } } @@ -147,10 +147,10 @@ @Override public String toString() { - return "CameraCapturerConfiguration{" - + "cameraDirection=" + cameraDirection + ", captureDimensions=" + captureFormat - + ", cameraId=" + cameraId + ", followEncodeDimensionRatio=" + followEncodeDimensionRatio - + ", cameraFocalLengthType=" + cameraFocalLengthType + '}'; + return &quot;CameraCapturerConfiguration{&quot; + + &quot;cameraDirection=&quot; + cameraDirection + &quot;, captureDimensions=&quot; + captureFormat + + &quot;, cameraId=&quot; + cameraId + &quot;, followEncodeDimensionRatio=&quot; + followEncodeDimensionRatio + + &quot;, cameraFocalLengthType=&quot; + cameraFocalLengthType + '}'; } } export class CameraCapturerConfiguration { @@ -158,7 +158,7 @@ public cameraFormat: CaptureFormat = new CaptureFormat(); public followEncodeDimensionRatio: boolean = true; } - __attribute__((visibility("default"))) @interface AgoraCameraCapturerConfiguration: NSObject + __attribute__((visibility(&quot;default&quot;))) @interface AgoraCameraCapturerConfiguration: NSObject #if TARGET_OS_IOS @property (assign, nonatomic) AgoraCameraDirection cameraDirection; @property(assign, nonatomic) AgoraFocalLength cameraFocalLengthType; @@ -174,18 +174,11 @@ @end struct CameraCapturerConfiguration { -#if defined(__ANDROID__) || (defined(__APPLE__) && TARGET_OS_IOS) - Optional<CAMERA_DIRECTION> cameraDirection; - - Optional<CAMERA_FOCAL_LENGTH_TYPE> cameraFocalLengthType; -#else - Optional<const char *> deviceId; -#endif - -#if defined(__ANDROID__) - Optional<const char *> cameraId; -#endif - Optional<bool> followEncodeDimensionRatio; + Optional&lt;CAMERA_DIRECTION&gt; cameraDirection; + Optional&lt;CAMERA_FOCAL_LENGTH_TYPE&gt; cameraFocalLengthType; + Optional&lt;const char *&gt; deviceId; + Optional&lt;const char *&gt; cameraId; + Optional&lt;bool&gt; followEncodeDimensionRatio; VideoFormat format; CameraCapturerConfiguration() : format(VideoFormat(0, 0, 0)) {} }; @@ -194,31 +187,31 @@ struct FCameraCapturerConfiguration { GENERATED_BODY() public: - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) ECAMERA_DIRECTION cameraDirection = ECAMERA_DIRECTION::CAMERA_FRONT; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) ECAMERA_FOCAL_LENGTH_TYPE cameraFocalLengthType = ECAMERA_FOCAL_LENGTH_TYPE::CAMERA_FOCAL_LENGTH_DEFAULT; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) bool deviceId_SetValue = false; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") - FString deviceId = ""; + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) + FString deviceId = &quot;&quot;; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) bool cameraId_SetValue = false; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") - FString cameraId = ""; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|CameraCapturerConfiguration") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) + FString cameraId = &quot;&quot;; + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|CameraCapturerConfiguration&quot;) FVideoFormat format = FVideoFormat(); - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|ChannelMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|ChannelMediaOptions&quot;) EAgoraOptional followEncodeDimensionRatio = EAgoraOptional::AGORA_NULL_VALUE; FCameraCapturerConfiguration(){} - FCameraCapturerConfiguration(const agora::rtc::CameraCapturerConfiguration & AgoraData){ -#if defined(__ANDROID__) || (defined(__APPLE__) && TARGET_OS_IOS) - cameraDirection = static_cast<ECAMERA_DIRECTION>(AgoraData.cameraDirection.value()); - cameraFocalLengthType = static_cast<ECAMERA_FOCAL_LENGTH_TYPE>(AgoraData.cameraFocalLengthType.value()); + FCameraCapturerConfiguration(const agora::rtc::CameraCapturerConfiguration &amp; AgoraData){ +#if defined(__ANDROID__) || (defined(__APPLE__) &amp;&amp; TARGET_OS_IOS) + cameraDirection = static_cast&lt;ECAMERA_DIRECTION&gt;(AgoraData.cameraDirection.value()); + cameraFocalLengthType = static_cast&lt;ECAMERA_FOCAL_LENGTH_TYPE&gt;(AgoraData.cameraFocalLengthType.value()); #else - SET_UEBP_OPTIONAL_VAL_FString(this->deviceId, AgoraData.deviceId); + SET_UEBP_OPTIONAL_VAL_FString(this-&gt;deviceId, AgoraData.deviceId); #endif #if defined(__ANDROID__) cameraId = UTF8_TO_TCHAR(AgoraData.cameraId.value()); @@ -228,25 +221,25 @@ public: } agora::rtc::CameraCapturerConfiguration CreateAgoraData() const { agora::rtc::CameraCapturerConfiguration AgoraData; -#if defined(__ANDROID__) || (defined(__APPLE__) && TARGET_OS_IOS) - AgoraData.cameraDirection = static_cast<agora::rtc::CAMERA_DIRECTION>(cameraDirection); - AgoraData.cameraFocalLengthType = static_cast<agora::rtc::CAMERA_FOCAL_LENGTH_TYPE>(cameraFocalLengthType); +#if defined(__ANDROID__) || (defined(__APPLE__) &amp;&amp; TARGET_OS_IOS) + AgoraData.cameraDirection = static_cast&lt;agora::rtc::CAMERA_DIRECTION&gt;(cameraDirection); + AgoraData.cameraFocalLengthType = static_cast&lt;agora::rtc::CAMERA_FOCAL_LENGTH_TYPE&gt;(cameraFocalLengthType); #else - SET_AGORA_OPTIONAL_VAL_CHARPTR______MEMOALLOC(AgoraData.deviceId, this->deviceId) + SET_AGORA_OPTIONAL_VAL_CHARPTR______MEMOALLOC(AgoraData.deviceId, this-&gt;deviceId) #endif #if defined(__ANDROID__) SET_AGORA_OPTIONAL_VAL_CHARPTR______MEMOALLOC( - AgoraData.cameraId,this->cameraId) + AgoraData.cameraId,this-&gt;cameraId) #endif AgoraData.format = format.CreateAgoraData(); - SET_AGORA_OPTIONAL_VAL_BOOL(AgoraData.followEncodeDimensionRatio, this->followEncodeDimensionRatio) + SET_AGORA_OPTIONAL_VAL_BOOL(AgoraData.followEncodeDimensionRatio, this-&gt;followEncodeDimensionRatio) return AgoraData; } - void FreeAgoraData(agora::rtc::CameraCapturerConfiguration& AgoraData) const { + void FreeAgoraData(agora::rtc::CameraCapturerConfiguration&amp; AgoraData) const { format.FreeAgoraData(AgoraData.format); -#if defined(__ANDROID__) || (defined(__APPLE__) && TARGET_OS_IOS) +#if defined(__ANDROID__) || (defined(__APPLE__) &amp;&amp; TARGET_OS_IOS) #else SET_AGORA_OPTIONAL_VAL_CHARPTR______MEMOFREE(AgoraData.deviceId) #endif @@ -266,11 +259,11 @@ public: } public class CameraCapturerConfiguration : IOptionalJsonParse { - public Optional<CAMERA_DIRECTION> cameraDirection = new Optional<CAMERA_DIRECTION>(); - public Optional<CAMERA_FOCAL_LENGTH_TYPE> cameraFocalLengthType = new Optional<CAMERA_FOCAL_LENGTH_TYPE>(); - public Optional<string> deviceId = new Optional<string>(); - public Optional<string> cameraId = new Optional<string>(); - public Optional<bool> followEncodeDimensionRatio = new Optional<bool>(); + public Optional&lt;CAMERA_DIRECTION&gt; cameraDirection = new Optional&lt;CAMERA_DIRECTION&gt;(); + public Optional&lt;CAMERA_FOCAL_LENGTH_TYPE&gt; cameraFocalLengthType = new Optional&lt;CAMERA_FOCAL_LENGTH_TYPE&gt;(); + public Optional&lt;string&gt; deviceId = new Optional&lt;string&gt;(); + public Optional&lt;string&gt; cameraId = new Optional&lt;string&gt;(); + public Optional&lt;bool&gt; followEncodeDimensionRatio = new Optional&lt;bool&gt;(); public VideoFormat format; public CameraCapturerConfiguration() @@ -278,7 +271,7 @@ public: this.format = new VideoFormat(0, 0, 0); } - public CameraCapturerConfiguration(Optional<CAMERA_DIRECTION> cameraDirection, Optional<CAMERA_FOCAL_LENGTH_TYPE> cameraFocalLengthType, Optional<string> deviceId, Optional<string> cameraId, Optional<bool> followEncodeDimensionRatio, VideoFormat format) + public CameraCapturerConfiguration(Optional&lt;CAMERA_DIRECTION&gt; cameraDirection, Optional&lt;CAMERA_FOCAL_LENGTH_TYPE&gt; cameraFocalLengthType, Optional&lt;string&gt; deviceId, Optional&lt;string&gt; cameraId, Optional&lt;bool&gt; followEncodeDimensionRatio, VideoFormat format) { this.cameraDirection = cameraDirection; this.cameraFocalLengthType = cameraFocalLengthType; @@ -331,72 +324,80 @@ class CameraCapturerConfiguration { @JsonKey(name: 'format') final VideoFormat? format; - factory CameraCapturerConfiguration.fromJson(Map<String, dynamic> json) => + factory CameraCapturerConfiguration.fromJson(Map&lt;String, dynamic&gt; json) =&gt; _$CameraCapturerConfigurationFromJson(json); - Map<String, dynamic> toJson() => _$CameraCapturerConfigurationToJson(this); + Map&lt;String, dynamic&gt; toJson() =&gt; _$CameraCapturerConfigurationToJson(this); } -

-
+

+
<text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> - - cameraDirection - (可选)摄像头方向。详见 。 - 该参数仅适用于 Android 和 iOS 平台。 - - - cameraId - (可选)摄像头 ID。默认为前置摄像头对应的摄像头 ID。你可以通过 Android 原生系统 API 获取摄像头 ID,详见 。 + + cameraDirection + (可选)摄像头方向。详见 。 + 该参数仅适用于 Android 和 iOS 平台。 + + + cameraId + (可选)摄像头 ID。默认为前置摄像头对应的摄像头 ID。你可以通过 Android 原生系统 API 获取摄像头 ID,详见
    -
  • 该参数仅适用于 Android。
  • +
  • 该参数仅适用于 Android。
  • 该参数和 cameraDirection 均用于指定摄像头,二者为互斥关系,你可以按需选用其中之一,具体区别如下:
    • 通过 cameraDirection 指定摄像头的方式更为简便。你只需指定摄像头的方向(前置或后置),无需指定具体的摄像头 ID,SDK 会通过系统 API 去检索和确定实际的摄像头 ID。
    • 通过 cameraId 则可以更精确地指定某个特定的摄像头。对于多摄像头的设备,cameraDirection 无法识别或访问全部可用摄像头,这种情况建议使用 cameraId 直接指定你想要的摄像头 ID。
-
- - cameraFocalLengthType - (可选)摄像头的焦距类型。详见 。 + + + cameraFocalLengthType + (可选)摄像头的焦距类型。详见
    -
  • 该参数仅适用于 Android 和 iOS。
  • -
  • 如需设置摄像头的焦距类型,仅支持通过 cameraDirection 指定摄像头,不支持通过 cameraId 进行指定。
  • -
  • 部分 iOS 设备的后置摄像头为多个摄像头组成的融合镜头,如双摄(广角和超广角)或三摄(广角、超广角和长焦),对于这种具备超广角能力的融合镜头,你可以通过以下任意一种方式实现超广角的采集效果: +
  • 该参数仅适用于 Android 和 iOS。
  • +
  • 如需设置摄像头的焦距类型,仅支持通过 cameraDirection 指定摄像头,不支持通过 cameraId 进行指定。
  • +
  • 部分 iOS 设备的后置摄像头为多个摄像头组成的融合镜头,如双摄(广角和超广角)或三摄(广角、超广角和长焦),对于这种具备超广角能力的融合镜头,你可以通过以下任意一种方式实现超广角的采集效果:
    • 方式一:将该参数设置为 (2)(超广角镜头)。
    • 方式二:将该参数设置为 (0)(标准镜头),然后调用 将相机缩放比例设置为小于 1.0 的数值,最小可以设置为 0.5。
    区别为方式一的超广角大小不可调节,方式二支持自由调节相机的缩放比例。
-
- - format - captureFormat - (可选)视频帧格式。详见 - - - dimension - (可选)视频帧的分辨率 (px)。默认值为 960 × 540。 - - - frameRate - (可选)视频帧的帧率 (fps)。默认值为 15。 - - - deviceId - (可选)摄像头的 ID。最大长度为 - 该参数仅适用于 Windows 和 macOS。 - - - followEncodeDimensionRatio - (可选)是否跟随 中设置的视频宽高比: + 摄像头焦距类型,详见 。 +
    +
  • :对于 iOS,如果 iPhone 或 iPad 拥有三摄或双摄后置摄像头,表示三摄(广角 + 超广角 + 长焦)或双摄(广角 + 超广角)的组合。在这种情况下,可以通过设置较小的缩放因子申请超广角镜头,设置较大的缩放因子申请长焦镜头。否则,默认表示广角前/后摄像头。
  • +
  • :广角摄像头。
  • +
  • :超广角摄像头。
  • +
  • :长焦摄像头。
  • +
+
+
+ + format + captureFormat + (可选)视频帧格式。详见 + + + dimension + (可选)视频帧的分辨率 (px)。默认值为 960 × 540。 + + + frameRate + (可选)视频帧的帧率 (fps)。默认值为 15。 + + + deviceId + (可选)摄像头的 ID。最大长度为 + 该参数仅适用于 Windows 和 macOS。 + + + followEncodeDimensionRatio + (可选)是否跟随 中设置的视频宽高比:
    -
  • :(默认) 跟随。SDK 会将采集到的视频按照已设置的视频宽高比进行裁剪,会同步改变本地预览画面、 中的视频画面
  • +
  • :(默认) 跟随。SDK 会将采集到的视频按照已设置的视频宽高比进行裁剪,会同步改变本地预览画面、 中的视频画面
  • :不跟随。SDK不改变采集到的视频帧宽高比。
-
-
+ +
diff --git a/dita/RTC-NG/API/class_contentinspectmodule.dita b/dita/RTC-NG/API/class_contentinspectmodule.dita index a79c6ff18fd..dfd8fb162a1 100644 --- a/dita/RTC-NG/API/class_contentinspectmodule.dita +++ b/dita/RTC-NG/API/class_contentinspectmodule.dita @@ -1,8 +1,8 @@ - + <ph keyref="ContentInspectModule"/> - 结构体,用于配置本地截图上传的频率。 + 配置本地截图上传模块。

@@ -19,39 +19,41 @@ public interval:number = 0; } - __attribute__((visibility("default"))) @interface AgoraContentInspectModule: NSObject + __attribute__((visibility(&quot;default&quot;))) @interface AgoraContentInspectModule: NSObject @property (assign, nonatomic) AgoraContentInspectType type; - @property (assign, nonatomic) NSInteger interval; +@property (assign, nonatomic) AgoraVideoModulePosition position; @end struct ContentInspectModule { CONTENT_INSPECT_TYPE type; unsigned int interval; + base::VIDEO_MODULE_POSITION position; ContentInspectModule() { type = CONTENT_INSPECT_INVALID; interval = 0; + position = base::POSITION_PRE_ENCODER; } }; USTRUCT(BlueprintType) struct FContentInspectModule { GENERATED_BODY() public: - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|ContentInspectModule") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|ContentInspectModule&quot;) ECONTENT_INSPECT_TYPE type = ECONTENT_INSPECT_TYPE::CONTENT_INSPECT_INVALID; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|ContentInspectModule") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = &quot;Agora|ContentInspectModule&quot;) int64 interval = 0; FContentInspectModule(){} - FContentInspectModule(const agora::media::ContentInspectModule & AgoraData){ - type = static_cast<ECONTENT_INSPECT_TYPE>(AgoraData.type); + FContentInspectModule(const agora::media::ContentInspectModule &amp; AgoraData){ + type = static_cast&lt;ECONTENT_INSPECT_TYPE&gt;(AgoraData.type); interval = AgoraData.interval; } agora::media::ContentInspectModule CreateAgoraData() const { agora::media::ContentInspectModule AgoraData; - AgoraData.type = static_cast<agora::media::CONTENT_INSPECT_TYPE>(type); + AgoraData.type = static_cast&lt;agora::media::CONTENT_INSPECT_TYPE&gt;(type); AgoraData.interval = interval; return AgoraData; } - void FreeAgoraData(agora::media::ContentInspectModule & AgoraData) const { + void FreeAgoraData(agora::media::ContentInspectModule &amp; AgoraData) const { } }; export class ContentInspectModule { @@ -84,19 +86,19 @@ public: final ContentInspectType? type; @JsonKey(name: 'interval') final int? interval; - factory ContentInspectModule.fromJson(Map<String, dynamic> json) => + factory ContentInspectModule.fromJson(Map&lt;String, dynamic&gt; json) =&gt; _$ContentInspectModuleFromJson(json); - Map<String, dynamic> toJson() => _$ContentInspectModuleToJson(this); + Map&lt;String, dynamic&gt; toJson() =&gt; _$ContentInspectModuleToJson(this); } -

+

-
+
<text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> type - 功能模块的类型。详见 + 功能模块的类型。详见

功能模块的类型:

    @@ -111,6 +113,11 @@ public: interval 本地截图上传的间隔,单位为秒,取值必须大于 0。默认值为 0,表示不进行截图上传。视频内容审核的间隔,单位为秒,取值必须大于 0。默认值为 0,表示不进行内容审核。推荐值为 10 秒,你也可以根据业务需求自行调整。 + + position + 视频观测的位置。详见 + 视频模块的位置。详见 +
diff --git a/dita/RTC-NG/API/class_directcdnstreamingmediaoptions.dita b/dita/RTC-NG/API/class_directcdnstreamingmediaoptions.dita index 17ed95e8f44..f207799c4cc 100644 --- a/dita/RTC-NG/API/class_directcdnstreamingmediaoptions.dita +++ b/dita/RTC-NG/API/class_directcdnstreamingmediaoptions.dita @@ -1,4 +1,4 @@ - + <ph keyref="DirectCdnStreamingMediaOptions"/> @@ -20,7 +20,7 @@ publishCustomVideoTrack = false; } } - + __attribute__((visibility("default"))) @interface AgoraDirectCdnStreamingMediaOptions : NSObject @property(assign, nonatomic) BOOL publishCameraTrack; @@ -48,23 +48,23 @@ struct FDirectCdnStreamingMediaOptions { GENERATED_BODY() - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") AGORAOPTIONAL publishCameraTrack; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") AGORAOPTIONAL publishMicrophoneTrack; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") AGORAOPTIONAL publishCustomAudioTrack; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") AGORAOPTIONAL publishCustomVideoTrack; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") AGORAOPTIONAL publishMediaPlayerAudioTrack; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") bool publishMediaPlayerId_SetValue; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") int publishMediaPlayerId; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") bool customVideoTrackId_SetValue; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingMediaOptions") int64 customVideoTrackId; }; export class DirectCdnStreamingMediaOptions { @@ -126,13 +126,24 @@ struct FDirectCdnStreamingMediaOptions @JsonKey(name: 'customVideoTrackId') final int? customVideoTrackId; - factory DirectCdnStreamingMediaOptions.fromJson(Map<String, dynamic> json) => + factory DirectCdnStreamingMediaOptions.fromJson(Map<String, dynamic> json) => _$DirectCdnStreamingMediaOptionsFromJson(json); - Map<String, dynamic> toJson() => _$DirectCdnStreamingMediaOptionsToJson(this); + Map<String, dynamic> toJson() => _$DirectCdnStreamingMediaOptionsToJson(this); } -

+

+
+ 详情 +
+ +
弃用:
+
该结构体自 v4.6.0 版本废弃。
+
该类自 v4.6.0 版本废弃。
+
该类自 v4.6.0 版本废弃,请改用其他替代方案。
+
+
+
<text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> diff --git a/dita/RTC-NG/API/class_directcdnstreamingstats.dita b/dita/RTC-NG/API/class_directcdnstreamingstats.dita index 13e54800df0..05e6f6dc399 100644 --- a/dita/RTC-NG/API/class_directcdnstreamingstats.dita +++ b/dita/RTC-NG/API/class_directcdnstreamingstats.dita @@ -1,7 +1,7 @@ - + - <ph keyref="DirectCdnStreamingStats" /> + <ph keyref="DirectCdnStreamingStats"/> 当前 CDN 推流的统计数据。
@@ -21,7 +21,7 @@ audioBitrate = 0; } } - + __attribute__((visibility("default"))) @interface AgoraDirectCdnStreamingStats : NSObject @property(assign, nonatomic) NSUInteger videoWidth; @property(assign, nonatomic) NSUInteger videoHeight; @@ -40,15 +40,15 @@ struct FDirectCdnStreamingStats { GENERATED_BODY() public: - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") int videoWidth = 0; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") int videoHeight = 0; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") int fps = 0; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") int videoBitrate = 0; - UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") + UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Agora|DirectCdnStreamingStats") int audioBitrate = 0; FDirectCdnStreamingStats(){} FDirectCdnStreamingStats(const agora::rtc::DirectCdnStreamingStats & AgoraData){ @@ -115,15 +115,26 @@ public: @JsonKey(name: 'audioBitrate') final int? audioBitrate; - factory DirectCdnStreamingStats.fromJson(Map<String, dynamic> json) => + factory DirectCdnStreamingStats.fromJson(Map<String, dynamic> json) => _$DirectCdnStreamingStatsFromJson(json); - Map<String, dynamic> toJson() => _$DirectCdnStreamingStatsToJson(this); + Map<String, dynamic> toJson() => _$DirectCdnStreamingStatsToJson(this); } -

+

+
+ 详情 +
+ +
弃用:
+
该结构体自 v4.6.0 版本废弃。
+
该类自 v4.6.0 版本废弃,请改用其他替代方案。
+
该类自 v4.6.0 版本废弃。
+
+
+
- <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property" /> + <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> videoWidth @@ -147,4 +158,4 @@ public:
-
\ No newline at end of file + diff --git a/dita/RTC-NG/API/class_multipathstats.dita b/dita/RTC-NG/API/class_multipathstats.dita new file mode 100644 index 00000000000..52a05898140 --- /dev/null +++ b/dita/RTC-NG/API/class_multipathstats.dita @@ -0,0 +1,102 @@ + + + + <ph keyref="MultipathStats"/> + 汇总多路径传输中所有网络路径的统计信息。 + +
+

+ + + __attribute__((visibility(&quot;default&quot;))) @interface AgoraMultipathStats : NSObject +@property (assign, nonatomic) NSUInteger lanRxBytes; +@property (assign, nonatomic) NSUInteger lanTxBytes; +@property (assign, nonatomic) NSUInteger wifiRxBytes; +@property (assign, nonatomic) NSUInteger wifiTxBytes; +@property (assign, nonatomic) NSUInteger mobileRxBytes; +@property (assign, nonatomic) NSUInteger mobileTxBytes; +@property (assign, nonatomic) NSUInteger activePathNum; +@property (copy, nonatomic) NSArray&lt;AgoraPathStats *&gt; *_Nullable pathStats NS_SWIFT_NAME(pathStats); +@end + struct MultipathStats { + uint32_t lanTxBytes; + uint32_t lanRxBytes; + uint32_t wifiTxBytes; + uint32_t wifiRxBytes; + uint32_t mobileTxBytes; + uint32_t mobileRxBytes; + int activePathNum; + const PathStats* pathStats; + MultipathStats() + : lanTxBytes(0), + lanRxBytes(0), + wifiTxBytes(0), + wifiRxBytes(0), + mobileTxBytes(0), + mobileRxBytes(0), + activePathNum(0), + pathStats(nullptr) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + lanTxBytes + 通过 LAN 网络发送的总字节数。 + 通过 LAN 路径发送的字节数。 + + + lanRxBytes + 通过 LAN 网络接收的总字节数。 + 通过 LAN 路径接收的字节数。 + + + wifiTxBytes + 通过 Wi-Fi 网络发送的总字节数。 + 通过 Wi-Fi 路径发送的字节数。 + + + wifiRxBytes + 通过 Wi-Fi 网络接收的总字节数。 + 通过 Wi-Fi 路径接收的字节数。 + + + mobileTxBytes + 通过移动蜂窝网络发送的总字节数。 + 通过移动网络路径发送的字节数。 + + + mobileRxBytes + 通过移动蜂窝网络接收的总字节数。 + 通过移动网络路径接收的字节数。 + + + activePathNum + 当前活动的路径数量。 + 当前活跃路径的数量。 + 活动路径的数量。 + + + pathStats + 路径统计信息数组,详见 + 路径的统计信息。详见 + 每个活动路径的统计信息数组。详见 + +
+
+
diff --git a/dita/RTC-NG/API/class_pathstats.dita b/dita/RTC-NG/API/class_pathstats.dita new file mode 100644 index 00000000000..ba74e221077 --- /dev/null +++ b/dita/RTC-NG/API/class_pathstats.dita @@ -0,0 +1,68 @@ + + + + <ph keyref="PathStats"/> + 用于描述多路径传输中某一特定网络路径的统计信息。 + +
+

+ + + __attribute__((visibility(&quot;default&quot;))) @interface AgoraPathStats : NSObject +@property (assign, nonatomic) AgoraMultipathType pathType; +@property (assign, nonatomic) NSUInteger txKBitRate; +@property (assign, nonatomic) NSUInteger rxKBitRate; +@end + struct PathStats { + MultipathType type; + int txKBitRate; + int rxKBitRate; + PathStats() : type(Unknown), txKBitRate(0), rxKBitRate(0) {} + PathStats(MultipathType t, int tx, int rx) : type(t), txKBitRate(tx), rxKBitRate(rx) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + type + 路径的类型。详见 + + + pathType + 路径类型,例如: +
    +
  • LAN:局域网。
  • +
  • WiFi:无线局域网。
  • +
  • Mobile:移动网络。
  • +
+
+ 路径类型。详见 AgoraMultipathType +
+ + txKBitRate + 该路径的发送码率,单位为 Kbps。 + 路径的传输码率,单位为 Kbps。 + + + rxKBitRate + 该路径的接收码率,单位为 Kbps。 + 路径的接收码率,单位为 Kbps。 + +
+
+
diff --git a/dita/RTC-NG/API/class_streamlayerconfig.dita b/dita/RTC-NG/API/class_streamlayerconfig.dita new file mode 100644 index 00000000000..859fd59d3b1 --- /dev/null +++ b/dita/RTC-NG/API/class_streamlayerconfig.dita @@ -0,0 +1,92 @@ + + + + <ph keyref="StreamLayerConfig"/> + 配置多质量层级视频流中某一层的参数。 + +
+

+ public class StreamLayerConfig { + public VideoEncoderConfiguration.VideoDimensions dimensions; + public int framerate; + public boolean enable; + public StreamLayerConfig() { + this.dimensions = new VideoEncoderConfiguration.VideoDimensions(0, 0); + this.framerate = 0; + this.enable = false; + } + public StreamLayerConfig(VideoEncoderConfiguration.VideoDimensions dimensions, int framerate, boolean enable) { + this.dimensions = dimensions; + this.framerate = framerate; + this.enable = enable; + } + @CalledByNative(&quot;StreamLayerConfig&quot;) + public int getFramerate() { + return framerate; + } + @CalledByNative(&quot;StreamLayerConfig&quot;) + public int getDimensionsWidth() { + return dimensions.width; + } + @CalledByNative(&quot;StreamLayerConfig&quot;) + public int getDimensionsHeight() { + return dimensions.height; + } + @CalledByNative(&quot;StreamLayerConfig&quot;) + public boolean isEnabled() { + return enable; + } +} + + __attribute__((visibility(&quot;default&quot;))) @interface AgoraStreamLayerConfig: NSObject +@property (assign, nonatomic) CGSize dimensions; +@property (assign, nonatomic) int framerate; +@property (assign, nonatomic) BOOL enable; +@end + + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

用于配置多质量层级视频流中某一层的参数,包括视频尺寸、帧率以及是否启用该层视频流。

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + dimensions + 视频帧的尺寸。默认值为 0。详见 VideoEncoderConfiguration.VideoDimensions + 视频帧的尺寸。默认值为 0。 + + + framerate + 本地视频采集的帧率(fps)。默认值为 0。 + 本地视频的采集帧率(fps)。默认值为 0。 + + + enable + 是否启用该分层视频流。 +
    +
  • :启用该分层视频流。
  • +
  • :(默认)不启用该分层视频流。
  • +
+
+ 是否启用对应层级的视频流。 +
    +
  • :启用对应层级的视频流。
  • +
  • :(默认)禁用对应层级的视频流。
  • +
+
+
+
+
+
diff --git a/dita/RTC-NG/API/class_watermarkbuffer.dita b/dita/RTC-NG/API/class_watermarkbuffer.dita new file mode 100644 index 00000000000..b641eebd779 --- /dev/null +++ b/dita/RTC-NG/API/class_watermarkbuffer.dita @@ -0,0 +1,71 @@ + + + + <ph keyref="WatermarkBuffer"/> + 用于定义水印图像的缓冲数据。 + +
+

+ + + __attribute__((visibility(&quot;default&quot;))) @interface WatermarkBuffer : NSObject +@property(assign, nonatomic) int width; +@property(assign, nonatomic) int height; +@property(assign, nonatomic) int length; +@property(strong, nonatomic) NSData* _Nullable buffer; +@property(assign, nonatomic) WatermarkBufferFormat format; +@end + struct WatermarkBuffer { + int width; + int height; + int length; + media::base::VIDEO_PIXEL_FORMAT format; + const uint8_t* buffer; + WatermarkBuffer() : buffer(NULL), width(0), height(0), length(0), format(media::base::VIDEO_PIXEL_I420) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + width + 水印图像的宽度,单位为像素。 + 水印缓冲区的宽度。 + + + height + 水印图像的高度,单位为像素。 + 水印缓冲区的高度。 + + + length + 缓冲区的长度,单位为字节。 + 水印缓冲区的长度。 + + + format + 水印缓冲区的格式。详见 + 水印缓冲区的格式,详见 。默认值为 。当前支持的格式包括: + + + buffer + 原始图像数据缓冲区。详见 NSData + 水印的缓冲区数据。 + +
+
+
diff --git a/dita/RTC-NG/API/class_watermarkconfig.dita b/dita/RTC-NG/API/class_watermarkconfig.dita new file mode 100644 index 00000000000..d8d5b124719 --- /dev/null +++ b/dita/RTC-NG/API/class_watermarkconfig.dita @@ -0,0 +1,109 @@ + + + + <ph keyref="WatermarkConfig"/> + 用于配置水印的相关信息。 + +
+

+ public class WatermarkConfig { + public static final int WATERMARK_TYPE_IMAGE = 0; + public static final int WATERMARK_TYPE_BUFFER = 1; + public String id; + public int type; + public WatermarkBuffer buffer = new WatermarkBuffer(); + public String imageUrl; + public WatermarkOptions options = new WatermarkOptions(); +} + + __attribute__((visibility(&quot;default&quot;))) @interface WatermarkConfig : NSObject +@property(copy, nonatomic) NSString* _Nonnull id; +@property(assign, nonatomic) WatermarkType type; +@property(strong, nonatomic) WatermarkBuffer* _Nullable buffer; +@property(strong, nonatomic) NSURL *_Nullable imageUrl; +@property(strong, nonatomic) WatermarkOptions* _Nonnull options; +@end + struct WatermarkConfig { + const char* id; + WATERMARK_SOURCE_TYPE type; + union { + WatermarkBuffer buffer; + WatermarkTimestamp timestamp; + WatermarkLiteral literal; + const char* imageUrl; + }; + WatermarkOptions options; + WatermarkConfig() : id(NULL), type(IMAGE), imageUrl(NULL) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + id + 水印的唯一标识符,通常使用 UUID 生成。 + 水印的唯一标识符。 + 水印的唯一标识符,建议使用 UUID。 + + + type + 水印的类型: +
    +
  • WATERMARK_TYPE_IMAGE:图像类型。
  • +
  • WATERMARK_TYPE_BUFFER:Buffer 类型。
  • +
+
+ 水印类型,详见 WatermarkType + 水印的类型,详见 +
+ + buffer + 包含水印图像数据的缓冲区。详见 + 水印图像的缓冲数据,详见 + 水印的缓冲区。详见 + + + imageUrl + 用于加载水印图像的 URL 地址。 + 水印图像的 URL。 + 水印图像文件的 URL,默认值为 NULL。 + + + options + 定义水印位置和大小的选项。详见 + 水印的显示选项,详见 + 水印的选项。详见 + + + timestamp + 水印的时间戳。详见 + + + literal + 水印的文字。详见 + + + WATERMARK_TYPE_IMAGE + 指定水印类型为图像。 + + + WATERMARK_TYPE_BUFFER + 指定水印类型为缓冲区。 + +
+
+
diff --git a/dita/RTC-NG/API/class_watermarkliteral.dita b/dita/RTC-NG/API/class_watermarkliteral.dita new file mode 100644 index 00000000000..df22a9814d5 --- /dev/null +++ b/dita/RTC-NG/API/class_watermarkliteral.dita @@ -0,0 +1,55 @@ + + + + <ph keyref="WatermarkLiteral"/> + 用于设置水印文字的属性。 + +
+

+ + + + struct WatermarkLiteral { + int fontSize; + int strokeWidth; + const char* wmLiteral; + const char* fontFilePath; + WatermarkLiteral() : wmLiteral(NULL), fontFilePath(NULL), fontSize(10), strokeWidth(1) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + fontSize + 文字的字体大小。默认值为 10。 + + + strokeWidth + 文字的描边宽度。默认值为 1。 + + + wmLiteral + 水印的文字内容。默认值为 NULL。 + + + fontFilePath + 字体文件的路径。默认值为 NULL。字体文件应为 .ttf 格式。 + +
+
+
diff --git a/dita/RTC-NG/API/class_watermarktimestamp.dita b/dita/RTC-NG/API/class_watermarktimestamp.dita new file mode 100644 index 00000000000..a204a2342e8 --- /dev/null +++ b/dita/RTC-NG/API/class_watermarktimestamp.dita @@ -0,0 +1,55 @@ + + + + <ph keyref="WatermarkTimestamp"/> + 用于设置时间戳水印的字体大小、字体路径、描边宽度和时间格式。 + +
+

+ + + + struct WatermarkTimestamp { + int fontSize; + const char* fontFilePath; + int strokeWidth; + const char* format; + WatermarkTimestamp() : fontSize(10), fontFilePath(NULL), strokeWidth(1), format(NULL) {} +}; + + + + +

+
+
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+

+
+
+ <text conref="../conref/conref_api_metadata.dita#conref_api_metadata/property"/> + + + fontSize + 时间戳的字体大小。默认值为 10。 + + + fontFilePath + 时间戳字体文件的路径。字体文件应为 .ttf 文件。如果未设置,SDK 会使用系统默认字体(如果可用)。 + + + strokeWidth + 时间戳的描边宽度。默认值为 1。 + + + format + 时间戳的格式。默认值为 '%F %X'。该格式遵循标准 C 库函数 strftime 的格式说明,详见 strftime + +
+
+
diff --git a/dita/RTC-NG/API/enum_directcdnstreamingreason.dita b/dita/RTC-NG/API/enum_directcdnstreamingreason.dita index 78dd7b7b4f0..63d55c991b5 100644 --- a/dita/RTC-NG/API/enum_directcdnstreamingreason.dita +++ b/dita/RTC-NG/API/enum_directcdnstreamingreason.dita @@ -1,36 +1,44 @@ - + - <ph keyref="DIRECT_CDN_STREAMING_REASON"/> - CDN 推流状态改变的原因。 + <ph keyref="DirectCdnStreamingReason"/> + CDN 推流原因码。 +
+
+ +
自从
+
v
+
+
+
枚举值 - - - 0:推流状态正常。 + + + (0):推流成功。 - - - 1:一般性错误,没有明确原因。你可以尝试重新推流。 + + + (1):推流失败。 - - - 2:音频推流出错。例如,本地音频采集设备未正常工作、被其他进程占用或没有使用权限。 + + + (2):因音频发布触发推流。 - - - 3:视频推流出错。例如,本地视频采集设备未正常工作、被其他进程占用或没有使用权限。 + + + (3):因视频发布触发推流。 - - - 4:连接 CDN 失败。 + + + (4):因网络连接触发推流。 - - - 5:URL 已用于推流。请使用新的 URL。 + + + (5):推流失败,通常由于已存在相同的流名称。 -
-
+
+
diff --git a/dita/RTC-NG/API/enum_directcdnstreamingstate.dita b/dita/RTC-NG/API/enum_directcdnstreamingstate.dita index 99433b5da0d..89ba9405797 100644 --- a/dita/RTC-NG/API/enum_directcdnstreamingstate.dita +++ b/dita/RTC-NG/API/enum_directcdnstreamingstate.dita @@ -1,32 +1,40 @@ - + - <ph keyref="DIRECT_CDN_STREAMING_STATE"/> - 当前 CDN 推流状态。 + <ph keyref="DirectCdnStreamingState"/> + CDN 推流状态。 +
+
+ +
自从
+
v
+
+
+
枚举值 - - - 0:初始状态,即推流尚未开始。 + + + (0):空闲状态。 - - - 1:正在推流中。当你调用 成功推流时,SDK 会返回该值。 + + + (1):推流中。 - - - 2:推流已正常结束。当你调用 主动停止推流时,SDK 会返回该值。 + + + (2):推流已停止。 - - - 3:推流失败。你可以通过 回调报告的信息排查问题,然后重新推流。 + + + (3):推流失败。 - - - 4:尝试重新连接声网服务器和 CDN。最多尝试重连 10 次,如仍未成功恢复连接,则推流状态变为 + + + (4):推流恢复中。 -
-
+ +
diff --git a/dita/RTC-NG/API/enum_multipathmode.dita b/dita/RTC-NG/API/enum_multipathmode.dita new file mode 100644 index 00000000000..37f2e909dd0 --- /dev/null +++ b/dita/RTC-NG/API/enum_multipathmode.dita @@ -0,0 +1,32 @@ + + + + <ph keyref="MultipathMode"/> + 数据在多个网络路径上的传输方式。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (0):将相同的数据冗余发送至所有可用路径。 + (0):冗余发送模式,数据同时通过多个路径发送。 + (0):冗余发送模式,数据同时通过多条路径发送,提升传输的冗余性和可靠性。 + + + + 数据仅通过内部算法判定为传输质量最优的路径进行发送。 + (1):动态发送模式,SDK 动态选择最佳路径进行数据传输。 + (1):动态发送模式,SDK 根据当前网络状况动态选择最佳路径进行数据传输,提升传输性能。 + + +
+
diff --git a/dita/RTC-NG/API/enum_multipathtype.dita b/dita/RTC-NG/API/enum_multipathtype.dita new file mode 100644 index 00000000000..8ce825f6576 --- /dev/null +++ b/dita/RTC-NG/API/enum_multipathtype.dita @@ -0,0 +1,44 @@ + + + + <ph keyref="MultipathType"/> + 多路径传输中使用的网络路径类型。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (0):局域网(LAN)路径。 + (0):LAN 类型,表示数据通过局域网传输。 + (0):局域网类型,表示数据通过局域网传输。适用于高速、低延迟的连接。 + + + + (1):Wi-Fi 路径。 + (1):WIFI 类型,表示数据通过 Wi-Fi 网络传输。 + (1):Wi-Fi 类型,表示数据通过 Wi-Fi 网络传输。适用于延迟适中的无线连接。 + + + + (2):移动网络路径。 + (2):Mobile 类型,表示数据通过移动网络传输。 + (2):移动网络类型,表示数据通过移动网络传输。适用于延迟较高且连接不稳定的场景。 + + + + (99):未知或未指定的网络路径。 + (99):未知类型,表示无法识别的网络路径类型。 + (99):未知类型,表示无法识别的路径类型。可用于错误处理或回退场景。 + + +
+
diff --git a/dita/RTC-NG/API/enum_renewtokenerrorcode.dita b/dita/RTC-NG/API/enum_renewtokenerrorcode.dita new file mode 100644 index 00000000000..b7c5d1f7a56 --- /dev/null +++ b/dita/RTC-NG/API/enum_renewtokenerrorcode.dita @@ -0,0 +1,56 @@ + + + + <ph keyref="RENEW_TOKEN_ERROR_CODE"/> + 表示调用 后的错误码。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (0):Token 更新成功。 + + + + (1):Token 更新失败。建议用户生成新的 Token 并重新调用 + (1):Token 更新失败。建议用户生成新的 Token 并重试 + + + + (2):Token 更新失败,原因是提供的 Token 已过期。建议用户生成一个过期时间更长的新 Token 并重新调用 + (2):Token 更新失败,原因是提供的 Token 已过期。建议用户生成一个过期时间更长的新 Token 并重试 + + + + (3):Token 更新失败,原因是提供的 Token 无效。建议用户检查 Token 的生成流程,生成新的 Token 并重新调用 + (3):Token 更新失败,原因是传入的 Token 无效。建议用户检查 Token 的生成流程,生成新的 Token 并重试 + (3):Token 更新失败,原因是提供的 Token 无效。建议用户检查 Token 的生成过程,生成新的 Token 并重试 + + + + (4):Token 更新失败,原因是 Token 中的频道名与当前频道不一致。建议用户检查频道名,生成新的 Token 并重新调用 + (4):Token 更新失败,原因是 Token 中的频道名与当前频道不一致。建议用户检查频道名,生成新的 Token 并重试 + + + + (5):Token 更新失败,原因是 Token 中的 App ID 与当前 App ID 不一致。建议用户检查 App ID,生成新的 Token 并重新调用 + (5):Token 更新失败,原因是 Token 中的 App ID 与当前 App ID 不一致。建议用户检查 App ID,生成新的 Token 并重试 + + + + (6):Token 更新请求因发起了新的请求而被取消。 + (6):Token 更新请求被取消,原因是发起了新的请求。 + (6):Token 更新被取消,原因是发起了新的请求,前一个请求被取消。 + + +
+
diff --git a/dita/RTC-NG/API/enum_screencolortype.dita b/dita/RTC-NG/API/enum_screencolortype.dita new file mode 100644 index 00000000000..6f2049c3bcf --- /dev/null +++ b/dita/RTC-NG/API/enum_screencolortype.dita @@ -0,0 +1,29 @@ + + + + <ph keyref="SCREEN_COLOR_TYPE"/> + 屏幕颜色类型。 + +
+
+
+ 枚举值 + + + + (0):自动选择屏幕颜色。 + (0):自动选择屏幕颜色类型。 + + + + (1):绿色屏幕。 + (1):使用绿色作为屏幕颜色类型。 + + + + (2):蓝色屏幕。 + (2):使用蓝色作为屏幕颜色类型。 + + +
+
diff --git a/dita/RTC-NG/API/enum_videoeffectaction.dita b/dita/RTC-NG/API/enum_videoeffectaction.dita new file mode 100644 index 00000000000..20db7010c90 --- /dev/null +++ b/dita/RTC-NG/API/enum_videoeffectaction.dita @@ -0,0 +1,31 @@ + + + + <ph keyref="VIDEO_EFFECT_ACTION"/> + 可对视频特效节点执行的操作。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (1):保存当前视频特效的参数。 + (1):保存当前视频特效节点的参数。 + + + + (2):将视频特效重置为默认参数。 + (2):重置视频特效为默认参数。 + (2):将视频特效节点重置为默认参数。 + + +
+
diff --git a/dita/RTC-NG/API/enum_videoeffectnodeid.dita b/dita/RTC-NG/API/enum_videoeffectnodeid.dita new file mode 100644 index 00000000000..c1b2960b2c7 --- /dev/null +++ b/dita/RTC-NG/API/enum_videoeffectnodeid.dita @@ -0,0 +1,32 @@ + + + + <ph keyref="VIDEO_EFFECT_NODE_ID"/> + 可应用的视频特效节点类型。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (1):美颜特效节点。 + + + + (2):风格妆特效节点。 + + + + (4):滤镜特效节点。 + + +
+
diff --git a/dita/RTC-NG/API/enum_videomoduletype.dita b/dita/RTC-NG/API/enum_videomoduletype.dita new file mode 100644 index 00000000000..d1eb410cd1f --- /dev/null +++ b/dita/RTC-NG/API/enum_videomoduletype.dita @@ -0,0 +1,38 @@ + + + + <ph keyref="VIDEO_MODULE_TYPE"/> + 用于定义视频模块类型。 + +
+
+
+ 枚举值 + + + + (0):视频采集模块。 + + + + (1):视频软件编码模块。 + + + + (2):视频硬件编码模块。 + + + + (3):视频软件解码模块。 + + + + (4):视频硬件解码模块。 + + + + (5):视频渲染模块。 + + +
+
diff --git a/dita/RTC-NG/API/enum_watermarkbufferformat.dita b/dita/RTC-NG/API/enum_watermarkbufferformat.dita new file mode 100644 index 00000000000..e23534706b9 --- /dev/null +++ b/dita/RTC-NG/API/enum_watermarkbufferformat.dita @@ -0,0 +1,36 @@ + + + + <ph keyref="WatermarkBufferFormat"/> + 水印缓冲区的数据格式。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (1):水印缓冲区使用 I420 格式。 + + + + (2):水印缓冲区使用 BGRA 格式。 + + + + (3):水印缓冲区使用 NV21 格式。 + + + + (4):水印缓冲区使用 RGBA 格式。 + + +
+
diff --git a/dita/RTC-NG/API/enum_watermarksourcetype.dita b/dita/RTC-NG/API/enum_watermarksourcetype.dita new file mode 100644 index 00000000000..0abf8fe4d3c --- /dev/null +++ b/dita/RTC-NG/API/enum_watermarksourcetype.dita @@ -0,0 +1,36 @@ + + + + <ph keyref="WATERMARK_SOURCE_TYPE"/> + 水印源的类型。 + +
+
+ +
自从:
+
自 v4.6.0 版本新增。
+
+
+
+
+ 枚举值 + + + + (0):水印源为图像。 + + + + (1):水印源为缓冲区。 + + + + (2):水印源为文本。 + + + + (3):水印源为时间戳。 + + +
+
diff --git a/dita/RTC-NG/API/rtc_api_data_type.dita b/dita/RTC-NG/API/rtc_api_data_type.dita index a897b554079..91cea22c25c 100644 --- a/dita/RTC-NG/API/rtc_api_data_type.dita +++ b/dita/RTC-NG/API/rtc_api_data_type.dita @@ -14,23 +14,23 @@
  • +
  • -
  • -
  • +
  • -
  • +
  • -
  • +
  • @@ -61,8 +61,8 @@
  • -
  • +
  • @@ -71,8 +71,14 @@
  • +
  • +
  • +
      +
    • +
    • +
    • @@ -82,14 +88,10 @@
  • -
  • -
      -
    • -
    • -
  • +
  • @@ -101,8 +103,9 @@
  • -
  • +
  • +
  • @@ -123,15 +126,16 @@
  • +
  • +
  • -
  • -
  • +
  • +
  • -
  • @@ -146,24 +150,28 @@
  • -
  • +
  • +
  • +
  • +
  • - +
  • + -
  • -
  • -
  • -
  • -
  • -
  • +
  • +
  • @@ -252,7 +256,13 @@
  • +
  • +
  • +
  • +
  • +
  • +
  • @@ -263,11 +273,11 @@
  • +
  • -
  • @@ -290,15 +300,17 @@
  • -
  • +
  • +
  • +
  • @@ -308,14 +320,15 @@
  • -
  • +
  • +
  • - + +
  • + + +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • + +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +
  • +