@volcengine/react-native-live-push 1.1.3-rc.0 → 1.2.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/build.gradle +2 -2
- package/android/src/main/java/com/volcengine/velive/rn/push/ClassHelper.java +9 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/NativeVariableManager.java +5 -8
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushModule.java +14 -2
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushPackage.java +16 -13
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushView.java +16 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushViewManager.java +7 -2
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerManager.java +410 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerView.java +434 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerViewManager.java +79 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/TextureMgr.java +168 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/YuvHelper.java +165 -0
- package/ios/VeLiveMixerHelper.h +46 -0
- package/ios/VeLiveMixerHelper.m +620 -0
- package/ios/VeLiveMixerView.h +69 -0
- package/ios/VeLiveMixerView.m +600 -0
- package/ios/VeLiveMixerViewManager.m +92 -0
- package/lib/commonjs/index.js +22698 -20359
- package/lib/commonjs/typescript/android/index.d.ts +44 -0
- package/lib/commonjs/typescript/codegen/android/api.d.ts +1068 -0
- package/lib/commonjs/typescript/codegen/android/callback.d.ts +333 -0
- package/lib/commonjs/typescript/codegen/android/errorcode.d.ts +92 -0
- package/lib/commonjs/typescript/codegen/android/index.d.ts +5 -0
- package/lib/commonjs/typescript/codegen/android/keytype.d.ts +1693 -0
- package/lib/commonjs/typescript/codegen/android/types.d.ts +33 -0
- package/lib/commonjs/typescript/codegen/ios/api.d.ts +1125 -0
- package/lib/commonjs/typescript/codegen/ios/callback.d.ts +242 -0
- package/lib/commonjs/typescript/codegen/ios/errorcode.d.ts +154 -0
- package/lib/commonjs/typescript/codegen/ios/external.d.ts +1 -0
- package/lib/commonjs/typescript/codegen/ios/index.d.ts +6 -0
- package/lib/commonjs/typescript/codegen/ios/keytype.d.ts +1154 -0
- package/lib/commonjs/typescript/codegen/ios/types.d.ts +46 -0
- package/lib/commonjs/typescript/codegen/pack/api.d.ts +1470 -0
- package/lib/commonjs/typescript/codegen/pack/callback.d.ts +446 -0
- package/lib/commonjs/typescript/codegen/pack/errorcode.d.ts +109 -0
- package/lib/commonjs/typescript/codegen/pack/index.d.ts +5 -0
- package/lib/commonjs/typescript/codegen/pack/keytype.d.ts +2248 -0
- package/lib/commonjs/typescript/codegen/pack/types.d.ts +68 -0
- package/lib/commonjs/typescript/codegen/type-shim.d.ts +6 -0
- package/lib/commonjs/typescript/component.d.ts +15 -0
- package/lib/commonjs/typescript/core/api.d.ts +18 -0
- package/lib/commonjs/typescript/core/callback.d.ts +2 -0
- package/lib/commonjs/typescript/core/env.d.ts +29 -0
- package/lib/commonjs/typescript/core/errorcode.d.ts +2 -0
- package/lib/commonjs/typescript/core/index.d.ts +6 -0
- package/lib/commonjs/typescript/core/keytype.d.ts +18 -0
- package/lib/commonjs/typescript/core/mixer.d.ts +26 -0
- package/lib/commonjs/typescript/core/pusher.d.ts +13 -0
- package/lib/commonjs/typescript/index.d.ts +3 -0
- package/lib/commonjs/typescript/ios/extends.d.ts +41 -0
- package/lib/commonjs/typescript/platforms/android/extends.d.ts +8 -0
- package/lib/commonjs/typescript/platforms/android/helper.d.ts +8 -0
- package/lib/commonjs/typescript/platforms/android/mixer.d.ts +8 -0
- package/lib/commonjs/typescript/platforms/ios/extends.d.ts +17 -0
- package/lib/commonjs/typescript/platforms/ios/helper.d.ts +8 -0
- package/lib/commonjs/typescript/platforms/ios/mixer.d.ts +9 -0
- package/lib/commonjs/typescript/runtime.d.ts +1 -0
- package/lib/commonjs/typescript/view/MixView.d.ts +52 -0
- package/lib/commonjs/typescript/view/VeImageView.d.ts +19 -0
- package/lib/commonjs/typescript/view/VeTextView.d.ts +7 -0
- package/lib/commonjs/typescript/view/VeView.d.ts +7 -0
- package/lib/commonjs/typescript/view/VeWebView.d.ts +7 -0
- package/lib/commonjs/typescript/view/index.d.ts +5 -0
- package/lib/module/index.js +22695 -20360
- package/lib/module/typescript/android/index.d.ts +44 -0
- package/lib/module/typescript/codegen/android/api.d.ts +1068 -0
- package/lib/module/typescript/codegen/android/callback.d.ts +333 -0
- package/lib/module/typescript/codegen/android/errorcode.d.ts +92 -0
- package/lib/module/typescript/codegen/android/index.d.ts +5 -0
- package/lib/module/typescript/codegen/android/keytype.d.ts +1693 -0
- package/lib/module/typescript/codegen/android/types.d.ts +33 -0
- package/lib/module/typescript/codegen/ios/api.d.ts +1125 -0
- package/lib/module/typescript/codegen/ios/callback.d.ts +242 -0
- package/lib/module/typescript/codegen/ios/errorcode.d.ts +154 -0
- package/lib/module/typescript/codegen/ios/external.d.ts +1 -0
- package/lib/module/typescript/codegen/ios/index.d.ts +6 -0
- package/lib/module/typescript/codegen/ios/keytype.d.ts +1154 -0
- package/lib/module/typescript/codegen/ios/types.d.ts +46 -0
- package/lib/module/typescript/codegen/pack/api.d.ts +1470 -0
- package/lib/module/typescript/codegen/pack/callback.d.ts +446 -0
- package/lib/module/typescript/codegen/pack/errorcode.d.ts +109 -0
- package/lib/module/typescript/codegen/pack/index.d.ts +5 -0
- package/lib/module/typescript/codegen/pack/keytype.d.ts +2248 -0
- package/lib/module/typescript/codegen/pack/types.d.ts +68 -0
- package/lib/module/typescript/codegen/type-shim.d.ts +6 -0
- package/lib/module/typescript/component.d.ts +15 -0
- package/lib/module/typescript/core/api.d.ts +18 -0
- package/lib/module/typescript/core/callback.d.ts +2 -0
- package/lib/module/typescript/core/env.d.ts +29 -0
- package/lib/module/typescript/core/errorcode.d.ts +2 -0
- package/lib/module/typescript/core/index.d.ts +6 -0
- package/lib/module/typescript/core/keytype.d.ts +18 -0
- package/lib/module/typescript/core/mixer.d.ts +26 -0
- package/lib/module/typescript/core/pusher.d.ts +13 -0
- package/lib/module/typescript/index.d.ts +3 -0
- package/lib/module/typescript/ios/extends.d.ts +41 -0
- package/lib/module/typescript/platforms/android/extends.d.ts +8 -0
- package/lib/module/typescript/platforms/android/helper.d.ts +8 -0
- package/lib/module/typescript/platforms/android/mixer.d.ts +8 -0
- package/lib/module/typescript/platforms/ios/extends.d.ts +17 -0
- package/lib/module/typescript/platforms/ios/helper.d.ts +8 -0
- package/lib/module/typescript/platforms/ios/mixer.d.ts +9 -0
- package/lib/module/typescript/runtime.d.ts +1 -0
- package/lib/module/typescript/view/MixView.d.ts +52 -0
- package/lib/module/typescript/view/VeImageView.d.ts +19 -0
- package/lib/module/typescript/view/VeTextView.d.ts +7 -0
- package/lib/module/typescript/view/VeView.d.ts +7 -0
- package/lib/module/typescript/view/VeWebView.d.ts +7 -0
- package/lib/module/typescript/view/index.d.ts +5 -0
- package/lib/typescript/android/index.d.ts +0 -3
- package/lib/typescript/codegen/android/api.d.ts +194 -762
- package/lib/typescript/codegen/android/callback.d.ts +85 -48
- package/lib/typescript/codegen/android/errorcode.d.ts +30 -0
- package/lib/typescript/codegen/android/keytype.d.ts +514 -122
- package/lib/typescript/codegen/ios/api.d.ts +380 -351
- package/lib/typescript/codegen/ios/callback.d.ts +33 -6
- package/lib/typescript/codegen/ios/errorcode.d.ts +52 -2
- package/lib/typescript/codegen/ios/keytype.d.ts +313 -35
- package/lib/typescript/codegen/pack/api.d.ts +302 -821
- package/lib/typescript/codegen/pack/callback.d.ts +54 -49
- package/lib/typescript/codegen/pack/errorcode.d.ts +38 -5
- package/lib/typescript/codegen/pack/keytype.d.ts +672 -228
- package/lib/typescript/core/api.d.ts +18 -2
- package/lib/typescript/core/keytype.d.ts +16 -0
- package/lib/typescript/core/mixer.d.ts +26 -0
- package/lib/typescript/core/pusher.d.ts +0 -3
- package/lib/typescript/index.d.ts +1 -0
- package/lib/typescript/platforms/android/extends.d.ts +8 -0
- package/lib/typescript/platforms/android/mixer.d.ts +8 -0
- package/lib/typescript/platforms/ios/mixer.d.ts +9 -0
- package/lib/typescript/view/MixView.d.ts +52 -0
- package/lib/typescript/view/VeImageView.d.ts +19 -0
- package/lib/typescript/view/VeTextView.d.ts +7 -0
- package/lib/typescript/view/VeView.d.ts +7 -0
- package/lib/typescript/view/VeWebView.d.ts +7 -0
- package/lib/typescript/view/index.d.ts +5 -0
- package/package.json +1 -1
- package/react-native-velive-push.podspec +3 -3
- package/android/src/main/java/com/volcengine/velive/rn/push/ScreenCaptureHelper.java +0 -73
|
@@ -1,29 +1,31 @@
|
|
|
1
1
|
import { NSString, BOOL, int, float, CGPoint, NSDictionary, id, long, NSArray, UIImage } from './types';
|
|
2
|
-
import { VeLiveFileRecorderConfiguration,
|
|
2
|
+
import { VeLiveFileRecorderConfiguration, VeLivePusherLogLevel, VeLivePusherConfiguration, VeLivePusherRenderMode, VeLiveVideoMirrorType, VeLiveVideoCaptureType, VeLiveAudioCaptureType, VeLiveVideoEncoderConfiguration, VeLiveAudioEncoderConfiguration, UIInterfaceOrientation, VeLiveVideoFrame, VeLiveVideoEncodeFrame, VeLiveAudioFrame, VeLiveVideoEffectLicenseConfiguration } from './keytype';
|
|
3
3
|
import { VeLiveMediaPlayerListener, VeLiveMediaPlayerFrameListener, VeLivePusherObserver, VeLivePusherStatisticsObserver, VeLiveVideoFrameListener, VeLiveAudioFrameListener, VeLiveScreenCaptureStatusObserver, VeLiveFileRecordingListener, VeLiveVideoFrameFilter, VeLiveAudioFrameFilter, VeLiveSnapshotListener } from './callback';
|
|
4
4
|
import { UIView } from './external';
|
|
5
5
|
export declare class VeLiveFileRecorderManager {
|
|
6
6
|
/** {zh}
|
|
7
7
|
* @detail api
|
|
8
8
|
* @brief 开始直播录制。
|
|
9
|
-
* @notes
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* - 录制出现错误,会触发 [onFileRecordingError:message:](155319#VeLiveFileRecordingListener-onfilerecordingerror-message) 回调消息。
|
|
9
|
+
* @notes - 请在调用 [startPush:](#VeLivePusher-startpush) 推流成功之后,调用该方法,直播过程中的音视频数据将保存到本地;
|
|
10
|
+
* - 本方法为异步操作;
|
|
11
|
+
* - 开始录制后,会触发 [onFileRecordingStarted](155319#VeLiveFileRecordingListener-onfilerecordingstarted) 回调消息;
|
|
12
|
+
* - 录制出现错误,会触发 [onFileRecordingError:message:](155319#VeLiveFileRecordingListener-onfilerecordingerror-message) 回调消息。
|
|
14
13
|
* @param path 录制文件保存路径,不能为空。
|
|
15
14
|
* @param config 直播录制配置。详情请参见 [VeLiveFileRecorderConfiguration](155321#VeLiveFileRecorderConfiguration)。
|
|
15
|
+
* @order 43
|
|
16
16
|
*/
|
|
17
|
+
|
|
17
18
|
startRecord(path: NSString, config: VeLiveFileRecorderConfiguration): void;
|
|
18
19
|
/** {zh}
|
|
19
20
|
* @detail api
|
|
20
21
|
* @brief 停止本地直播录制。
|
|
21
|
-
* @notes
|
|
22
|
-
* - 请在调用 [startRecord:config:](#VeLiveFileRecorderManager-startrecord-config) 成功开始录制之后,调用该方法;
|
|
22
|
+
* @notes - 请在调用 [startRecord:config:](#VeLiveFileRecorderManager-startrecord-config) 成功开始录制之后,调用该方法;
|
|
23
23
|
* - 本方法为异步操作;
|
|
24
|
-
* - 停止录制,会触发 [
|
|
24
|
+
* - 停止录制,会触发 [onFileRecordingStopped](155319#VeLiveFileRecordingListener-onfilerecordingstopped) 回调消息;
|
|
25
25
|
* - 录制出现错误,会触发 [onFileRecordingError:message:](155319#VeLiveFileRecordingListener-onfilerecordingerror-message) 回调消息。
|
|
26
|
+
* @order 45
|
|
26
27
|
*/
|
|
28
|
+
|
|
27
29
|
stopRecord(): void;
|
|
28
30
|
init(): this;
|
|
29
31
|
}
|
|
@@ -31,175 +33,186 @@ export declare class VeLiveCameraDevice {
|
|
|
31
33
|
/** {zh}
|
|
32
34
|
* @detail api
|
|
33
35
|
* @brief 是否支持闪光灯。
|
|
36
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
37
|
+
* @order 49
|
|
34
38
|
* @return <br>
|
|
35
39
|
* - YES:支持;
|
|
36
40
|
* - NO:不支持。
|
|
37
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
38
|
-
* @order 49
|
|
39
41
|
*/
|
|
42
|
+
|
|
40
43
|
isTorchSupported(): BOOL;
|
|
41
44
|
/** {zh}
|
|
42
45
|
* @detail api
|
|
43
46
|
* @brief 开启/关闭闪光灯。
|
|
44
|
-
* @
|
|
45
|
-
* - =0:开启/关闭成功;
|
|
46
|
-
* - ≠0:开启/关闭失败。
|
|
47
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
47
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
48
48
|
* @order 51
|
|
49
49
|
* @param enable 是否开启闪光灯。默认为 NO。 <br>
|
|
50
50
|
* - YES:开启;
|
|
51
51
|
* - NO:关闭。
|
|
52
|
+
* @return - =0:开启/关闭成功;
|
|
53
|
+
* - ≠0:开启/关闭失败。
|
|
52
54
|
*/
|
|
55
|
+
|
|
53
56
|
enableTorch(enable: BOOL): int;
|
|
54
57
|
/** {zh}
|
|
55
58
|
* @detail api
|
|
56
59
|
* @brief 设置摄像头的缩放倍数。
|
|
60
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
61
|
+
* @order 52
|
|
62
|
+
* @param ratio 缩放倍数。默认为原尺寸,缩放倍数的取值范围为 [[getMinZoomRatio](#VeLiveCameraDevice-getminzoomratio),[getMaxZoomRatio](#VeLiveCameraDevice-getmaxzoomratio)]。
|
|
57
63
|
* @return <br>
|
|
58
64
|
* - =0:缩放成功;
|
|
59
65
|
* - ≠0:缩放失败。
|
|
60
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
61
|
-
* @order 52
|
|
62
|
-
* @param ratio 缩放倍数。默认为原尺寸,缩放倍数的取值范围为 [[getMinZoomRatio,getMaxZoomRatio](155318#VeLiveCameraDevice-getmaxzoomratio)]。
|
|
63
66
|
*/
|
|
67
|
+
|
|
64
68
|
setZoomRatio(ratio: float): int;
|
|
65
69
|
/** {zh}
|
|
66
70
|
* @detail api
|
|
67
71
|
* @brief 获取摄像头当前的缩放倍数。
|
|
68
|
-
* @
|
|
69
|
-
* - ≤0:表示不支持缩放;
|
|
70
|
-
* - \\>0:支持缩放,数值表示当前缩放倍数。
|
|
71
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
72
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
72
73
|
* @order 53
|
|
74
|
+
* @return - ≤0:表示不支持缩放;
|
|
75
|
+
* - >0:支持缩放,数值表示当前缩放倍数。
|
|
73
76
|
*/
|
|
77
|
+
|
|
74
78
|
getCurrentZoomRatio(): float;
|
|
75
79
|
/** {zh}
|
|
76
80
|
* @detail api
|
|
77
81
|
* @brief 获取摄像头的最大缩放倍数。
|
|
78
|
-
* @
|
|
79
|
-
* - ≤0:表示不支持缩放;
|
|
80
|
-
* - \\>0:支持缩放,数值表示最大缩放倍数。
|
|
81
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
82
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
82
83
|
* @order 54
|
|
84
|
+
* @return <br>
|
|
85
|
+
* - ≤0:表示不支持缩放;
|
|
86
|
+
* - >0:支持缩放,数值表示最大缩放倍数。
|
|
83
87
|
*/
|
|
88
|
+
|
|
84
89
|
getMaxZoomRatio(): float;
|
|
85
90
|
/** {zh}
|
|
86
91
|
* @detail api
|
|
87
92
|
* @brief 获取摄像头的最小缩放倍数。
|
|
88
|
-
* @
|
|
89
|
-
* - ≤0:表示不支持缩放;
|
|
90
|
-
* - \\>0:支持缩放,数值表示最小缩放倍数。
|
|
91
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
93
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
92
94
|
* @order 55
|
|
95
|
+
* @return <br>
|
|
96
|
+
* - ≤0:表示不支持缩放;
|
|
97
|
+
* - >0:支持缩放,数值表示最小缩放倍数。
|
|
93
98
|
*/
|
|
99
|
+
|
|
94
100
|
getMinZoomRatio(): float;
|
|
95
101
|
/** {zh}
|
|
96
102
|
* @detail api
|
|
97
103
|
* @brief 是否支持自动对焦。
|
|
104
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
105
|
+
* @order 56
|
|
98
106
|
* @return <br>
|
|
99
107
|
* - YES:支持;
|
|
100
108
|
* - NO:不支持。
|
|
101
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
102
|
-
* @order 56
|
|
103
109
|
*/
|
|
110
|
+
|
|
104
111
|
isAutoFocusEnabled(): BOOL;
|
|
105
112
|
/** {zh}
|
|
106
113
|
* @detail api
|
|
107
114
|
* @brief 开启/关闭自动对焦功能。
|
|
108
|
-
* @
|
|
109
|
-
* - =0:开启/关闭成功;
|
|
110
|
-
* - ≠0:开启/关闭失败。
|
|
111
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
115
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
112
116
|
* @order 57
|
|
113
117
|
* @param enable 是否开启自动对焦,默认为 YES。
|
|
114
118
|
* - YES:开启;
|
|
115
119
|
* - NO:关闭。
|
|
120
|
+
* @return <br>
|
|
121
|
+
* - =0:开启/关闭成功;
|
|
122
|
+
* - ≠0:开启/关闭失败。
|
|
116
123
|
*/
|
|
124
|
+
|
|
117
125
|
enableAutoFocus(enable: BOOL): int;
|
|
118
126
|
/** {zh}
|
|
119
127
|
* @detail api
|
|
120
128
|
* @brief 设置摄像头的对焦位置。
|
|
129
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
130
|
+
* @order 58
|
|
131
|
+
* @param position 以左上角为原点,对焦点距当前视图的坐标值。
|
|
121
132
|
* @return <br>
|
|
122
133
|
* - =0:设置成功;
|
|
123
134
|
* - ≠0:设置失败。
|
|
124
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
125
|
-
* @order 58
|
|
126
|
-
* @param position 以左上角为原点,对焦点距当前视图的坐标值。
|
|
127
135
|
*/
|
|
136
|
+
|
|
128
137
|
setFocusPosition(position: CGPoint): int;
|
|
129
138
|
/** {zh}
|
|
130
139
|
* @detail api
|
|
131
140
|
* @brief 检查当前使用的摄像头是否支持手动设置曝光点。
|
|
141
|
+
* @notes 必须已调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 使用 SDK 内部采集模块进行视频采集时,才能检查曝光点设置能力。
|
|
142
|
+
* @order 59
|
|
132
143
|
* @return <br>
|
|
133
144
|
* - YES: 支持。 <br>
|
|
134
145
|
* - NO: 不支持。
|
|
135
|
-
* @notes 必须已调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 使用 SDK 内部采集模块进行视频采集时,才能检查曝光点设置能力。
|
|
136
|
-
* @order 59
|
|
137
146
|
*/
|
|
147
|
+
|
|
138
148
|
isExposurePositionSupported(): BOOL;
|
|
139
149
|
/** {zh}
|
|
140
150
|
* @detail api
|
|
141
151
|
* @brief 设置当前使用的摄像头的曝光点。
|
|
142
152
|
* @param position 曝光点坐标。以本地预览画布的左上为坐标原点,`position`的`x`字段为曝光点水平方向归一化坐标,`y`字段为曝光点垂直方向归一化坐标,取值范围为 [0, 1]。
|
|
153
|
+
* @notes - 必须已调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 使用 SDK 内部采集模块进行视频采集,并且使用 SDK 内部渲染时,才能设置曝光点。
|
|
154
|
+
* - 曝光点设置为画布中央(即`x`和`y`均取 0.5)时,恢复系统默认值。
|
|
155
|
+
* - 调用 [stopVideoCapture:](155318#VeLivePusher-stopvideocapture) 关闭内部采集后,设置的曝光点失效。
|
|
156
|
+
* @order 60
|
|
143
157
|
* @return <br>
|
|
144
158
|
* - =0: 成功。
|
|
145
159
|
* - ≠0: 失败。
|
|
146
|
-
* @notes <br>
|
|
147
|
-
* - 必须已调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 使用 SDK 内部采集模块进行视频采集,并且使用 SDK 内部渲染时,才能设置曝光点。 <br>
|
|
148
|
-
* - 曝光点设置为画布中央(即`x`和`y`均取 0.5)时,恢复系统默认值。 <br>
|
|
149
|
-
* - 调用 stopVideoCapture:{@link #VeLivePusher#stopVideoCapture} 关闭内部采集后,设置的曝光点失效。
|
|
150
|
-
* @order 60
|
|
151
160
|
*/
|
|
161
|
+
|
|
152
162
|
setExposurePosition(position: CGPoint): int;
|
|
153
163
|
/** {zh}
|
|
154
164
|
* @detail api
|
|
155
165
|
* @brief 设置当前使用的摄像头的曝光补偿。
|
|
156
|
-
* @
|
|
157
|
-
*
|
|
158
|
-
* - ≠0:设置失败。
|
|
159
|
-
* @notes <br>
|
|
160
|
-
* - 必须已调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 使用 SDK 内部采集模块进行视频采集时,才能设置曝光补偿。
|
|
161
|
-
* - 调用 stopVideoCapture:{@link #VeLivePusher#stopVideoCapture} 关闭内部采集后,设置的曝光补偿失效。
|
|
166
|
+
* @notes - 必须已调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 使用 SDK 内部采集模块进行视频采集时,才能设置曝光补偿。
|
|
167
|
+
* - 调用 [stopVideoCapture:](#VeLivePusher-stopvideocapture) 关闭内部采集后,设置的曝光补偿失效。
|
|
162
168
|
* @order 61
|
|
163
|
-
* @param value 曝光补偿值,取值范围 [[getMinExposureCompensation](
|
|
169
|
+
* @param value 曝光补偿值,取值范围 [[getMinExposureCompensation](#VeLiveCameraDevice-getminexposurecompensation), [getMaxExposureCompensation](#VeLiveCameraDevice-getmaxexposurecompensation)],0 为系统默认值表示没有曝光补偿。
|
|
170
|
+
* @return - =0:设置成功;
|
|
171
|
+
* - ≠0:设置失败。
|
|
164
172
|
*/
|
|
173
|
+
|
|
165
174
|
setExposureCompensation(value: float): int;
|
|
166
175
|
/** {zh}
|
|
167
176
|
* @detail api
|
|
168
177
|
* @brief 获取摄像头的最小曝光补偿。
|
|
178
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
179
|
+
* @order 62
|
|
169
180
|
* @return <br>
|
|
170
181
|
* - ≤0:表示不支持曝光补偿;
|
|
171
182
|
* - >0:支持曝光补偿,数值表示最小曝光补偿。
|
|
172
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
173
|
-
* @order 62
|
|
174
183
|
*/
|
|
184
|
+
|
|
175
185
|
getMinExposureCompensation(): float;
|
|
176
186
|
/** {zh}
|
|
177
187
|
* @detail api
|
|
178
188
|
* @brief 获取摄像头的最大曝光补偿。
|
|
189
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
190
|
+
* @order 63
|
|
179
191
|
* @return <br>
|
|
180
192
|
* - ≤0:表示不支持曝光补偿;
|
|
181
193
|
* - >0:支持曝光补偿,数值表示最大曝光补偿。
|
|
182
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
183
|
-
* @order 63
|
|
184
194
|
*/
|
|
195
|
+
|
|
185
196
|
getMaxExposureCompensation(): float;
|
|
186
197
|
/** {zh}
|
|
187
198
|
* @detail api
|
|
188
199
|
* @brief 设置相机参数。
|
|
189
|
-
* @notes
|
|
200
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
190
201
|
* @order 64
|
|
191
202
|
* @param parameter 相机参数字典,包含要设置的参数名称(键)和对应的值
|
|
192
203
|
*/
|
|
204
|
+
|
|
193
205
|
setParameter(parameter: NSDictionary): void;
|
|
194
206
|
/** {zh}
|
|
195
207
|
* @detail api
|
|
196
208
|
* @brief 获取相机参数。
|
|
197
|
-
* @
|
|
198
|
-
* 相机参数的值,具体类型需要根据参数名称确定。
|
|
199
|
-
* @notes <br>需要在调用 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 启动相机采集后,调用本方法。
|
|
209
|
+
* @notes 需要在调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 启动相机采集后,调用本方法。
|
|
200
210
|
* @order 65
|
|
201
211
|
* @param key 需要获取的相机参数的名称。
|
|
212
|
+
* @return <br>
|
|
213
|
+
* 相机参数的值,具体类型需要根据参数名称确定。
|
|
202
214
|
*/
|
|
215
|
+
|
|
203
216
|
getParameter(key: NSString): id;
|
|
204
217
|
init(): this;
|
|
205
218
|
}
|
|
@@ -207,36 +220,39 @@ export declare class VeLiveMediaPlayer {
|
|
|
207
220
|
/** {zh}
|
|
208
221
|
* @detail api
|
|
209
222
|
* @brief 设置文件路径。支持的文件格式包括 MP3、AAC、M4A、WAV。
|
|
223
|
+
* @order 1
|
|
224
|
+
* @param url 文件路径。
|
|
210
225
|
* @return <br>
|
|
211
226
|
* - 0:成功;
|
|
212
227
|
* - ≠0:失败。
|
|
213
|
-
* @order 87
|
|
214
|
-
* @param url 文件路径。
|
|
215
228
|
*/
|
|
229
|
+
|
|
216
230
|
prepare(url: NSString): int;
|
|
217
231
|
/** {zh}
|
|
218
232
|
* @detail api
|
|
219
233
|
* @brief 销毁播放器实例。
|
|
220
|
-
* @order
|
|
234
|
+
* @order 3
|
|
221
235
|
*/
|
|
236
|
+
|
|
222
237
|
destroy(): void;
|
|
223
238
|
/** {zh}
|
|
224
239
|
* @detail api
|
|
225
240
|
* @brief 设置播放状态的监听。
|
|
226
|
-
* @notes
|
|
227
|
-
*
|
|
228
|
-
* @order 89
|
|
241
|
+
* @notes 重复调用本方法,仅最后一次调用生效。
|
|
242
|
+
* @order 4
|
|
229
243
|
* @param listener 播放状态监听。详情请参见 [VeLiveMediaPlayerListener](155319#VeLiveMediaPlayerListener)。
|
|
230
244
|
*/
|
|
245
|
+
|
|
231
246
|
setListener(listener: id<VeLiveMediaPlayerListener>): void;
|
|
232
247
|
/** {zh}
|
|
233
248
|
* @detail api
|
|
234
249
|
* @brief 设置音视频帧回调的监听。
|
|
235
250
|
* @notes <br>
|
|
236
251
|
* 重复调用本方法,仅最后一次调用生效。
|
|
237
|
-
* @order
|
|
252
|
+
* @order 5
|
|
238
253
|
* @param listener 音视频帧回调监听。详情请参见 [VeLiveMediaPlayerFrameListener](155319#VeLiveMediaPlayerFrameListener)。
|
|
239
254
|
*/
|
|
255
|
+
|
|
240
256
|
setFrameListener(listener: id<VeLiveMediaPlayerFrameListener>): void;
|
|
241
257
|
/** {zh}
|
|
242
258
|
* @detail api
|
|
@@ -244,16 +260,18 @@ export declare class VeLiveMediaPlayer {
|
|
|
244
260
|
* @param enable 开启/关闭,默认为 NO。 <br>
|
|
245
261
|
* - YES:开启;
|
|
246
262
|
* - NO:关闭。
|
|
247
|
-
* @order
|
|
263
|
+
* @order 6
|
|
248
264
|
*/
|
|
265
|
+
|
|
249
266
|
enableMixer(enable: BOOL): void;
|
|
250
267
|
/** {zh}
|
|
251
268
|
* @detail api
|
|
252
269
|
* @brief 开启/关闭自动音量均衡。
|
|
253
|
-
* @order
|
|
270
|
+
* @order 7
|
|
254
271
|
* @param sourceLufs 源响度。
|
|
255
272
|
* @param targetLufs 目标响度。
|
|
256
273
|
*/
|
|
274
|
+
|
|
257
275
|
enableAutoEq(sourceLufs: float, targetLufs: float): void;
|
|
258
276
|
/** {zh}
|
|
259
277
|
* @detail api
|
|
@@ -261,6 +279,7 @@ export declare class VeLiveMediaPlayer {
|
|
|
261
279
|
* @param view 渲染视图。
|
|
262
280
|
* @order 93
|
|
263
281
|
*/
|
|
282
|
+
|
|
264
283
|
setRenderView(view: UIView): void;
|
|
265
284
|
/** {zh}
|
|
266
285
|
* @detail api
|
|
@@ -268,84 +287,93 @@ export declare class VeLiveMediaPlayer {
|
|
|
268
287
|
* @param enable 是否循环播放。默认为 NO。<br>
|
|
269
288
|
* - YES:循环播放;
|
|
270
289
|
* - NO:不循环播放。
|
|
271
|
-
* @order
|
|
290
|
+
* @order 8
|
|
272
291
|
*/
|
|
292
|
+
|
|
273
293
|
enableBGMLoop(enable: BOOL): void;
|
|
274
294
|
/** {zh}
|
|
275
295
|
* @detail api
|
|
276
296
|
* @brief 开始播放。
|
|
297
|
+
* @notes
|
|
298
|
+
* - 需要在调用 [prepare:](#VeLiveMediaPlayer-prepare) 设置文件路径后,调用本方法;
|
|
299
|
+
* - 此方法为异步操作。当 SDK 收到开始播放 [onStart](155319#VeLiveMediaPlayerListener-onstart) 的回调后,开始播放。
|
|
300
|
+
* @order 9
|
|
277
301
|
* @return <br>
|
|
278
302
|
* - 0:成功;
|
|
279
303
|
* - ≠0:失败。
|
|
280
|
-
* @notes <br>
|
|
281
|
-
* - 需要在调用 prepare:{@link #VeLiveMediaPlayer#prepare} 设置文件路径后,调用本方法;
|
|
282
|
-
* - 此方法为异步操作。当 SDK 收到开始播放 onStart{@link #VeLiveMediaPlayerListener#onStart} 的回调后,开始播放。
|
|
283
|
-
* @order 94
|
|
284
304
|
*/
|
|
305
|
+
|
|
285
306
|
start(): Promise<int>;
|
|
286
307
|
/** {zh}
|
|
287
308
|
* @detail api
|
|
288
309
|
* @brief 停止播放。
|
|
310
|
+
* @notes
|
|
311
|
+
* 需要在调用 [start](#VeLiveMediaPlayer-start) 开始播放后,调用本方法。
|
|
312
|
+
* @order 10
|
|
289
313
|
* @return <br>
|
|
290
314
|
* - 0:成功;
|
|
291
315
|
* - ≠0:失败。
|
|
292
|
-
* @notes <br>
|
|
293
|
-
* 需要在调用 start{@link #start} 开始播放后,调用本方法。
|
|
294
|
-
* @order 97
|
|
295
316
|
*/
|
|
317
|
+
|
|
296
318
|
stop(): Promise<int>;
|
|
297
319
|
/** {zh}
|
|
298
320
|
* @detail api
|
|
299
321
|
* @brief 暂停播放。
|
|
300
|
-
* @notes
|
|
301
|
-
*
|
|
302
|
-
* @order
|
|
322
|
+
* @notes
|
|
323
|
+
* 需要在调用 [start](#VeLiveMediaPlayer-start) 开始播放后,调用本方法。
|
|
324
|
+
* @order 11
|
|
303
325
|
*/
|
|
326
|
+
|
|
304
327
|
pause(): Promise<void>;
|
|
305
328
|
/** {zh}
|
|
306
329
|
* @detail api
|
|
307
330
|
* @brief 恢复播放。
|
|
308
|
-
* @notes
|
|
309
|
-
*
|
|
310
|
-
* @order
|
|
331
|
+
* @notes
|
|
332
|
+
* 需要在调用 [pause](#VeLiveMediaPlayer-pause) 暂停播放后,调用本方法。
|
|
333
|
+
* @order 12
|
|
311
334
|
*/
|
|
335
|
+
|
|
312
336
|
resume(): Promise<void>;
|
|
313
337
|
/** {zh}
|
|
314
338
|
* @detail api
|
|
315
339
|
* @brief 设置播放进度。
|
|
340
|
+
* @order 13
|
|
341
|
+
* @param pos 播放时间,单位为 ms。
|
|
316
342
|
* @return <br>
|
|
317
343
|
* - 0:成功;
|
|
318
344
|
* - ≠0:失败。
|
|
319
|
-
* @order 100
|
|
320
|
-
* @param pos 播放时间,单位为 ms。
|
|
321
345
|
*/
|
|
346
|
+
|
|
322
347
|
seek(pos: long): int;
|
|
323
348
|
/** {zh}
|
|
324
349
|
* @detail api
|
|
325
350
|
* @brief 获取文件的总时长,单位为 ms。
|
|
351
|
+
* @notes
|
|
352
|
+
* 需要在调用 [start](#VeLiveMediaPlayer-start) 开始播放后,调用本方法。
|
|
353
|
+
* @order 2
|
|
326
354
|
* @return <br>
|
|
327
355
|
* - >0:成功,音频文件时长;
|
|
328
356
|
* - ≤0:失败。
|
|
329
|
-
* @notes <br>
|
|
330
|
-
* 需要在调用 start{@link #start} 开始播放后,调用本方法。
|
|
331
|
-
* @order 101
|
|
332
357
|
*/
|
|
358
|
+
|
|
333
359
|
getDuration(): long;
|
|
334
360
|
/** {zh}
|
|
335
361
|
* @detail api
|
|
336
362
|
* @brief 设置播放音频的音量。
|
|
337
|
-
* @order
|
|
363
|
+
* @order 14
|
|
338
364
|
* @param volume 播放音频音量,取值范围为 [0.0,4.0]。
|
|
339
365
|
*/
|
|
366
|
+
|
|
340
367
|
setBGMVolume(volume: float): void;
|
|
341
368
|
/** {zh}
|
|
342
369
|
* @detail api
|
|
343
370
|
* @brief 设置音频采集音量。
|
|
344
|
-
* @notes
|
|
345
|
-
*
|
|
346
|
-
* @order
|
|
371
|
+
* @notes
|
|
372
|
+
* 需要在调用 [start](#VeLiveMediaPlayer-start) 开始播放背景音乐后,调用本方法。
|
|
373
|
+
* @order 15
|
|
347
374
|
* @param volume 音频采集音量,取值范围为 [0.0,4.0]。
|
|
348
375
|
*/
|
|
376
|
+
|
|
349
377
|
setVoiceVolume(volume: float): void;
|
|
350
378
|
init(): this;
|
|
351
379
|
}
|
|
@@ -356,14 +384,16 @@ export declare class VeLiveAudioDevice {
|
|
|
356
384
|
* @order 60
|
|
357
385
|
* @param level 音量响度等级,取值范围为 [0.0,4.0]。
|
|
358
386
|
*/
|
|
387
|
+
|
|
359
388
|
setVoiceLoudness(level: float): void;
|
|
360
389
|
/** {zh}
|
|
361
390
|
* @detail api
|
|
362
391
|
* @brief 获取当前音量响度。
|
|
392
|
+
* @order 61
|
|
363
393
|
* @return <br>
|
|
364
394
|
* 当前音量响度等级。
|
|
365
|
-
* @order 61
|
|
366
395
|
*/
|
|
396
|
+
|
|
367
397
|
getVoiceLoudness(): float;
|
|
368
398
|
/** {zh}
|
|
369
399
|
* @detail api
|
|
@@ -373,6 +403,7 @@ export declare class VeLiveAudioDevice {
|
|
|
373
403
|
* - NO:不支持。
|
|
374
404
|
* @order 62
|
|
375
405
|
*/
|
|
406
|
+
|
|
376
407
|
isSupportHardwareEcho(): BOOL;
|
|
377
408
|
/** {zh}
|
|
378
409
|
* @detail api
|
|
@@ -380,138 +411,85 @@ export declare class VeLiveAudioDevice {
|
|
|
380
411
|
* @param enable 耳返功能开关。默认值为 NO。<br>
|
|
381
412
|
* - YES:开启;
|
|
382
413
|
* - NO:关闭。
|
|
383
|
-
* @notes
|
|
384
|
-
*
|
|
414
|
+
* @notes
|
|
415
|
+
* 需要在调用 [startAudioCapture:](#VeLivePusher-startaudiocapture) 启动音频采集后,调用本方法。
|
|
385
416
|
* @order 64
|
|
386
417
|
*/
|
|
418
|
+
|
|
387
419
|
enableEcho(enable: BOOL): void;
|
|
388
420
|
/** {zh}
|
|
389
421
|
* @detail api
|
|
390
422
|
* @brief 获取当前耳返开启状态。
|
|
423
|
+
* @notes
|
|
424
|
+
* 需要在调用 [startAudioCapture:](#VeLivePusher-startaudiocapture) 启动音频采集后,调用本方法。
|
|
425
|
+
* @order 65
|
|
391
426
|
* @return <br>
|
|
392
427
|
* - YES:开启;
|
|
393
428
|
* - NO:关闭。
|
|
394
|
-
* @notes <br>
|
|
395
|
-
* 需要在调用 startAudioCapture:{@link #VeLivePusher#startAudioCapture} 启动音频采集后,调用本方法。
|
|
396
|
-
* @order 65
|
|
397
429
|
*/
|
|
430
|
+
|
|
398
431
|
isEnableEcho(): BOOL;
|
|
399
432
|
init(): this;
|
|
400
433
|
}
|
|
401
|
-
export declare class VeLiveMixerManager {
|
|
402
|
-
/** {zh}
|
|
403
|
-
* @detail api
|
|
404
|
-
* @brief 添加一路需要混流的视频流到混流器中。
|
|
405
|
-
* @return <br>
|
|
406
|
-
* 视频流 ID。
|
|
407
|
-
* @order 65
|
|
408
|
-
*/
|
|
409
|
-
addVideoStream(): int;
|
|
410
|
-
/** {zh}
|
|
411
|
-
* @detail api
|
|
412
|
-
* @brief 从混流器中移除一路非主路的视频流。
|
|
413
|
-
* @order 66
|
|
414
|
-
* @param streamId 需要移除的非主路视频流 ID。
|
|
415
|
-
*/
|
|
416
|
-
removeVideoStream(streamId: int): void;
|
|
417
|
-
/** {zh}
|
|
418
|
-
* @detail api
|
|
419
|
-
* @brief 添加一路音频流到混流器中,并指定混流类型。
|
|
420
|
-
* @param type 混流类型,详情请参见 VeLiveAudioMixType{@link #VeLiveAudioMixType}
|
|
421
|
-
* @return <br>
|
|
422
|
-
* 音频流 ID。
|
|
423
|
-
* @order 68
|
|
424
|
-
*/
|
|
425
|
-
addAudioStream(type: VeLiveAudioMixType): int;
|
|
426
|
-
/** {zh}
|
|
427
|
-
* @detail api
|
|
428
|
-
* @brief 从混流器中移除一路非主路的音频流。
|
|
429
|
-
* @order 69
|
|
430
|
-
* @param streamId 需要移除的非主路音频流 ID。
|
|
431
|
-
*/
|
|
432
|
-
removeAudioStream(streamId: int): void;
|
|
433
|
-
/** {zh}
|
|
434
|
-
* @detail api
|
|
435
|
-
* @brief 设置指定混流音频的音量。当你将 VeLiveAudioMixType{@link #VeLiveAudioMixType} 设置为 `VeLiveAudioMixPlayAndPush` 时,该方法同时控制该路音频在拉流端和本地的播放音量。
|
|
436
|
-
* @order 70
|
|
437
|
-
* @param streamId 非主路音频流 ID。
|
|
438
|
-
* @param volume 音量大小,范围为 [0.0,4.0]。
|
|
439
|
-
*/
|
|
440
|
-
setAudioStream(streamId: int, volume: float): void;
|
|
441
|
-
/** {zh}
|
|
442
|
-
* @detail api
|
|
443
|
-
* @brief 获取主路视频流 ID。
|
|
444
|
-
* @order 71
|
|
445
|
-
*/
|
|
446
|
-
getOriginVideoStream(): int;
|
|
447
|
-
/** {zh}
|
|
448
|
-
* @detail api
|
|
449
|
-
* @brief 获取主路音频流 ID。
|
|
450
|
-
* @order 72
|
|
451
|
-
*/
|
|
452
|
-
getOriginAudioStream(): int;
|
|
453
|
-
/** {zh}
|
|
454
|
-
* @detail api
|
|
455
|
-
* @brief 获取屏幕推流App音频流 ID。
|
|
456
|
-
*/
|
|
457
|
-
getAppAudioStream(): int;
|
|
458
|
-
/** {zh}
|
|
459
|
-
* @detail api
|
|
460
|
-
* @order 73
|
|
461
|
-
* @brief 发送指定混流 ID 的自定义视频帧数据。
|
|
462
|
-
* @param frame 自定义的视频帧,详情请参见 [VeLiveVideoFrame](155321#VeLiveVideoFrame)。
|
|
463
|
-
* @param streamId 需要混流的视频流 ID。
|
|
464
|
-
*/
|
|
465
|
-
sendCustomVideoFrame(frame: VeLiveVideoFrame, streamId: int): void;
|
|
466
|
-
/** {zh}
|
|
467
|
-
* @detail api
|
|
468
|
-
* @order 74
|
|
469
|
-
* @brief 发送指定混流 ID 的自定义音频帧数据。
|
|
470
|
-
* @param frame 自定义的音频帧,详情请参见 [VeLiveAudioFrame](155321#VeLiveAudioFrame)。
|
|
471
|
-
* @param streamId 混流的音频流 ID。
|
|
472
|
-
*/
|
|
473
|
-
sendCustomAudioFrame(frame: VeLiveAudioFrame, streamId: int): void;
|
|
474
|
-
/** {zh}
|
|
475
|
-
* @detail api
|
|
476
|
-
* @brief 更新音视频混流的布局。
|
|
477
|
-
* @order 75
|
|
478
|
-
* @param mixDescription 新的音视频混流布局,详情请参见 [VeLiveStreamMixDescription](155321#VeLiveStreamMixDescription)。
|
|
479
|
-
*/
|
|
480
|
-
updateStreamMixDescription(mixDescription: VeLiveStreamMixDescription): void;
|
|
481
|
-
init(): this;
|
|
482
|
-
}
|
|
483
434
|
export declare class VeLivePusher {
|
|
484
435
|
/** {zh}
|
|
485
436
|
* @detail api
|
|
486
437
|
* @brief 设置输出到控制台的日志等级。
|
|
487
|
-
* @order
|
|
438
|
+
* @order 50
|
|
488
439
|
* @param level 输出的日志级别,默认值为 `VeLivePusherLogLevelNone`,表示关闭日志。级别详情请参见 [VeLivePusherLogLevel](155321#VeLivePusherLogLevel)。
|
|
489
440
|
*/
|
|
441
|
+
|
|
490
442
|
static setLogLevel(level: VeLivePusherLogLevel): void;
|
|
491
443
|
/** {zh}
|
|
492
444
|
* @detail api
|
|
493
445
|
* @param applicationGroupIdentifier iOS app group 标识符。
|
|
494
446
|
* @brief 开启屏幕采集。
|
|
447
|
+
* @order 20
|
|
495
448
|
*/
|
|
449
|
+
|
|
496
450
|
startScreenCapture(applicationGroupIdentifier: NSString): void;
|
|
497
451
|
/** {zh}
|
|
498
452
|
* @detail api
|
|
499
|
-
* @brief
|
|
453
|
+
* @brief 停止屏幕采集。
|
|
454
|
+
* @notes <br>
|
|
455
|
+
* 该方法用于结束当前屏幕采集流程,并释放相关资源。调用本方法后,`pauseScreenCapture` 和 `resumeScreenCapture` 将不再生效。
|
|
456
|
+
* @order 21
|
|
500
457
|
*/
|
|
458
|
+
|
|
501
459
|
stopScreenCapture(): void;
|
|
460
|
+
/** {zh}
|
|
461
|
+
* @detail api
|
|
462
|
+
* @brief 暂停屏幕采集。
|
|
463
|
+
* @notes <br>
|
|
464
|
+
* 调用该方法后,屏幕采集将暂停输出数据,但不会销毁内部资源。您可通过 `resumeScreenCapture` 来恢复采集。如果当前采集已经停止或尚未开始,调用本方法不会产生任何效果。
|
|
465
|
+
* @order 22
|
|
466
|
+
*/
|
|
467
|
+
|
|
468
|
+
pauseScreenCapture(): void;
|
|
469
|
+
/** {zh}
|
|
470
|
+
* @detail api
|
|
471
|
+
* @brief 恢复屏幕采集。
|
|
472
|
+
* @notes <br>
|
|
473
|
+
* 在调用 `pauseScreenCapture` 暂停后,通过本方法可以恢复屏幕采集输出。如果屏幕采集已经停止或尚未开始,调用本方法不会产生任何效果。
|
|
474
|
+
* @order 23
|
|
475
|
+
*/
|
|
476
|
+
|
|
477
|
+
resumeScreenCapture(): void;
|
|
502
478
|
init(): this;
|
|
503
479
|
/** {zh}
|
|
504
480
|
* @detail api
|
|
505
481
|
* @brief 初始化推流器。
|
|
506
482
|
* @order 0
|
|
507
|
-
* @param config 推流配置类。详细信息请参见
|
|
483
|
+
* @param config 推流配置类。详细信息请参见 [VeLivePusherConfiguration](155321#VeLivePusherConfiguration)。
|
|
508
484
|
*/
|
|
485
|
+
|
|
509
486
|
initWithConfig(config: VeLivePusherConfiguration): this;
|
|
510
487
|
/** {zh}
|
|
511
488
|
* @detail api
|
|
512
|
-
* @brief 停止采集和推流,并销毁推流器。通常在调用 stopPush
|
|
489
|
+
* @brief 停止采集和推流,并销毁推流器。通常在调用 [stopPush](#VeLivePusher-stoppush) 结束推流后调用此方法进行清理。
|
|
513
490
|
* @order 2
|
|
514
491
|
*/
|
|
492
|
+
|
|
515
493
|
destroy(): void;
|
|
516
494
|
/** {zh}
|
|
517
495
|
* @detail api
|
|
@@ -519,9 +497,10 @@ export declare class VeLivePusher {
|
|
|
519
497
|
* @notes <br>
|
|
520
498
|
* - 需要在创建推流引擎后,调用本方法;
|
|
521
499
|
* - 重复调用本方法,仅最后一次调用生效。
|
|
522
|
-
* @order
|
|
500
|
+
* @order 4
|
|
523
501
|
* @param observer 推流器回调对象,详细信息请参见 [VeLivePusherObserver](155319#VeLivePusherObserver)。
|
|
524
502
|
*/
|
|
503
|
+
|
|
525
504
|
setObserver(observer: id<VeLivePusherObserver>): void;
|
|
526
505
|
/** {zh}
|
|
527
506
|
* @detail api
|
|
@@ -529,200 +508,222 @@ export declare class VeLivePusher {
|
|
|
529
508
|
* @notes <br>
|
|
530
509
|
* - 需要在创建推流引擎后,调用本方法;
|
|
531
510
|
* - 重复调用本方法,仅最后一次调用生效。
|
|
532
|
-
* @order
|
|
511
|
+
* @order 6
|
|
533
512
|
* @param observer 推流器周期性回调对象,详细信息请参见 [VeLivePusherStatisticsObserver](155319#VeLivePusherStatisticsObserver)。
|
|
534
513
|
* @param interval 周期性回调的时间间隔,单位为 s,默认值为 5。
|
|
535
514
|
*/
|
|
515
|
+
|
|
536
516
|
setStatisticsObserver(observer: id<VeLivePusherStatisticsObserver>, interval: int): void;
|
|
537
517
|
/** {zh}
|
|
538
518
|
* @detail api
|
|
539
519
|
* @brief 添加视频帧的监听回调,用于获取推流器输出的视频帧。
|
|
520
|
+
* @order 51
|
|
521
|
+
* @param listener 视频帧的监听回调,详细信息请参见 [VeLiveVideoFrameListener](155319#VeLiveVideoFrameListener)。
|
|
540
522
|
* @return <br>
|
|
541
523
|
* - 0:成功;
|
|
542
524
|
* - ≠0:失败。
|
|
543
|
-
* @order 4
|
|
544
|
-
* @param listener 视频帧的监听回调,详细信息请参见 [VeLiveVideoFrameListener](155319#VeLiveVideoFrameListener)。
|
|
545
525
|
*/
|
|
526
|
+
|
|
546
527
|
addVideoFrameListener(listener: id<VeLiveVideoFrameListener>): int;
|
|
547
528
|
/** {zh}
|
|
548
529
|
* @detail api
|
|
549
530
|
* @brief 移除已添加的视频帧监听回调。
|
|
550
|
-
* @return <br>
|
|
551
|
-
* - 0:成功;
|
|
552
|
-
* - <0:失败。
|
|
553
531
|
* @notes <br>
|
|
554
532
|
* 如果没有添加过此监听回调或者监听回调已被移除,调用此方法将返回失败。
|
|
555
|
-
* @order
|
|
533
|
+
* @order 52
|
|
556
534
|
* @param listener 视频帧的监听回调,详细信息请参见 [VeLiveVideoFrameListener](155319#VeLiveVideoFrameListener)。
|
|
535
|
+
* @return <br>
|
|
536
|
+
* - 0:成功;
|
|
537
|
+
* - <0:失败。
|
|
557
538
|
*/
|
|
539
|
+
|
|
558
540
|
removeVideoFrameListener(listener: id<VeLiveVideoFrameListener>): int;
|
|
559
541
|
/** {zh}
|
|
560
542
|
* @detail api
|
|
561
543
|
* @brief 添加音频帧的监听回调,用于获取推流器输出的音频帧。
|
|
544
|
+
* @order 53
|
|
545
|
+
* @param listener 音频帧监听回调,详细信息请参见 [VeLiveAudioFrameListener](155319#VeLiveAudioFrameListener)。
|
|
562
546
|
* @return <br>
|
|
563
547
|
* - 0:成功;
|
|
564
548
|
* - <0:失败。
|
|
565
|
-
* @order 6
|
|
566
|
-
* @param listener 音频帧监听回调,详细信息请参见 [VeLiveAudioFrameListener](155319#VeLiveAudioFrameListener)。
|
|
567
549
|
*/
|
|
550
|
+
|
|
568
551
|
addAudioFrameListener(listener: id<VeLiveAudioFrameListener>): int;
|
|
569
552
|
/** {zh}
|
|
570
553
|
* @detail api
|
|
571
554
|
* @brief 移除已添加的音频帧监听回调。
|
|
572
|
-
* @return <br>
|
|
573
|
-
* - 0:成功;
|
|
574
|
-
* - <0:失败。
|
|
575
555
|
* @notes <br>
|
|
576
556
|
* 如果没有添加过此监听回调或者监听回调已被移除,调用此方法将返回失败。
|
|
577
|
-
* @order
|
|
557
|
+
* @order 54
|
|
578
558
|
* @param listener 音频帧的监听回调,详细信息请参见 [VeLiveAudioFrameListener](155319#VeLiveAudioFrameListener)。
|
|
559
|
+
* @return <br>
|
|
560
|
+
* - 0:成功;
|
|
561
|
+
* - <0:失败。
|
|
579
562
|
*/
|
|
563
|
+
|
|
580
564
|
removeAudioFrameListener(listener: id<VeLiveAudioFrameListener>): int;
|
|
581
565
|
/** {zh}
|
|
582
566
|
* @detail api
|
|
583
567
|
* @brief 添加屏幕采集的监听。
|
|
584
|
-
* @return <br>
|
|
585
|
-
* - 0:成功;
|
|
586
|
-
* - <0:失败。
|
|
587
568
|
* @notes <br>
|
|
588
569
|
* 如果没有添加过此监听回调或者监听回调已被移除,调用此方法将返回失败。
|
|
589
570
|
* @param listener 屏幕采集事件监听回调,详细信息请参见 VeLiveScreenCaptureStatusObserver{@link #VeLiveScreenCaptureStatusObserver}
|
|
590
571
|
* @param observer 录屏推流事件监听器。详情见 [VeLiveScreenCaptureStatusObserver](155319#VeLiveScreenCaptureStatusObserver)。
|
|
572
|
+
* @order 5
|
|
573
|
+
* @return <br>
|
|
574
|
+
* - 0:成功;
|
|
575
|
+
* - <0:失败。
|
|
591
576
|
*/
|
|
577
|
+
|
|
592
578
|
setScreenCaptureObserver(observer: id<VeLiveScreenCaptureStatusObserver>): int;
|
|
593
579
|
/** {zh}
|
|
594
580
|
* @detail api
|
|
595
581
|
* @brief 设置本地预览视图。如您对采集到的画面进行了美颜等处理,View 中显示的是美颜后的画面。
|
|
596
|
-
* @order
|
|
582
|
+
* @order 7
|
|
597
583
|
* @param view 本地预览视图。
|
|
598
584
|
*/
|
|
585
|
+
|
|
599
586
|
setRenderView(view: UIView): Promise<void>;
|
|
600
587
|
/** {zh}
|
|
601
588
|
* @detail api
|
|
602
|
-
* @order
|
|
589
|
+
* @order 10
|
|
603
590
|
* @brief 设置本地预览填充模式。
|
|
604
591
|
* @param fillMode 本地预览填充模式,默认值为 VeLivePusherRenderModeFill,即视频帧自适应画布的填充模式,详细信息请参见 [VeLivePusherRenderMode](155321#VeLivePusherRenderMode)。
|
|
605
592
|
*/
|
|
593
|
+
|
|
606
594
|
setRenderFillMode(fillMode: VeLivePusherRenderMode): void;
|
|
607
595
|
/** {zh}
|
|
608
596
|
* @detail api
|
|
609
|
-
* @brief
|
|
610
|
-
* @
|
|
611
|
-
* 该方法可用于配置预览和推流画面是否镜像。
|
|
612
|
-
* @order 9
|
|
597
|
+
* @brief 开启/关闭镜像。该方法可用于配置预览和推流画面是否镜像。
|
|
598
|
+
* @order 8
|
|
613
599
|
* @param type 镜像类型,详细信息请参见 [VeLiveVideoMirrorType](155321#VeLiveVideoMirrorType)。
|
|
614
600
|
* @param enable 是否开启镜像。<br>
|
|
615
601
|
* - YES:开启;
|
|
616
602
|
* - NO:关闭。
|
|
617
603
|
*/
|
|
604
|
+
|
|
618
605
|
setVideoMirror(type: VeLiveVideoMirrorType, enable: BOOL): void;
|
|
619
606
|
/** {zh}
|
|
620
607
|
* @detail api
|
|
621
608
|
* @brief 开始推流。
|
|
622
|
-
* @order
|
|
609
|
+
* @order 24
|
|
623
610
|
* @param url 推流地址,用于将直播流推送到目标服务器。
|
|
624
611
|
*/
|
|
612
|
+
|
|
625
613
|
startPush(url: NSString): void;
|
|
626
614
|
/** {zh}
|
|
627
615
|
* @detail api
|
|
628
616
|
* @brief 开始推流,支持备用推流地址。
|
|
629
617
|
* @notes <br>
|
|
630
618
|
* 当数组中第一个推流地址不可用时,会自动切换到后面的备用推流地址继续推流。
|
|
631
|
-
* @order
|
|
619
|
+
* @order 25
|
|
632
620
|
* @param urls 推流地址列表,包含一个或多个推流地址。
|
|
633
621
|
*/
|
|
622
|
+
|
|
634
623
|
startPushWithUrls(urls: NSArray<NSString>): void;
|
|
635
624
|
/** {zh}
|
|
636
625
|
* @detail api
|
|
637
626
|
* @brief 停止推流。
|
|
638
|
-
* @notes
|
|
639
|
-
*
|
|
640
|
-
* @order
|
|
627
|
+
* @notes
|
|
628
|
+
* 停止推流后,可以通过调用 [startPush:](#VeLivePusher-startpush) 或 [startPushWithUrls:](#VeLivePusher-startpushwithurls) 方法重新开始推流。
|
|
629
|
+
* @order 26
|
|
641
630
|
*/
|
|
631
|
+
|
|
642
632
|
stopPush(): void;
|
|
643
633
|
/** {zh}
|
|
644
634
|
* @detail api
|
|
645
635
|
* @brief 当前是否正在推流中,可用来查询推流器的当前状态。
|
|
636
|
+
* @order 27
|
|
646
637
|
* @return <br>
|
|
647
638
|
* 是否正在推流。<br>
|
|
648
639
|
* - YES:正在推流中;
|
|
649
640
|
* - NO:已经停止推流。
|
|
650
|
-
* @order 13
|
|
651
641
|
*/
|
|
642
|
+
|
|
652
643
|
isPushing(): BOOL;
|
|
653
644
|
/** {zh}
|
|
654
645
|
* @detail api
|
|
655
646
|
* @brief 开始视频采集。
|
|
656
|
-
* @notes
|
|
657
|
-
*
|
|
658
|
-
* @order
|
|
647
|
+
* @notes
|
|
648
|
+
* 调用该接口后,可以通过调用接口 [stopVideoCapture](#VeLivePusher-stopvideocapture) 停止视频采集。
|
|
649
|
+
* @order 11
|
|
659
650
|
* @param type 视频采集类型,详细信息请参见 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType)。
|
|
660
651
|
*/
|
|
652
|
+
|
|
661
653
|
startVideoCapture(type: VeLiveVideoCaptureType): void;
|
|
662
654
|
/** {zh}
|
|
663
655
|
* @detail api
|
|
664
656
|
* @brief 停止视频采集。
|
|
665
|
-
* @notes
|
|
666
|
-
*
|
|
657
|
+
* @notes
|
|
658
|
+
* 调用该接口后,可以通过调用接口 [startVideoCapture:](#VeLivePusher-startvideocapture) 开始视频采集。
|
|
659
|
+
* @order 12
|
|
667
660
|
*/
|
|
661
|
+
|
|
668
662
|
stopVideoCapture(): void;
|
|
669
663
|
/** {zh}
|
|
670
664
|
* @detail api
|
|
671
665
|
* @brief 切换视频采集类型。
|
|
672
|
-
* @notes
|
|
673
|
-
*
|
|
666
|
+
* @notes
|
|
667
|
+
* 该接口必须在调用接口 [startVideoCapture:](#VeLivePusher-startvideocapture) 后调用才能生效。
|
|
668
|
+
* @order 13
|
|
674
669
|
* @param type 视频采集类型,详细信息请参见 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType)。
|
|
675
670
|
*/
|
|
671
|
+
|
|
676
672
|
switchVideoCapture(type: VeLiveVideoCaptureType): void;
|
|
677
673
|
/** {zh}
|
|
678
674
|
* @detail api
|
|
679
675
|
* @brief 开始音频采集。
|
|
680
|
-
* @notes
|
|
681
|
-
*
|
|
682
|
-
* @order
|
|
676
|
+
* @notes
|
|
677
|
+
* 调用该接口后,可以通过调用接口 [[stopAudioCapture](#VeLivePusher-stopaudiocapture) 停止音频采集。
|
|
678
|
+
* @order 15
|
|
683
679
|
* @param type 音频采集类型,详细信息请参见 [VeLiveAudioCaptureType](155321#VeLiveAudioCaptureType)。
|
|
684
680
|
*/
|
|
681
|
+
|
|
685
682
|
startAudioCapture(type: VeLiveAudioCaptureType): void;
|
|
686
683
|
/** {zh}
|
|
687
684
|
* @detail api
|
|
688
685
|
* @brief 停止音频采集。
|
|
689
|
-
* @notes
|
|
690
|
-
*
|
|
691
|
-
* @order
|
|
686
|
+
* @notes
|
|
687
|
+
* 调用该接口后,可以通过调用接口 [startAudioCapture:](#VeLivePusher-startaudiocapture) 开始音频采集。
|
|
688
|
+
* @order 16
|
|
692
689
|
*/
|
|
690
|
+
|
|
693
691
|
stopAudioCapture(): void;
|
|
694
692
|
/** {zh}
|
|
695
693
|
* @detail api
|
|
696
694
|
* @brief 切换音频采集类型。
|
|
697
|
-
* @notes
|
|
698
|
-
*
|
|
699
|
-
* @order
|
|
695
|
+
* @notes
|
|
696
|
+
* 该接口必须在调用接口 [startAudioCapture:](#VeLivePusher-startaudiocapture) 后调用才能生效。
|
|
697
|
+
* @order 17
|
|
700
698
|
* @param type 音频采集类型,详细信息请参见 [VeLiveAudioCaptureType](155321#VeLiveAudioCaptureType)。
|
|
701
699
|
*/
|
|
700
|
+
|
|
702
701
|
switchAudioCapture(type: VeLiveAudioCaptureType): void;
|
|
703
702
|
/** {zh}
|
|
704
703
|
* @detail api
|
|
705
704
|
* @brief 获取当前视频采集类型。
|
|
705
|
+
* @order 14
|
|
706
706
|
* @return <br>
|
|
707
707
|
* 视频采集类型,详细信息请参见 VeLiveVideoCaptureType{@link #VeLiveVideoCaptureType}。
|
|
708
|
-
* @order 20
|
|
709
708
|
*/
|
|
709
|
+
|
|
710
710
|
getCurrentVideoCaptureType(): VeLiveVideoCaptureType;
|
|
711
711
|
/** {zh}
|
|
712
712
|
* @detail api
|
|
713
713
|
* @brief 获取当前音频采集类型。
|
|
714
|
+
* @order 18
|
|
714
715
|
* @return <br>
|
|
715
716
|
* 音频采集类型,详细信息请参见 VeLiveAudioCaptureType{@link #VeLiveAudioCaptureType}。
|
|
716
|
-
* @order 21
|
|
717
717
|
*/
|
|
718
|
+
|
|
718
719
|
getCurrentAudioCaptureType(): VeLiveAudioCaptureType;
|
|
719
720
|
/** {zh}
|
|
720
721
|
* @detail api
|
|
721
|
-
* @brief
|
|
722
|
-
* @
|
|
723
|
-
* @order 25
|
|
722
|
+
* @brief 自定义静态图,适用于静态图推流采集类型。使用该接口时,需要将视频采集类型设置为 VeLiveVideoCaptureCustomImage,您可调用 [startVideoCapture:](#VeLivePusher-startvideocapture) 方法,将 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 设置为 VeLiveVideoCaptureCustomImage。
|
|
723
|
+
* @order 19
|
|
724
724
|
* @param image 静态图片,用于在静态图推流采集类型下设置静态图。
|
|
725
725
|
*/
|
|
726
|
+
|
|
726
727
|
updateCustomImage(image: UIImage): Promise<void>;
|
|
727
728
|
/** {zh}
|
|
728
729
|
* @detail api
|
|
@@ -730,51 +731,58 @@ export declare class VeLivePusher {
|
|
|
730
731
|
* @param mute 是否设置为静音。默认为 NO。<br>
|
|
731
732
|
* - YES:静音推流;
|
|
732
733
|
* - NO:正常推流。
|
|
733
|
-
* @order
|
|
734
|
+
* @order 22
|
|
734
735
|
*/
|
|
736
|
+
|
|
735
737
|
setMute(mute: BOOL): void;
|
|
736
738
|
/** {zh}
|
|
737
739
|
* @detail api
|
|
738
740
|
* @brief 当前是否是静音状态。
|
|
741
|
+
* @order 23
|
|
739
742
|
* @return <br>
|
|
740
743
|
* - YES:当前是静音状态;
|
|
741
744
|
* - NO:当前非静音状态。
|
|
742
|
-
* @order 24
|
|
743
745
|
*/
|
|
746
|
+
|
|
744
747
|
isMute(): BOOL;
|
|
745
748
|
/** {zh}
|
|
746
749
|
* @detail api
|
|
747
750
|
* @brief 设置推流视频编码参数。
|
|
748
751
|
* @notes <br>
|
|
749
752
|
* 该接口可在推流开始前或开始后调用。
|
|
750
|
-
* @order
|
|
753
|
+
* @order 29
|
|
751
754
|
* @param config 推流视频参数,支持设置推流视频分辨率、编码格式、目标码率和视频 GOP 大小等信息。详情请参见 [VeLiveVideoEncoderConfiguration](155321#VeLiveVideoEncoderConfiguration)。
|
|
752
755
|
*/
|
|
756
|
+
|
|
753
757
|
setVideoEncoderConfiguration(config: VeLiveVideoEncoderConfiguration): void;
|
|
754
758
|
/** {zh}
|
|
755
759
|
* @detail api
|
|
756
760
|
* @brief 设置推流音频编码参数。
|
|
757
|
-
* @notes
|
|
758
|
-
*
|
|
759
|
-
* @order
|
|
761
|
+
* @notes
|
|
762
|
+
* 该接口需要在 [startPush:](#VeLivePusher-startpush) 或 [startPushWithUrls:](#VeLivePusher-startpushwithurls) 方法之前调用。
|
|
763
|
+
* @order 28
|
|
760
764
|
* @param config 推流音频编码参数,详情请参见 [VeLiveAudioEncoderConfiguration](155321#VeLiveAudioEncoderConfiguration)。
|
|
761
765
|
*/
|
|
766
|
+
|
|
762
767
|
setAudioEncoderConfiguration(config: VeLiveAudioEncoderConfiguration): void;
|
|
763
768
|
/** {zh}
|
|
764
769
|
* @detail api
|
|
765
770
|
* @brief 开始本地文件录制。
|
|
766
|
-
* @order
|
|
771
|
+
* @order 44
|
|
767
772
|
* @param path 录制文件保存路径,不能为空。
|
|
768
773
|
* @param config 文件录制设置,详情请参见 [VeLiveFileRecorderConfiguration](155321#VeLiveFileRecorderConfiguration)。
|
|
769
774
|
* @param listener 本地文件录制的监听,详情请参见 [VeLiveFileRecordingListener](155319#VeLiveFileRecordingListener)。
|
|
770
775
|
*/
|
|
776
|
+
|
|
771
777
|
startFileRecording(path: NSString, config: VeLiveFileRecorderConfiguration, listener: id<VeLiveFileRecordingListener>): void;
|
|
772
778
|
/** {zh}
|
|
773
779
|
* @detail api
|
|
774
780
|
* @brief 停止本地文件录制。
|
|
775
|
-
* @notes
|
|
776
|
-
*
|
|
781
|
+
* @notes
|
|
782
|
+
* 该接口需要在 [startFileRecording](#VeLivePusher-startfilerecording-config-listener) 方法之后调用。
|
|
783
|
+
* @order 46
|
|
777
784
|
*/
|
|
785
|
+
|
|
778
786
|
stopFileRecording(): void;
|
|
779
787
|
/** {zh}
|
|
780
788
|
* @detail api
|
|
@@ -782,30 +790,25 @@ export declare class VeLivePusher {
|
|
|
782
790
|
* - 控制闪光灯开关
|
|
783
791
|
* - 设置摄像头缩放比例
|
|
784
792
|
* - 设置自动对焦
|
|
785
|
-
* @
|
|
786
|
-
*
|
|
787
|
-
* @notes <br>该接口需要在 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureFrontCamera 或 VeLiveVideoCaptureBackCamera。
|
|
793
|
+
* @notes
|
|
794
|
+
* 该接口需要在 [startVideoCapture:](#VeLivePusher-startvideocapture) 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureFrontCamera 或 VeLiveVideoCaptureBackCamera。
|
|
788
795
|
* @order 32
|
|
796
|
+
* @return
|
|
797
|
+
* 相机设备管理对象 [VeLiveCameraDevice](#VeLiveCameraDevice)。
|
|
789
798
|
*/
|
|
799
|
+
|
|
790
800
|
getCameraDevice(): VeLiveCameraDevice;
|
|
791
801
|
/** {zh}
|
|
792
802
|
* @detail api
|
|
793
803
|
* @brief 获取音频模块管理对象。
|
|
794
|
-
* @
|
|
795
|
-
*
|
|
796
|
-
* @notes <br>
|
|
797
|
-
* 该接口需要在 startAudioCapture:{@link #VeLivePusher#startAudioCapture} 方法中设置 VeLiveAudioCaptureType{@link #VeLiveAudioCaptureType} 为 VeLiveAudioCaptureMicrophone。
|
|
804
|
+
* @notes
|
|
805
|
+
* 该接口需要在 [startAudioCapture:](#VeLivePusher-startaudiocapture) 方法中设置 [VeLiveAudioCaptureType](155321#VeLiveAudioCaptureType) 为 VeLiveAudioCaptureMicrophone。
|
|
798
806
|
* @order 33
|
|
807
|
+
* @return
|
|
808
|
+
* 音频模块管理对象 [VeLiveAudioDevice](#VeLiveAudioDevice)。
|
|
799
809
|
*/
|
|
810
|
+
|
|
800
811
|
getAudioDevice(): VeLiveAudioDevice;
|
|
801
|
-
/** {zh}
|
|
802
|
-
* @detail api
|
|
803
|
-
* @brief 获取混流管理对象。
|
|
804
|
-
* @return <br>
|
|
805
|
-
* 混流管理对象 VeLiveMixerManager{@link #VeLiveMixerManager}。
|
|
806
|
-
* @order 31
|
|
807
|
-
*/
|
|
808
|
-
getMixerManager(): VeLiveMixerManager;
|
|
809
812
|
/** {zh}
|
|
810
813
|
* @detail api
|
|
811
814
|
* @brief 获取视频特效管理对象 `VeLiveVideoEffectManager`。通过视频特效管理,您可以使用以下功能。
|
|
@@ -814,70 +817,75 @@ export declare class VeLivePusher {
|
|
|
814
817
|
* - 设置素材
|
|
815
818
|
* - 设置贴纸
|
|
816
819
|
* - 设置滤镜
|
|
817
|
-
* @
|
|
818
|
-
*
|
|
819
|
-
* @
|
|
820
|
-
*
|
|
821
|
-
*
|
|
820
|
+
* @notes
|
|
821
|
+
* 该接口需要集成智能美化特效 SDK 后才能使用。
|
|
822
|
+
* @order 31
|
|
823
|
+
* @return
|
|
824
|
+
* 视频特效管理对象 [VeLiveVideoEffectManager](#VeLiveVideoEffectManager)。
|
|
822
825
|
*/
|
|
826
|
+
|
|
823
827
|
getVideoEffectManager(): VeLiveVideoEffectManager;
|
|
824
828
|
/** {zh}
|
|
825
829
|
* @detail api
|
|
826
830
|
* @brief 创建播放器。
|
|
827
|
-
* @
|
|
828
|
-
*
|
|
829
|
-
*
|
|
831
|
+
* @order 3
|
|
832
|
+
* @return
|
|
833
|
+
* 播放器管理对象 [VeLiveMediaPlayer](#VeLiveMediaPlayer)。
|
|
830
834
|
*/
|
|
835
|
+
|
|
831
836
|
createPlayer(): VeLiveMediaPlayer;
|
|
832
837
|
/** {zh}
|
|
833
838
|
* @detail api
|
|
834
839
|
* @brief 自定义视频处理。
|
|
835
840
|
* @param filter 视频帧滤镜对象 VeLiveVideoFrameFilter{@link #VeLiveVideoFrameFilter}。
|
|
836
|
-
* @order
|
|
841
|
+
* @order 36
|
|
837
842
|
*/
|
|
843
|
+
|
|
838
844
|
setVideoFrameFilter(filter: id<VeLiveVideoFrameFilter>): void;
|
|
839
845
|
/** {zh}
|
|
840
846
|
* @detail api
|
|
841
847
|
* @brief 自定义音频处理。
|
|
842
848
|
* @param filter 音频帧滤镜对象 VeLiveAudioFrameFilter{@link #VeLiveAudioFrameFilter}。
|
|
843
|
-
* @order
|
|
849
|
+
* @order 40
|
|
844
850
|
*/
|
|
851
|
+
|
|
845
852
|
setAudioFrameFilter(filter: id<VeLiveAudioFrameFilter>): void;
|
|
846
853
|
/** {zh}
|
|
847
854
|
* @detail api
|
|
848
855
|
* @brief 设置推流视频帧朝向。默认为竖屏推流。
|
|
849
856
|
* @param orientation 视频帧朝向。
|
|
857
|
+
* @order 9
|
|
850
858
|
*/
|
|
859
|
+
|
|
851
860
|
setOrientation(orientation: UIInterfaceOrientation): void;
|
|
852
861
|
/** {zh}
|
|
853
862
|
* @detail api
|
|
854
863
|
* @brief 设置推流水印。
|
|
855
|
-
* @
|
|
856
|
-
* - 0:水印设置成功;
|
|
857
|
-
* - <0:水印设置失败。
|
|
858
|
-
* @order 37
|
|
864
|
+
* @order 35
|
|
859
865
|
* @param image 水印图片。取值为 null 时,表示禁用水印。
|
|
860
866
|
* @param x 水印的水平偏移量,即水印图片相对视频流左上角的横向偏移与视频流宽度的比值,取值范围为 [0.0,1.0]。
|
|
861
867
|
* @param y 水印的垂直偏移量,即水印图片相对视频流左上角的纵向偏移与视频流高度的比值,取值范围为 [0.0,1.0]。
|
|
862
868
|
* @param scale 水印图片的缩放比例,取值范围为 [0.0,1.0]。
|
|
869
|
+
* @return <br>
|
|
870
|
+
* - 0:水印设置成功;
|
|
871
|
+
* - <0:水印设置失败。
|
|
863
872
|
*/
|
|
873
|
+
|
|
864
874
|
setWatermark(image: UIImage, x: float, y: float, scale: float): Promise<int>;
|
|
865
875
|
/** {zh}
|
|
866
876
|
* @detail api
|
|
867
877
|
* @brief 视频截图。
|
|
868
|
-
* @order
|
|
878
|
+
* @order 34
|
|
869
879
|
* @param listener 截图监听对象,详情请参见 [VeLiveSnapshotListener](155319#VeLiveSnapshotListener)。
|
|
870
880
|
*/
|
|
881
|
+
|
|
871
882
|
snapshot(listener: id<VeLiveSnapshotListener>): void;
|
|
872
883
|
/** {zh}
|
|
873
884
|
* @detail api
|
|
874
885
|
* @brief 通过视频帧发送 SEI 消息。
|
|
875
|
-
* @
|
|
876
|
-
*
|
|
877
|
-
*
|
|
878
|
-
* @notes <br>
|
|
879
|
-
* 该接口需要在调用 startPush:{@link #VeLivePusher#startPush} 或 startPushWithUrls:{@link #VeLivePusher#startPushWithUrls} 方法之后调用。
|
|
880
|
-
* @order 42
|
|
886
|
+
* @notes
|
|
887
|
+
* 该接口需要在调用 [startPush:](#VeLivePusher-startpush) 或 [startPushWithUrls:](#VeLivePusher-startpushwithurls) 方法之后调用。
|
|
888
|
+
* @order 41
|
|
881
889
|
* @param key SEI 消息为 JSON 格式的字符串。此参数为 JSON 结构中的 Key。
|
|
882
890
|
* @param value SEI 消息为 JSON 格式的字符串。此参数为 JSON 结构中的 Value。
|
|
883
891
|
* @param repeat 消息发送重复的次数。例如,`repeat` 取值为 20,`isKeyFrame` 取值为 YES,则会在调用该方法后连续 20 个关键帧中添加 SEI 消息。
|
|
@@ -887,210 +895,231 @@ export declare class VeLivePusher {
|
|
|
887
895
|
* @param allowsCovered 是否允许覆盖。<br>
|
|
888
896
|
* - YES:允许;
|
|
889
897
|
* - NO:不允许。
|
|
898
|
+
* @return <br>
|
|
899
|
+
* - 0:成功;
|
|
900
|
+
* - <0:失败。
|
|
890
901
|
*/
|
|
902
|
+
|
|
891
903
|
sendSeiMessage(key: NSString, value: id, repeat: int, isKeyFrame: BOOL, allowsCovered: BOOL): int;
|
|
892
904
|
/** {zh}
|
|
893
905
|
* @detail api
|
|
894
906
|
* @brief 推送外部视频帧数据。
|
|
907
|
+
* @notes
|
|
908
|
+
* 该接口需要在 [startVideoCapture:](#VeLivePusher-startvideocapture) 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureExternal。
|
|
909
|
+
* @order 37
|
|
910
|
+
* @param frame 视频帧的数据信息,详情请参见 [VeLiveVideoFrame](155321#VeLiveVideoFrame)。
|
|
895
911
|
* @return <br>
|
|
896
912
|
* - 0:成功;
|
|
897
913
|
* - <0:失败。
|
|
898
|
-
* @notes <br>该接口需要在 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureExternal。
|
|
899
|
-
* @order 43
|
|
900
|
-
* @param frame 视频帧的数据信息,详情请参见 [VeLiveVideoFrame](155321#VeLiveVideoFrame)。
|
|
901
914
|
*/
|
|
915
|
+
|
|
902
916
|
pushExternalVideoFrame(frame: VeLiveVideoFrame): int;
|
|
903
917
|
/** {zh}
|
|
904
918
|
* @detail api
|
|
905
919
|
* @brief 推送外部视频编码数据。
|
|
920
|
+
* @notes
|
|
921
|
+
* 该接口需要在 [startVideoCapture:](#VeLivePusher-startvideocapture) 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureFrontCamera 或 VeLiveVideoCaptureExternal。
|
|
922
|
+
* @order 38
|
|
923
|
+
* @param encodeFrame 视频编码帧的数据信息,详情请参见 [VeLiveVideoEncodeFrame](155321#VeLiveVideoEncodeFrame)。
|
|
906
924
|
* @return <br>
|
|
907
925
|
* - 0:成功;
|
|
908
926
|
* - <0:失败。
|
|
909
|
-
* @notes <br>该接口需要在 startVideoCapture:{@link #VeLivePusher#startVideoCapture} 方法中设置 [VeLiveVideoCaptureType](155321#VeLiveVideoCaptureType) 为 VeLiveVideoCaptureFrontCamera 或 VeLiveVideoCaptureExternal。
|
|
910
|
-
* @order 44
|
|
911
|
-
* @param encodeFrame 视频编码帧的数据信息,详情请参见 [VeLiveVideoEncodeFrame](155321#VeLiveVideoEncodeFrame)。
|
|
912
927
|
*/
|
|
928
|
+
|
|
913
929
|
pushExternalVideoEncodeFrame(encodeFrame: VeLiveVideoEncodeFrame): int;
|
|
914
930
|
/** {zh}
|
|
915
931
|
* @detail api
|
|
916
932
|
* @brief 推送外部音频帧数据。
|
|
933
|
+
* @notes
|
|
934
|
+
* 该接口需要在 [startAudioCapture:](#VeLivePusher-startaudiocapture) 方法中设置 [VeLiveAudioCaptureType](155321#VeLiveAudioCaptureType) 为 VeLiveAudioCaptureExternal。
|
|
935
|
+
* @order 39
|
|
936
|
+
* @param frame 外部音频数据。详情请参见 [VeLiveAudioFrame](155321#VeLiveAudioFrame)。
|
|
917
937
|
* @return <br>
|
|
918
938
|
* - 0:成功;
|
|
919
939
|
* - <0:失败。
|
|
920
|
-
* @notes <br>
|
|
921
|
-
* 该接口需要在 startAudioCapture:{@link #VeLivePusher#startAudioCapture} 方法中设置 VeLiveAudioCaptureType{@link #VeLiveAudioCaptureType} 为 VeLiveAudioCaptureExternal。
|
|
922
|
-
* @order 45
|
|
923
|
-
* @param frame 外部音频数据。详情请参见 [VeLiveAudioFrame](155321#VeLiveAudioFrame)。
|
|
924
940
|
*/
|
|
941
|
+
|
|
925
942
|
pushExternalAudioFrame(frame: VeLiveAudioFrame): int;
|
|
926
943
|
/** {zh}
|
|
927
944
|
* @detail api
|
|
928
|
-
* @brief
|
|
945
|
+
* @brief 高级配置。您可通过提交工单联系[技术支持](https://console.volcengine.com/workorder/create?step=3&SubProductID=P00000076),了解配置方法。
|
|
946
|
+
* @order 42
|
|
947
|
+
* @param key 推流高级配置为 JSON 格式的字符串,此参数为 JSON 结构中的 Key。
|
|
948
|
+
* @param value 推流高级配置为 JSON 格式的字符串,此参数为 JSON 结构中的 Value。建议传入 NSDictionary 或者 NSString 对象。
|
|
929
949
|
* @return <br>
|
|
930
950
|
* - 0:成功;
|
|
931
951
|
* - -1:失败,参数错误。
|
|
932
|
-
* @order 43
|
|
933
|
-
* @param key 推流高级配置为 JSON 格式的字符串,此参数为 JSON 结构中的 Key。您可通过提交工单联系[技术支持](https://console.volcengine.com/workorder/create?step=3&SubProductID=P00000076&FlowKey=iNcpuNlwBHbovcjeWlKP),了解配置方法。
|
|
934
|
-
* @param value 推流高级配置为 JSON 格式的字符串,此参数为 JSON 结构中的 Value。建议传入 NSDictionary 或者 NSString 对象。您可通过提交工单联系[技术支持](https://console.volcengine.com/workorder/create?step=3&SubProductID=P00000076&FlowKey=iNcpuNlwBHbovcjeWlKP),了解配置方法。
|
|
935
952
|
*/
|
|
953
|
+
|
|
936
954
|
setProperty(key: NSString, value: id): int;
|
|
937
955
|
/** {zh}
|
|
938
956
|
* @detail api
|
|
939
957
|
* @brief 强制请求 IDR 帧,发起请求以编码一个新的 IDR 帧。
|
|
940
|
-
* @notes
|
|
941
|
-
*
|
|
942
|
-
* @order
|
|
958
|
+
* @notes
|
|
959
|
+
* 该接口需要在调用 [startPush:](#VeLivePusher-startpush) 或 [startPushWithUrls:](#VeLivePusher-startpushwithurls) 方法之后调用。
|
|
960
|
+
* @order 49
|
|
943
961
|
*/
|
|
962
|
+
|
|
944
963
|
requestIDRFrame(): void;
|
|
945
964
|
}
|
|
946
965
|
export declare class VeLiveVideoEffectManager {
|
|
947
966
|
/** {zh}
|
|
948
967
|
* @detail api
|
|
949
968
|
* @brief 视频特效许可证配置,用于初始化视频特效管理对象。
|
|
969
|
+
* @order 2
|
|
970
|
+
* @param config 特效初始化配置,详情请参见 [VeLiveVideoEffectLicenseConfiguration](155321#VeLiveVideoEffectLicenseConfiguration)。
|
|
950
971
|
* @return <br>
|
|
951
972
|
* - 0:调用成功;
|
|
952
973
|
* - -1:调用失败。
|
|
953
|
-
* @order 76
|
|
954
|
-
* @param config 特效初始化配置,详情请参见 [VeLiveVideoEffectLicenseConfiguration](155321#VeLiveVideoEffectLicenseConfiguration)。
|
|
955
974
|
*/
|
|
975
|
+
|
|
956
976
|
setupWithConfig(config: VeLiveVideoEffectLicenseConfiguration): int;
|
|
957
977
|
/** {zh}
|
|
958
978
|
* @detail api
|
|
959
|
-
* @brief
|
|
960
|
-
* @notes
|
|
961
|
-
*
|
|
962
|
-
*
|
|
963
|
-
*
|
|
964
|
-
* @order 76
|
|
979
|
+
* @brief 在许可证过期后,可调用该方法更新 License,本方法仅对在线 License 有效。
|
|
980
|
+
* @notes
|
|
981
|
+
* - 需要通过调用 [setupWithConfig:](155318#VeLiveVideoEffectManager-setupwithconfig) 设置视频特效许可证后调用;
|
|
982
|
+
* - 本方法为异步操作。
|
|
983
|
+
* @order 3
|
|
965
984
|
* @param completion 结果回调信息。
|
|
966
985
|
*/
|
|
986
|
+
|
|
967
987
|
updateLicense(completion: (result: number, message: string) => void): void;
|
|
968
988
|
/** {zh}
|
|
969
989
|
* @detail api
|
|
970
990
|
* @brief 设置特效算法模型包的路径。
|
|
971
|
-
* @return <br>
|
|
972
|
-
* - 0:调用成功;
|
|
973
|
-
* - -1:调用失败。
|
|
974
991
|
* @notes <br>
|
|
975
992
|
* 需要通过调用 setupWithConfig:{@link #VeLiveVideoEffectManager#setupWithConfig} 设置视频特效许可证后调用。
|
|
976
|
-
* @order
|
|
993
|
+
* @order 4
|
|
977
994
|
* @param path 特效算法模型包的路径。
|
|
995
|
+
* @return <br>
|
|
996
|
+
* - 0:调用成功;
|
|
997
|
+
* - -1:调用失败。
|
|
978
998
|
*/
|
|
999
|
+
|
|
979
1000
|
setAlgoModelPath(path: NSString): int;
|
|
980
1001
|
/** {zh}
|
|
981
1002
|
* @detail api
|
|
982
1003
|
* @brief 创建/销毁特效引擎。
|
|
983
|
-
* @
|
|
984
|
-
*
|
|
985
|
-
*
|
|
986
|
-
* @notes <br>
|
|
987
|
-
* - 该方法需要在调用 setupWithConfig:{@link #VeLiveVideoEffectManager#setupWithConfig} 和 setAlgoModelPath:{@link #VeLiveVideoEffectManager#setAlgoModelPath} 后调用;
|
|
988
|
-
* - 该方法不直接开启/关闭视频特效,您需要在调用该方法后,调用 setComposeNodes:{@link #VeLiveVideoEffectManager#setComposeNodes} 开启视频特效;
|
|
1004
|
+
* @notes
|
|
1005
|
+
* - 该方法需要在调用 [setupWithConfig:](#VeLiveVideoEffectManager-setupwithconfig) 和 [setAlgoModelPath:](#VeLiveVideoEffectManager-setalgomodelpath) 后调用;
|
|
1006
|
+
* - 该方法不直接开启/关闭视频特效,您需要在调用该方法后,调用 [setComposeNodes:](#VeLiveVideoEffectManager-setcomposenodes) 开启视频特效;
|
|
989
1007
|
* - 通用场景下,特效引擎会随 EffectManager 销毁而销毁。如果您对性能有较高要求,也可以在不使用特效相关功能时,调用该方法销毁特效引擎;
|
|
990
1008
|
* - 如果重复创建/销毁特效引擎,会产生时间消耗。
|
|
991
|
-
* @order
|
|
1009
|
+
* @order 5
|
|
992
1010
|
* @param enable 是否创建特效引擎。默认为 NO。 <br>
|
|
993
1011
|
* - YES:创建;
|
|
994
1012
|
* - NO:销毁。
|
|
1013
|
+
* @return <br>
|
|
1014
|
+
* - 0:调用成功;
|
|
1015
|
+
* - -1:调用失败。
|
|
995
1016
|
*/
|
|
1017
|
+
|
|
996
1018
|
setEnable(enable: BOOL): int;
|
|
997
1019
|
/** {zh}
|
|
998
1020
|
* @detail api
|
|
999
1021
|
* @brief 设置视频特效组合。支持设置 ComposeMakeup.bundle 中的功能,包括美颜、美形、美体、美妆等。
|
|
1022
|
+
* @notes
|
|
1023
|
+
* - 需要在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 创建特效引擎后,调用本方法;
|
|
1024
|
+
* - 重复调用本方法,仅最后一次调用生效;
|
|
1025
|
+
* - 如果需要在当前的视频特效组合中叠加特效,可调用 [appendComposeNodes:](#VeLiveVideoEffectManager-appendcomposenodes) 方法。
|
|
1026
|
+
* @order 6
|
|
1027
|
+
* @param nodes 视频特效素材包路径数组。
|
|
1000
1028
|
* @return <br>
|
|
1001
1029
|
* - 0:调用成功;
|
|
1002
1030
|
* - -1:调用失败。
|
|
1003
|
-
* @notes <br>
|
|
1004
|
-
* - 需要在调用 setEnable:{@link #VeLiveVideoEffectManager#setEnable} 创建特效引擎后,调用本方法;
|
|
1005
|
-
* - 重复调用本方法,仅最后一次调用生效;
|
|
1006
|
-
* - 如果需要在当前的视频特效组合中叠加特效,可调用 appendComposeNodes:{@link #VeLiveVideoEffectManager#appendComposeNodes} 方法。
|
|
1007
|
-
* @order 79
|
|
1008
|
-
* @param nodes 视频特效素材包路径数组。
|
|
1009
1031
|
*/
|
|
1032
|
+
|
|
1010
1033
|
setComposeNodes(nodes: NSArray<NSString>): int;
|
|
1011
1034
|
/** {zh}
|
|
1012
1035
|
* @detail api
|
|
1013
|
-
* @brief
|
|
1036
|
+
* @brief 调用本方法,会在 [setComposeNodes:](#VeLiveVideoEffectManager-setcomposenodes) 设置的视频特效组合的基础上叠加特效。
|
|
1037
|
+
* @notes 需要在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 创建特效引擎后,调用本方法。
|
|
1038
|
+
* @order 7
|
|
1039
|
+
* @param nodes 视频特效素材包路径数组。
|
|
1014
1040
|
* @return <br>
|
|
1015
1041
|
* - 0:调用成功;
|
|
1016
1042
|
* - -1:调用失败。
|
|
1017
|
-
* @notes <br>
|
|
1018
|
-
* - 需要在调用 setEnable:{@link #VeLiveVideoEffectManager#setEnable} 创建特效引擎后,调用本方法。
|
|
1019
|
-
* - 调用本方法,会在 setComposeNodes:{@link #VeLiveVideoEffectManager#setComposeNodes} 设置的视频特效组合的基础上叠加特效。
|
|
1020
|
-
* @order 80
|
|
1021
|
-
* @param nodes 视频特效素材包路径数组。
|
|
1022
1043
|
*/
|
|
1044
|
+
|
|
1023
1045
|
appendComposeNodes(nodes: NSArray<NSString>): int;
|
|
1024
1046
|
/** {zh}
|
|
1025
1047
|
* @detail api
|
|
1026
|
-
* @brief
|
|
1048
|
+
* @brief 调用本方法,可移除调用 [setComposeNodes:](#VeLiveVideoEffectManager-setcomposenodes) 和 [ppendComposeNodes:](#VeLiveVideoEffectManager-appendcomposenodes) 设置的视频特效资源。
|
|
1049
|
+
* @notes 需要在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 创建特效引擎后,调用本方法。
|
|
1050
|
+
* @order 8
|
|
1051
|
+
* @param nodes 视频特效素材包路径数组。
|
|
1027
1052
|
* @return <br>
|
|
1028
1053
|
* - 0:调用成功;
|
|
1029
1054
|
* - -1:调用失败。
|
|
1030
|
-
* @notes <br>
|
|
1031
|
-
* - 需要在调用 setEnable:{@link #VeLiveVideoEffectManager#setEnable} 创建特效引擎后,调用本方法。
|
|
1032
|
-
* - 调用本方法,可移除调用 setComposeNodes:{@link #VeLiveVideoEffectManager#setComposeNodes} 和 appendComposeNodes:{@link #VeLiveVideoEffectManager#appendComposeNodes} 设置的视频特效资源。
|
|
1033
|
-
* @order 81
|
|
1034
|
-
* @param nodes 视频特效素材包路径数组。
|
|
1035
1055
|
*/
|
|
1056
|
+
|
|
1036
1057
|
removeComposeNodes(nodes: NSArray<NSString>): int;
|
|
1037
1058
|
/** {zh}
|
|
1038
1059
|
* @detail api
|
|
1039
1060
|
* @brief 设置视频特效强度。
|
|
1040
|
-
* @
|
|
1041
|
-
*
|
|
1042
|
-
* - -1:调用失败。
|
|
1043
|
-
* @notes <br>
|
|
1044
|
-
* - 需要在调用 setComposeNodes:{@link #VeLiveVideoEffectManager#setComposeNodes} 设置视频特效组合或调用 appendComposeNodes:{@link #VeLiveVideoEffectManager#appendComposeNodes} 叠加视频特效素材包后,调用本方法;
|
|
1061
|
+
* @notes
|
|
1062
|
+
* - 需要在调用 [setComposeNodes:](#VeLiveVideoEffectManager-setcomposenodes) 设置视频特效组合或调用 [appendComposeNodes:](#VeLiveVideoEffectManager-appendcomposenodes) 叠加视频特效素材包后,调用本方法;
|
|
1045
1063
|
* - 该方法仅适用于同时含有上述三个参数的特效资源,对于没有强度参数的特效(如贴纸),该方法无效。
|
|
1046
|
-
* @order
|
|
1064
|
+
* @order 9
|
|
1047
1065
|
* @param node 视频特效素材包路径。
|
|
1048
1066
|
* @param key 需要设置的素材 key 名称
|
|
1049
1067
|
* @param intensity 需要设置的强度值。取值范围为 [0.0,1.0]。
|
|
1068
|
+
* @return <br>
|
|
1069
|
+
* - 0:调用成功;
|
|
1070
|
+
* - -1:调用失败。
|
|
1050
1071
|
*/
|
|
1072
|
+
|
|
1051
1073
|
updateComposerNodeIntensity(node: NSString, key: NSString, intensity: float): int;
|
|
1052
1074
|
/** {zh}
|
|
1053
1075
|
* @detail api
|
|
1054
1076
|
* @brief 设置颜色滤镜。
|
|
1077
|
+
* @notes
|
|
1078
|
+
* 请在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 开启视频特效后,调用该方法。
|
|
1079
|
+
* @order 11
|
|
1080
|
+
* @param path 滤镜资源包绝对路径。
|
|
1055
1081
|
* @return <br>
|
|
1056
1082
|
* - 0:调用成功;
|
|
1057
1083
|
* - -1:调用失败。
|
|
1058
|
-
* @notes <br>请在调用 setEnable:{@link #VeLiveVideoEffectManager#setEnable} 开启视频特效后,调用该方法。
|
|
1059
|
-
* @order 83
|
|
1060
|
-
* @param path 滤镜资源包绝对路径。
|
|
1061
1084
|
*/
|
|
1085
|
+
|
|
1062
1086
|
setFilter(path: NSString): int;
|
|
1063
1087
|
/** {zh}
|
|
1064
1088
|
* @detail api
|
|
1065
1089
|
* @brief 设置已启用的颜色滤镜强度。
|
|
1090
|
+
* @notes
|
|
1091
|
+
* 请在调用 [setFilter:](#VeLiveVideoEffectManager-setfilter) 设置颜色滤镜后调用。
|
|
1092
|
+
* @order 12
|
|
1093
|
+
* @param intensity 滤镜强度,取值范围为 [0.0,1.0]。
|
|
1066
1094
|
* @return <br>
|
|
1067
1095
|
* - 0:调用成功;
|
|
1068
1096
|
* - -1:调用失败。
|
|
1069
|
-
* @notes <br>
|
|
1070
|
-
* 请在调用 setFilter:{@link #VeLiveVideoEffectManager#setFilter} 设置颜色滤镜后调用。
|
|
1071
|
-
* @order 84
|
|
1072
|
-
* @param intensity 滤镜强度,取值范围为 [0.0,1.0]。
|
|
1073
1097
|
*/
|
|
1098
|
+
|
|
1074
1099
|
updateFilterIntensity(intensity: float): int;
|
|
1075
1100
|
/** {zh}
|
|
1076
1101
|
* @detail api
|
|
1077
1102
|
* @brief 设置贴纸特效。
|
|
1103
|
+
* @notes
|
|
1104
|
+
* 请在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 开启视频特效后,调用该方法。
|
|
1105
|
+
* @order 10
|
|
1106
|
+
* @param path 贴纸素材包的绝对路径。
|
|
1078
1107
|
* @return <br>
|
|
1079
1108
|
* - 0:调用成功;
|
|
1080
1109
|
* - -1:调用失败。
|
|
1081
|
-
* @notes <br>请在调用 setEnable:{@link #VeLiveVideoEffectManager#setEnable} 开启视频特效后,调用该方法。
|
|
1082
|
-
* @order 85
|
|
1083
|
-
* @param path 贴纸素材包的绝对路径。
|
|
1084
1110
|
*/
|
|
1111
|
+
|
|
1085
1112
|
setSticker(path: NSString): int;
|
|
1086
1113
|
/** {zh}
|
|
1087
1114
|
* @detail api
|
|
1088
1115
|
* @brief 智能美化特效(简称 CV)高级接口。
|
|
1089
|
-
* @notes
|
|
1116
|
+
* @notes
|
|
1117
|
+
* 请在调用 [setEnable:](#VeLiveVideoEffectManager-setenable) 开启视频特效后,调用该方法,不要在主线程中频繁执行同步操作。
|
|
1090
1118
|
* @param callback 回调 CV 的 handle。
|
|
1091
1119
|
* @param isGLThread 是否在 GL 线程回调 callback。
|
|
1092
1120
|
* @param isAsync 是否同步执行 callback。
|
|
1093
1121
|
*/
|
|
1122
|
+
|
|
1094
1123
|
setAdvancedFeature(callback: (handle: void) => void, isGLThread: BOOL, isAsync: BOOL): void;
|
|
1095
1124
|
init(): this;
|
|
1096
1125
|
}
|