@byteplus/react-native-live-push 1.0.2 → 1.0.3-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/NativeVariableManager.java +1 -1
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushModule.java +5 -3
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushViewManager.java +10 -5
- package/ios/VeLivePushView.m +1 -1
- package/ios/VeLivePushViewManager.m +5 -1
- package/lib/commonjs/index.js +21799 -17839
- package/lib/module/index.js +21799 -17832
- package/lib/typescript/android/index.d.ts +3 -0
- package/lib/typescript/codegen/android/api.d.ts +1350 -75
- package/lib/typescript/codegen/android/keytype.d.ts +439 -62
- package/lib/typescript/codegen/android/types.d.ts +7 -6
- package/lib/typescript/codegen/ios/api.d.ts +11 -19
- package/lib/typescript/codegen/ios/callback.d.ts +17 -25
- package/lib/typescript/codegen/ios/external.d.ts +1 -0
- package/lib/typescript/codegen/ios/index.d.ts +1 -0
- package/lib/typescript/codegen/ios/keytype.d.ts +6 -34
- package/lib/typescript/codegen/ios/types.d.ts +16 -5
- package/lib/typescript/codegen/pack/api.d.ts +1250 -1216
- package/lib/typescript/codegen/pack/callback.d.ts +153 -295
- package/lib/typescript/codegen/pack/errorcode.d.ts +11 -150
- package/lib/typescript/codegen/pack/index.d.ts +1 -1
- package/lib/typescript/codegen/pack/keytype.d.ts +806 -1366
- package/lib/typescript/codegen/pack/types.d.ts +67 -0
- package/lib/typescript/component.d.ts +10 -3
- package/lib/typescript/core/api.d.ts +2 -2
- package/lib/typescript/core/callback.d.ts +2 -2
- package/lib/typescript/core/errorcode.d.ts +2 -2
- package/lib/typescript/core/keytype.d.ts +2 -7
- package/lib/typescript/platforms/ios/extends.d.ts +17 -0
- package/package.json +2 -1
- package/react-native-velive-push.podspec +3 -3
|
@@ -1,1642 +1,1809 @@
|
|
|
1
|
-
import { VeLiveVideoBufferType, VeLivePixelFormat, VeLiveVideoRotation, VeLiveVideoEffectLicenseConfiguration, VeLivePusherRenderMode, VeLiveVideoMirrorType, VeLiveVideoCaptureType, VeLiveAudioCaptureType, VeLiveVideoEncoderConfiguration, VeLiveAudioEncoderConfiguration, VeLiveFileRecorderConfiguration, VeLiveOrientation, VeLiveVideoEncodeFrame, VeLivePusherLogLevel, VeLiveStreamMixDescription, VeLiveAudioBufferType, VeLiveAudioSampleRate, VeLiveAudioChannel, VeLiveVideoCaptureConfiguration, VeLiveAudioCaptureConfiguration } from './keytype';
|
|
2
1
|
import * as $p_a from '../android/index';
|
|
3
2
|
import * as $p_i from '../ios/index';
|
|
4
3
|
import { VeLivePusherObserver, VeLivePusherStatisticsObserver, VeLiveFileRecordingListener, VeLiveVideoFrameFilter, VeLiveAudioFrameFilter, VeLiveVideoFrameListener, VeLiveAudioFrameListener, VeLiveSnapshotListener, VeLiveMediaPlayerListener, VeLiveMediaPlayerFrameListener } from './callback';
|
|
5
|
-
import {
|
|
4
|
+
import { VeLivePusherRenderMode, VeLiveVideoMirrorType, VeLiveVideoCaptureType, VeLiveAudioCaptureType, VeLiveOrientation, VeLivePusherLogLevel, VeLiveVideoEncoderConfiguration, VeLiveAudioEncoderConfiguration, VeLiveFileRecorderConfiguration, VeLiveVideoCaptureConfiguration, VeLiveVideoEffectLicenseConfiguration, VeLiveStreamMixDescription, VeLiveAudioBufferType, VeLiveAudioSampleRate, VeLiveAudioChannel } from './keytype';
|
|
5
|
+
import { View, Bitmap, Matrix, ByteBuffer } from './types';
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
* @detail api
|
|
9
|
-
* @list overview
|
|
10
|
-
* @brief The information of a video frame.
|
|
11
|
-
*/
|
|
12
|
-
export declare class VeLiveVideoFrame {
|
|
13
|
-
protected _instance: any;
|
|
14
|
-
protected __init(...args: any[]): void;
|
|
15
|
-
protected __new_instance(...args: any[]): $p_a.VeLiveVideoFrame | $p_i.VeLiveVideoFrame;
|
|
16
|
-
get width(): number;
|
|
17
|
-
set width(value: number);
|
|
18
|
-
get height(): number;
|
|
19
|
-
set height(value: number);
|
|
20
|
-
/**
|
|
21
|
-
* @platform android
|
|
22
|
-
*/
|
|
23
|
-
get android_ptsUs(): number;
|
|
24
|
-
set android_ptsUs(value: number);
|
|
25
|
-
get textureId(): number;
|
|
26
|
-
set textureId(value: number);
|
|
27
|
-
get data(): any;
|
|
28
|
-
set data(value: any);
|
|
7
|
+
export declare class VeLivePusher {
|
|
29
8
|
|
|
30
9
|
/** {en}
|
|
31
10
|
* @platform android
|
|
32
11
|
* @detail api
|
|
33
|
-
* @
|
|
34
|
-
* @brief
|
|
12
|
+
* @hidden
|
|
13
|
+
* @brief Gets the version number of the current SDK.
|
|
14
|
+
* @return <br>
|
|
15
|
+
* The version number of the current SDK.
|
|
16
|
+
*
|
|
35
17
|
*/
|
|
36
|
-
|
|
18
|
+
static android_getVersion(): string;
|
|
37
19
|
|
|
38
20
|
/** {en}
|
|
39
21
|
* @detail api
|
|
40
|
-
* @
|
|
41
|
-
* @
|
|
22
|
+
* @brief Sets the level of the output log.
|
|
23
|
+
* @param logLevel The log level. See VeLivePusherLogLevel {@link #VeLivePusherLogLevel} for details.
|
|
24
|
+
* @order 60
|
|
25
|
+
*
|
|
42
26
|
*/
|
|
43
|
-
|
|
27
|
+
static setLogLevel(logLevel: VeLivePusherLogLevel): void;
|
|
44
28
|
|
|
45
29
|
/** {en}
|
|
30
|
+
* @platform android
|
|
46
31
|
* @detail api
|
|
47
|
-
* @
|
|
48
|
-
* @brief
|
|
49
|
-
* @
|
|
50
|
-
*
|
|
32
|
+
* @hidden
|
|
33
|
+
* @brief Sets log configurations.
|
|
34
|
+
* @param config The log level. See VeLivePusherLogConfig {@link #VeLivePusherLogConfig} for details。
|
|
35
|
+
*
|
|
51
36
|
*/
|
|
52
|
-
|
|
37
|
+
static android_setLogConfig(config: $p_a.VeLivePusherLogConfig): void;
|
|
53
38
|
|
|
54
39
|
/** {en}
|
|
40
|
+
* @platform android
|
|
55
41
|
* @detail api
|
|
56
|
-
* @
|
|
57
|
-
* @
|
|
58
|
-
* @
|
|
59
|
-
*
|
|
60
|
-
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
42
|
+
* @brief Sets the context of OpenGL.
|
|
43
|
+
* @param context The context of OpenGL.
|
|
44
|
+
* @order 61
|
|
45
|
+
*
|
|
61
46
|
*/
|
|
62
|
-
|
|
47
|
+
static android_setEGLContext(context: $p_a.EGLContext): void;
|
|
48
|
+
protected _instance: any;
|
|
49
|
+
protected __init(...args: any[]): void;
|
|
50
|
+
protected __new_instance(...args: any[]): any;
|
|
63
51
|
|
|
64
52
|
/** {en}
|
|
65
53
|
* @detail api
|
|
66
|
-
* @
|
|
67
|
-
* @
|
|
68
|
-
*
|
|
69
|
-
* The pixel format. See VeLivePixelFormat {@link #VeLivePixelFormat} for details.
|
|
54
|
+
* @brief Stops capturing and pushing streams and destroys the pusher. Call this method after stopPush {@link #VeLivePusher#stopPush} is called.
|
|
55
|
+
* @order 13
|
|
56
|
+
*
|
|
70
57
|
*/
|
|
71
|
-
|
|
58
|
+
destroy(): void;
|
|
72
59
|
|
|
73
60
|
/** {en}
|
|
74
61
|
* @detail api
|
|
75
|
-
* @
|
|
76
|
-
* @
|
|
77
|
-
* @
|
|
78
|
-
*
|
|
79
|
-
*
|
|
62
|
+
* @brief Sets an observer to listen for live pusher events, including errors, statuses, network quality, device information, and first frame rendering.
|
|
63
|
+
* @param observer The observer. Refer to VeLivePusherObserver {@link #VeLivePusherObserver} for details.
|
|
64
|
+
* @notes <br>
|
|
65
|
+
* - This method must be called after the live pusher is created;
|
|
66
|
+
* - If you make multiple calls to this method, only the last call takes effect.
|
|
67
|
+
* @order 1
|
|
68
|
+
*
|
|
80
69
|
*/
|
|
81
|
-
|
|
70
|
+
setObserver(observer: VeLivePusherObserver): void;
|
|
82
71
|
|
|
83
72
|
/** {en}
|
|
84
73
|
* @detail api
|
|
85
|
-
* @
|
|
86
|
-
* @
|
|
87
|
-
* @
|
|
88
|
-
*
|
|
74
|
+
* @brief Sets an observer to periodically report push-stream statistics.
|
|
75
|
+
* @param observer The observer. Refer to VeLivePusherStatisticsObserver {@link #VeLivePusherStatisticsObserver} for details.
|
|
76
|
+
* @param interval The time interval between two callbacks, in seconds. The default value is `5`.
|
|
77
|
+
* @notes <br>
|
|
78
|
+
* - This method must be called after the live pusher is created;
|
|
79
|
+
* - If you make multiple calls to this method, only the last call takes effect.
|
|
80
|
+
* @order 15
|
|
81
|
+
*
|
|
89
82
|
*/
|
|
90
|
-
|
|
83
|
+
setStatisticsObserver(observer: VeLivePusherStatisticsObserver, interval: number): void;
|
|
91
84
|
|
|
92
85
|
/** {en}
|
|
93
86
|
* @detail api
|
|
94
|
-
* @
|
|
95
|
-
* @
|
|
96
|
-
* @
|
|
97
|
-
*
|
|
98
|
-
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
87
|
+
* @brief Sets the preview for the local camera. If beauty AR is applied to the captured video or if it undergoes any other processing, the preview will display the processed video.
|
|
88
|
+
* @param view The preview view.
|
|
89
|
+
* @order 16
|
|
90
|
+
*
|
|
99
91
|
*/
|
|
100
|
-
|
|
92
|
+
setRenderView(view: View): Promise<void>;
|
|
101
93
|
|
|
102
94
|
/** {en}
|
|
103
95
|
* @detail api
|
|
104
|
-
* @
|
|
105
|
-
* @
|
|
106
|
-
*
|
|
107
|
-
* The width of the video frame.
|
|
96
|
+
* @brief Sets fill mode for the local camera preview.
|
|
97
|
+
* @param mode The fill mode.
|
|
98
|
+
*
|
|
108
99
|
*/
|
|
109
|
-
|
|
100
|
+
setRenderFillMode(mode: VeLivePusherRenderMode): void;
|
|
110
101
|
|
|
111
102
|
/** {en}
|
|
112
103
|
* @detail api
|
|
113
|
-
* @
|
|
114
|
-
* @
|
|
115
|
-
* @
|
|
116
|
-
*
|
|
104
|
+
* @brief Enables or disables mirroring for the local preview and the streamed video.
|
|
105
|
+
* @param type Mirror mode. See VeLiveVideoMirrorType {@link #VeLiveVideoMirrorType} for details.
|
|
106
|
+
* @param mirror Whether to enable mirroring. <br>
|
|
107
|
+
* - true: Enable;
|
|
108
|
+
* - false: Disable.
|
|
109
|
+
* @order 17
|
|
110
|
+
*
|
|
117
111
|
*/
|
|
118
|
-
|
|
112
|
+
setVideoMirror(type: VeLiveVideoMirrorType, mirror: boolean): void;
|
|
119
113
|
|
|
120
114
|
/** {en}
|
|
121
|
-
* @platform android
|
|
122
115
|
* @detail api
|
|
123
|
-
* @
|
|
124
|
-
* @
|
|
125
|
-
* @
|
|
126
|
-
*
|
|
116
|
+
* @brief Starts video capture.
|
|
117
|
+
* @notes <br>After calling this method, you can stop video capture by calling [stopVideoCapture](#VeLivePusher-stopvideocapture).
|
|
118
|
+
* @order 18
|
|
119
|
+
* @param type The video capture type. See VeLiveVideoCaptureType{@link #VeLiveVideoCaptureType} for details.
|
|
120
|
+
*
|
|
121
|
+
*
|
|
127
122
|
*/
|
|
128
|
-
|
|
123
|
+
startVideoCapture(type: VeLiveVideoCaptureType): void;
|
|
129
124
|
|
|
130
125
|
/** {en}
|
|
131
|
-
* @platform android
|
|
132
126
|
* @detail api
|
|
133
|
-
* @
|
|
134
|
-
* @
|
|
135
|
-
* @
|
|
136
|
-
*
|
|
127
|
+
* @brief Stops video capture.
|
|
128
|
+
* @notes <br>After calling this method, you can start video capture by calling [startVideoCapture](#VeLivePusher-startvideocapture).
|
|
129
|
+
* @order 19
|
|
130
|
+
*
|
|
137
131
|
*/
|
|
138
|
-
|
|
132
|
+
stopVideoCapture(): void;
|
|
139
133
|
|
|
140
134
|
/** {en}
|
|
141
135
|
* @detail api
|
|
142
|
-
* @
|
|
143
|
-
* @
|
|
144
|
-
* @
|
|
145
|
-
*
|
|
136
|
+
* @brief Starts audio capture.
|
|
137
|
+
* @notes <br>After calling this method, you can stop audio capture by calling [stopAudioCapture](#VeLivePusher-stopaudiocapture).
|
|
138
|
+
* @order 20
|
|
139
|
+
* @param type The audio capture type. See VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} for details.
|
|
140
|
+
*
|
|
146
141
|
*/
|
|
147
|
-
|
|
142
|
+
startAudioCapture(type: VeLiveAudioCaptureType): void;
|
|
148
143
|
|
|
149
144
|
/** {en}
|
|
150
145
|
* @detail api
|
|
151
|
-
* @
|
|
152
|
-
* @
|
|
153
|
-
* @
|
|
154
|
-
*
|
|
146
|
+
* @brief Stops audio capture.
|
|
147
|
+
* @notes <br>After calling this method, you can start audio capture by calling [startAudioCapture](#VeLivePusher-startaudiocapture).
|
|
148
|
+
* @order 21
|
|
149
|
+
*
|
|
155
150
|
*/
|
|
156
|
-
|
|
151
|
+
stopAudioCapture(): void;
|
|
157
152
|
|
|
158
153
|
/** {en}
|
|
159
|
-
* @platform android
|
|
160
154
|
* @detail api
|
|
161
|
-
* @
|
|
162
|
-
* @
|
|
163
|
-
* @
|
|
164
|
-
*
|
|
155
|
+
* @brief Switches the video capture type.
|
|
156
|
+
* @notes <br>This method must be called after [startVideoCapture](#VeLivePusher-startvideocapture) is called.
|
|
157
|
+
* @order 22
|
|
158
|
+
* @param type The video capture type. See VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} for details.
|
|
159
|
+
*
|
|
165
160
|
*/
|
|
166
|
-
|
|
161
|
+
switchVideoCapture(type: VeLiveVideoCaptureType): void;
|
|
167
162
|
|
|
168
163
|
/** {en}
|
|
169
|
-
* @platform android
|
|
170
164
|
* @detail api
|
|
171
|
-
* @
|
|
172
|
-
* @
|
|
173
|
-
* @
|
|
174
|
-
*
|
|
165
|
+
* @brief Switches audio capture type.
|
|
166
|
+
* @notes <br>This method must be called after [startVideoCapture](#VeLivePusher-startvideocapture) is called.
|
|
167
|
+
* @order 23
|
|
168
|
+
* @param type The audio capture type. See VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} for details.
|
|
169
|
+
*
|
|
175
170
|
*/
|
|
176
|
-
|
|
171
|
+
switchAudioCapture(type: VeLiveAudioCaptureType): void;
|
|
177
172
|
|
|
178
173
|
/** {en}
|
|
179
174
|
* @detail api
|
|
180
|
-
* @
|
|
181
|
-
* @brief Gets the video data in the format of byte [].
|
|
175
|
+
* @brief Gets the current video capture type.
|
|
182
176
|
* @return <br>
|
|
183
|
-
*
|
|
177
|
+
* The video capture type. See VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} for details.
|
|
178
|
+
* @order 24
|
|
179
|
+
*
|
|
184
180
|
*/
|
|
185
|
-
|
|
181
|
+
getCurrentVideoCaptureType(): VeLiveVideoCaptureType;
|
|
186
182
|
|
|
187
183
|
/** {en}
|
|
188
|
-
* @platform android
|
|
189
184
|
* @detail api
|
|
190
|
-
* @
|
|
191
|
-
* @brief Gets the internal release callback.
|
|
185
|
+
* @brief Gets the current audio capture type.
|
|
192
186
|
* @return <br>
|
|
193
|
-
*
|
|
187
|
+
* The audio capture type. See VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} for details.
|
|
188
|
+
* @order 25
|
|
189
|
+
*
|
|
194
190
|
*/
|
|
195
|
-
|
|
191
|
+
getCurrentAudioCaptureType(): VeLiveAudioCaptureType;
|
|
196
192
|
|
|
197
193
|
/** {en}
|
|
198
|
-
* @platform android
|
|
199
194
|
* @detail api
|
|
200
|
-
* @
|
|
201
|
-
* @
|
|
202
|
-
* @
|
|
203
|
-
*
|
|
204
|
-
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
195
|
+
* @brief Sets a static image to push. When using this method, you must call startVideoCapture {@link #VeLivePusher#startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureCustomImage`.
|
|
196
|
+
* @param image The static image to push.
|
|
197
|
+
* @order 26
|
|
198
|
+
*
|
|
205
199
|
*/
|
|
206
|
-
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
/** {en}
|
|
210
|
-
* @detail api
|
|
211
|
-
* @list overview
|
|
212
|
-
* @brief The camera manager.
|
|
213
|
-
*/
|
|
214
|
-
export declare class VeLiveCameraDevice {
|
|
215
|
-
protected _instance: any;
|
|
216
|
-
protected __init(...args: any[]): void;
|
|
217
|
-
protected __new_instance(...args: any[]): $p_a.VeLiveCameraDevice | $p_i.VeLiveCameraDevice;
|
|
200
|
+
updateCustomImage(image: Bitmap): Promise<void>;
|
|
218
201
|
|
|
219
202
|
/** {en}
|
|
220
|
-
* @
|
|
221
|
-
* @
|
|
203
|
+
* @detail api
|
|
204
|
+
* @brief Gets the camera manager. With the camera manager, you can do the following:
|
|
205
|
+
* - Control the flashlight
|
|
206
|
+
* - Set the camera zoom
|
|
207
|
+
* - Set autofocus
|
|
208
|
+
* @return <br>
|
|
209
|
+
* The camera manager. See VeLiveCameraDevice {@link #VeLiveCameraDevice} for details.
|
|
210
|
+
* @notes <br>
|
|
211
|
+
* To use this method, you must first call startVideoCapture {@link #startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureFrontCamera` or `VeLiveVideoCaptureBackCamera`.
|
|
212
|
+
* @order 27
|
|
213
|
+
*
|
|
222
214
|
*/
|
|
223
|
-
|
|
224
|
-
set android_CAMERA_DEVICE_CODE_OK(value: $p_a.int);
|
|
215
|
+
getCameraDevice(): VeLiveCameraDevice;
|
|
225
216
|
|
|
226
217
|
/** {en}
|
|
227
|
-
* @
|
|
228
|
-
* @
|
|
218
|
+
* @detail api
|
|
219
|
+
* @brief Sets video encoding parameters for the pushed stream.
|
|
220
|
+
* @notes This method can be called before or after live streaming starts.
|
|
221
|
+
* @order 28
|
|
222
|
+
* @param config The video encoding parameters, including the video resolution, encoding format, target bitrate, and GOP size. For details, see VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration}.
|
|
223
|
+
*
|
|
229
224
|
*/
|
|
230
|
-
|
|
231
|
-
set android_CAMERA_DEVICE_CODE_NOT_LIVE(value: $p_a.int);
|
|
225
|
+
setVideoEncoderConfiguration(config: VeLiveVideoEncoderConfiguration): void;
|
|
232
226
|
|
|
233
227
|
/** {en}
|
|
234
228
|
* @platform android
|
|
235
|
-
* @
|
|
229
|
+
* @detail api
|
|
230
|
+
* @brief Gets video encoding parameters for the pushed stream.
|
|
231
|
+
* @return <br>
|
|
232
|
+
* The video encoding parameters, including the video resolution, encoding format, target bitrate, and GOP size. For details, see VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration}.
|
|
233
|
+
* @order 29
|
|
234
|
+
*
|
|
236
235
|
*/
|
|
237
|
-
|
|
238
|
-
set android_CAMERA_DEVICE_CODE_NOT_SUPPORT(value: $p_a.int);
|
|
236
|
+
android_getVideoEncoderConfiguration(): $p_a.VeLiveVideoEncoderConfiguration;
|
|
239
237
|
|
|
240
238
|
/** {en}
|
|
241
|
-
* @
|
|
242
|
-
* @
|
|
239
|
+
* @detail api
|
|
240
|
+
* @brief Sets audio encoding parameters for the pushed stream.
|
|
241
|
+
* @notes <br>This method must be called before calling [startPush](#VeLivePusher-startpush) or [startPushWithUrls](#VeLivePusher-startpushwithurls).
|
|
242
|
+
* @order 30
|
|
243
|
+
* @param config The audio encoding parameters. See [VeLiveAudioEncoderConfiguration](147521#VeLiveAudioEncoderConfiguration) for details.
|
|
244
|
+
*
|
|
243
245
|
*/
|
|
244
|
-
|
|
245
|
-
set android_CAMERA_DEVICE_CODE_PARAM_ILLEGAL(value: $p_a.int);
|
|
246
|
+
setAudioEncoderConfiguration(config: VeLiveAudioEncoderConfiguration): void;
|
|
246
247
|
|
|
247
248
|
/** {en}
|
|
248
249
|
* @platform android
|
|
249
|
-
* @
|
|
250
|
+
* @detail api
|
|
251
|
+
* @brief Gets audio encoding parameters for the pushed stream.
|
|
252
|
+
* @return <br>The audio encoding parameters. See VeLiveAudioEncoderConfiguration for details.
|
|
253
|
+
* @order 31
|
|
254
|
+
*
|
|
250
255
|
*/
|
|
251
|
-
|
|
252
|
-
set android_CAMERA_DEVICE_CODE_ERROR_BASE(value: $p_a.int);
|
|
256
|
+
android_getAudioEncoderConfiguration(): $p_a.VeLiveAudioEncoderConfiguration;
|
|
253
257
|
|
|
254
258
|
/** {en}
|
|
255
259
|
* @detail api
|
|
256
|
-
* @
|
|
257
|
-
* @
|
|
258
|
-
* @
|
|
259
|
-
*
|
|
260
|
-
* Call this method after calling startVideoCapture {@link #startVideoCapture} to start camera capture.
|
|
261
|
-
* @order 64
|
|
260
|
+
* @brief Starts streaming.
|
|
261
|
+
* @param url The push stream address.
|
|
262
|
+
* @order 32
|
|
263
|
+
*
|
|
262
264
|
*/
|
|
263
|
-
|
|
265
|
+
startPush(url: string): void;
|
|
264
266
|
|
|
265
267
|
/** {en}
|
|
266
268
|
* @detail api
|
|
267
|
-
* @
|
|
268
|
-
* @
|
|
269
|
-
* @
|
|
270
|
-
*
|
|
271
|
-
* @
|
|
272
|
-
*
|
|
269
|
+
* @brief Starts streaming with one or more push stream addresses.
|
|
270
|
+
* @param urls A list of push stream addresses.
|
|
271
|
+
* @notes <br>
|
|
272
|
+
* When the first push stream address in the array is unavailable, the SDK will automatically switch to the subsequent addresses.
|
|
273
|
+
* @order 33
|
|
274
|
+
*
|
|
273
275
|
*/
|
|
274
|
-
|
|
276
|
+
startPushWithUrls(urls: Array<string>): void;
|
|
275
277
|
|
|
276
278
|
/** {en}
|
|
277
|
-
* @platform android
|
|
278
279
|
* @detail api
|
|
279
|
-
* @
|
|
280
|
-
* @
|
|
280
|
+
* @brief Stops streaming.
|
|
281
|
+
* @notes <br>
|
|
282
|
+
* After you have stopped streaming, you can restart streaming by calling startPush {@link #startPush} or startPushWithUrls {@link #startPushWithUrls}.
|
|
283
|
+
* @order 34
|
|
284
|
+
*
|
|
285
|
+
*/
|
|
286
|
+
stopPush(): void;
|
|
287
|
+
|
|
288
|
+
/** {en}
|
|
289
|
+
* @detail api
|
|
290
|
+
* @brief Checks whether the streaming is currently ongoing. You can use this method to query the status of the live pusher.
|
|
281
291
|
* @return <br>
|
|
282
|
-
*
|
|
283
|
-
*
|
|
284
|
-
*
|
|
292
|
+
* Whether the streaming is currently ongoing. <br>
|
|
293
|
+
* - true: The streaming is currently ongoing;
|
|
294
|
+
* - false: The streaming has stopped.
|
|
295
|
+
* @order 35
|
|
296
|
+
*
|
|
285
297
|
*/
|
|
286
|
-
|
|
298
|
+
isPushing(): boolean;
|
|
287
299
|
|
|
288
300
|
/** {en}
|
|
289
301
|
* @detail api
|
|
290
|
-
* @
|
|
291
|
-
* @
|
|
302
|
+
* @brief Sets a watermark for the pushed stream.
|
|
303
|
+
* @param image The watermark image. Setting it to null means disabling watermarking.
|
|
304
|
+
* @param x The horizontal offset of the watermark, which represents the ratio of the distance between the left edge of the watermark and the left edge of the video to the width of the video. The value range is [0.0,1.0].
|
|
305
|
+
* @param y The vertical offset of the watermark, which represents the ratio of the distance between the top edge of the watermark and the top edge of the video to the height of the video. The value range is [0.0,1.0].
|
|
306
|
+
* @param scale The uniform scaling of the watermark. The value range is [0.0, 1.0].
|
|
292
307
|
* @return <br>
|
|
293
308
|
* - 0: Success;
|
|
294
|
-
* -
|
|
295
|
-
* @
|
|
296
|
-
*
|
|
297
|
-
* @param enable Whether to enable the flashlight. <br>
|
|
298
|
-
* - true: Enable;
|
|
299
|
-
* - false: (Default) Disable.
|
|
309
|
+
* - < 0: Failure.
|
|
310
|
+
* @order 36
|
|
311
|
+
*
|
|
300
312
|
*/
|
|
301
|
-
|
|
313
|
+
setWatermark(image: Bitmap, x: number, y: number, scale: number): Promise<number>;
|
|
302
314
|
|
|
303
315
|
/** {en}
|
|
304
316
|
* @detail api
|
|
305
|
-
* @
|
|
306
|
-
* @
|
|
317
|
+
* @brief Starts local recording.
|
|
318
|
+
* @order 37
|
|
319
|
+
* @param path The directory for saving the recording file. You cannot leave this parameter empty.
|
|
320
|
+
* @param config The recording configurations. See VeLiveFileRecorderConfiguration for details.
|
|
321
|
+
* @param listener The listener for recording events. See VeLiveFileRecordingListener for details.
|
|
322
|
+
*
|
|
323
|
+
*/
|
|
324
|
+
startFileRecording(path: string, config: VeLiveFileRecorderConfiguration, listener: VeLiveFileRecordingListener): void;
|
|
325
|
+
|
|
326
|
+
/** {en}
|
|
327
|
+
* @detail api
|
|
328
|
+
* @brief Stops local recording.
|
|
329
|
+
* @notes <br>This method must be called after calling [startFileRecording](#VeLivePusher-startfilerecording).
|
|
330
|
+
* @order 38
|
|
331
|
+
*
|
|
332
|
+
*/
|
|
333
|
+
stopFileRecording(): void;
|
|
334
|
+
|
|
335
|
+
/** {en}
|
|
336
|
+
* @detail api
|
|
337
|
+
* @brief Set advanced configurations. You can contact BytePlus technical support for more information about how to use this method.
|
|
338
|
+
* @param key The JSON key.
|
|
339
|
+
* @param value The JSON value.
|
|
307
340
|
* @return <br>
|
|
308
341
|
* - 0: Success;
|
|
309
|
-
* -
|
|
310
|
-
* @
|
|
311
|
-
*
|
|
312
|
-
* @param ratio The zoom factor. The SDK uses the original size by default. The range of the zoom factor is [[getMinZoomRatio](#VeLiveCameraDevice-getminzoomratio),[getMaxZoomRatio](#VeLiveCameraDevice-getmaxzoomratio)].
|
|
342
|
+
* - -1: Failure.
|
|
343
|
+
* @order 39
|
|
344
|
+
*
|
|
313
345
|
*/
|
|
314
|
-
|
|
346
|
+
setProperty(key: string, value: Object): number;
|
|
315
347
|
|
|
316
348
|
/** {en}
|
|
317
349
|
* @detail api
|
|
318
|
-
* @
|
|
319
|
-
* @
|
|
350
|
+
* @brief Pushes an external video frame.
|
|
351
|
+
* @param frame The external video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
320
352
|
* @return <br>
|
|
321
|
-
* -
|
|
322
|
-
* -
|
|
323
|
-
* @notes
|
|
324
|
-
* @
|
|
353
|
+
* - 0: Success;
|
|
354
|
+
* - < 0: Failure.
|
|
355
|
+
* @notes <br>
|
|
356
|
+
* To use this method, you must first call startVideoCapture {@link #startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureExternal`.
|
|
357
|
+
* @order 40
|
|
358
|
+
*
|
|
325
359
|
*/
|
|
326
|
-
|
|
360
|
+
pushExternalVideoFrame(frame: VeLiveVideoFrame): number;
|
|
327
361
|
|
|
328
362
|
/** {en}
|
|
329
363
|
* @detail api
|
|
330
|
-
* @
|
|
331
|
-
* @
|
|
364
|
+
* @brief Pushes an external audio frame.
|
|
365
|
+
* @param frame The external audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
332
366
|
* @return <br>
|
|
333
|
-
*
|
|
334
|
-
*
|
|
335
|
-
* @notes
|
|
336
|
-
* @
|
|
367
|
+
* - 0: Success;
|
|
368
|
+
* - < 0: Failure.
|
|
369
|
+
* @notes <br>
|
|
370
|
+
* To use this method, you must first call startAudioCapture {@link #AustartdioCapture} and set VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} to `VeLiveAudioCaptureExternal`.
|
|
371
|
+
* @order 41
|
|
372
|
+
*
|
|
337
373
|
*/
|
|
338
|
-
|
|
374
|
+
pushExternalAudioFrame(frame: VeLiveAudioFrame): number;
|
|
339
375
|
|
|
340
376
|
/** {en}
|
|
341
377
|
* @detail api
|
|
342
|
-
* @
|
|
343
|
-
* @
|
|
378
|
+
* @brief Sets the orientation of the pushed video frame. The default orientation is portrait.
|
|
379
|
+
* @param orientation The orientation of the pushed video frame. See VeLiveOrientation {@link #VeLiveOrientation} for details.
|
|
380
|
+
* @order 42
|
|
381
|
+
*
|
|
382
|
+
*/
|
|
383
|
+
setOrientation(orientation: VeLiveOrientation): void;
|
|
384
|
+
|
|
385
|
+
/** {en}
|
|
386
|
+
* @detail api
|
|
387
|
+
* @brief Sends an SEI message through the video frame. The SEI messages are strings in JSON format.
|
|
344
388
|
* @return <br>
|
|
345
|
-
* -
|
|
346
|
-
* -
|
|
347
|
-
* @notes <br>
|
|
348
|
-
* @order
|
|
389
|
+
* - 0: Success;
|
|
390
|
+
* - < 0: Failure.
|
|
391
|
+
* @notes <br>This method must be called after calling [startPush](#VeLivePusher-startpush) or [startPushWithUrls](#VeLivePusher-startpushwithurls).
|
|
392
|
+
* @order 43
|
|
393
|
+
* @param key The JSON key.
|
|
394
|
+
* @param value The JSON value.
|
|
395
|
+
* @param repeat The number of times the message is sent. For example, if you set `repeat` to `20` and set `isKeyFrame` to `true`, the SDK will add the SEI message to 20 consecutive key frames starting from the time the method is called.
|
|
396
|
+
* @param isKeyFrame Whether SEI messages are only included in key frames. <br>
|
|
397
|
+
* - true: Add the SEI message to key frames only;
|
|
398
|
+
* - false: Add the SEI message to all types of frames.
|
|
399
|
+
* @param allowsCovered Whether to allow overwriting. <br>
|
|
400
|
+
* - true: Allow overwriting;
|
|
401
|
+
* - false: Do not allow overwriting.
|
|
402
|
+
*
|
|
349
403
|
*/
|
|
350
|
-
|
|
404
|
+
sendSeiMessage(key: string, value: Object, repeat: number, isKeyFrame: boolean, allowsCovered: boolean): number;
|
|
351
405
|
|
|
352
406
|
/** {en}
|
|
353
407
|
* @detail api
|
|
354
|
-
* @
|
|
355
|
-
* @
|
|
408
|
+
* @brief Sets whether to mute the stream.
|
|
409
|
+
* @param mute Whether to mute the stream. <br>
|
|
410
|
+
* - true: Mute;
|
|
411
|
+
* - false: (Default) Do not mute.
|
|
412
|
+
* @order 44
|
|
413
|
+
*
|
|
414
|
+
*/
|
|
415
|
+
setMute(mute: boolean): void;
|
|
416
|
+
|
|
417
|
+
/** {en}
|
|
418
|
+
* @detail api
|
|
419
|
+
* @brief Checks whether the stream is muted.
|
|
356
420
|
* @return <br>
|
|
357
|
-
* - true:
|
|
358
|
-
* - false:
|
|
359
|
-
* @
|
|
360
|
-
*
|
|
421
|
+
* - true: The stream is muted;
|
|
422
|
+
* - false: The stream is not muted.
|
|
423
|
+
* @order 45
|
|
424
|
+
*
|
|
361
425
|
*/
|
|
362
|
-
|
|
426
|
+
isMute(): boolean;
|
|
363
427
|
|
|
364
428
|
/** {en}
|
|
365
429
|
* @detail api
|
|
366
|
-
* @
|
|
367
|
-
*
|
|
430
|
+
* @brief Gets the special effects manager. With the special effects manager, you can do the following:
|
|
431
|
+
* - Set beauty AR
|
|
432
|
+
* - Set special effects
|
|
433
|
+
* - Set materials
|
|
434
|
+
* - Set stickers
|
|
435
|
+
* - Set filters
|
|
368
436
|
* @return <br>
|
|
369
|
-
*
|
|
370
|
-
*
|
|
371
|
-
*
|
|
372
|
-
* @order
|
|
373
|
-
*
|
|
374
|
-
* - true: (Default) Enable;
|
|
375
|
-
* - false: Disable.
|
|
437
|
+
* The special effects manager. See VeLiveVideoEffectManager {@link #VeLiveVideoEffectManager} for details.
|
|
438
|
+
* @notes <br>
|
|
439
|
+
* You must first integrate the BytePlus Effects SDK before calling this method.
|
|
440
|
+
* @order 46
|
|
441
|
+
*
|
|
376
442
|
*/
|
|
377
|
-
|
|
443
|
+
getVideoEffectManager(): VeLiveVideoEffectManager;
|
|
378
444
|
|
|
379
445
|
/** {en}
|
|
380
446
|
* @detail api
|
|
381
|
-
* @
|
|
382
|
-
* @
|
|
447
|
+
* @brief Sets custom video processing.
|
|
448
|
+
* @order 47
|
|
449
|
+
* @param filter The video filter. See VeLiveVideoFrameFilter for details.
|
|
450
|
+
*
|
|
451
|
+
*/
|
|
452
|
+
setVideoFrameFilter(filter: VeLiveVideoFrameFilter): void;
|
|
453
|
+
|
|
454
|
+
/** {en}
|
|
455
|
+
* @detail api
|
|
456
|
+
* @brief Gets the audio device manager.
|
|
383
457
|
* @return <br>
|
|
384
|
-
*
|
|
385
|
-
*
|
|
386
|
-
*
|
|
387
|
-
* @order
|
|
388
|
-
*
|
|
389
|
-
* @param viewH The height of the current view.
|
|
390
|
-
* @param x The horizontal coordinate of the focus point from the upper left corner of the current view.
|
|
391
|
-
* @param y The vertical coordinate of the focus point from the upper left corner of the current view.
|
|
458
|
+
* The audio device manager. See VeLiveAudioDevice {@link #VeLiveAudioDevice} for details.
|
|
459
|
+
* @notes <br>
|
|
460
|
+
* To use this method, you must first call startAudioCapture {@link #startAudioCapture} and set VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} to `VeLiveAudioCaptureMicrophone`.
|
|
461
|
+
* @order 48
|
|
462
|
+
*
|
|
392
463
|
*/
|
|
393
|
-
|
|
464
|
+
getAudioDevice(): VeLiveAudioDevice;
|
|
394
465
|
|
|
395
466
|
/** {en}
|
|
396
467
|
* @detail api
|
|
397
|
-
* @
|
|
398
|
-
* @
|
|
399
|
-
* @
|
|
400
|
-
*
|
|
401
|
-
* @notes You must call [startVideoCapture](#VeLivePusher-startvideocapture) to start SDK internal video capturing before calling this API.
|
|
402
|
-
* @order 74
|
|
468
|
+
* @brief Sets custom audio processing.
|
|
469
|
+
* @order 49
|
|
470
|
+
* @param filter The audio filter. See VeLiveAudioFrameFilter for details.
|
|
471
|
+
*
|
|
403
472
|
*/
|
|
404
|
-
|
|
473
|
+
setAudioFrameFilter(filter: VeLiveAudioFrameFilter): void;
|
|
405
474
|
|
|
406
475
|
/** {en}
|
|
407
|
-
* @return - =0: Success.
|
|
408
|
-
* - ≠0: Failure.
|
|
409
476
|
* @detail api
|
|
410
|
-
* @
|
|
411
|
-
* @
|
|
412
|
-
*
|
|
413
|
-
*
|
|
414
|
-
*
|
|
415
|
-
* @param viewW The width of the current view.
|
|
416
|
-
* @param viewH The height of the current view.
|
|
417
|
-
* @param x The horizontal coordinate of the focus point from the upper left corner of the current view.
|
|
418
|
-
* @param y The vertical coordinate of the focus point from the upper left corner of the current view.
|
|
477
|
+
* @brief Creates the media player.
|
|
478
|
+
* @return <br>
|
|
479
|
+
* The media player. See VeLiveMediaPlayer {@link #VeLiveMediaPlayer} for details.
|
|
480
|
+
* @order 50
|
|
481
|
+
*
|
|
419
482
|
*/
|
|
420
|
-
|
|
483
|
+
createPlayer(): VeLiveMediaPlayer;
|
|
421
484
|
|
|
422
485
|
/** {en}
|
|
423
|
-
* @return - ≤0: The camera does not support exposure;
|
|
424
|
-
* - \\>0: The minimum exposure compensation.
|
|
425
486
|
* @detail api
|
|
426
|
-
* @
|
|
427
|
-
* @
|
|
428
|
-
*
|
|
429
|
-
* @order
|
|
487
|
+
* @brief Gets the audio and video mixer.
|
|
488
|
+
* @return <br>
|
|
489
|
+
* The audio and video mixer. See VeLiveMixerManager {@link #VeLiveMixerManager} for details.
|
|
490
|
+
* @order 51
|
|
491
|
+
*
|
|
430
492
|
*/
|
|
431
|
-
|
|
493
|
+
getMixerManager(): VeLiveMixerManager;
|
|
432
494
|
|
|
433
495
|
/** {en}
|
|
434
|
-
* @
|
|
435
|
-
* - \\>0: The maximum exposure compensation.
|
|
496
|
+
* @platform android
|
|
436
497
|
* @detail api
|
|
437
|
-
* @
|
|
438
|
-
* @
|
|
439
|
-
* @
|
|
440
|
-
* @order
|
|
498
|
+
* @brief Starts screen capture.
|
|
499
|
+
* @param enableAppAudio Whether to record in-app audio data. Currently, you can only set it to `true`, which is the default value.
|
|
500
|
+
* @param screenIntent The system screen recording permission.
|
|
501
|
+
* @order 52
|
|
502
|
+
*
|
|
503
|
+
*
|
|
441
504
|
*/
|
|
442
|
-
|
|
505
|
+
android_startScreenRecording(enableAppAudio: boolean, screenIntent: $p_a.Intent): void;
|
|
443
506
|
|
|
444
507
|
/** {en}
|
|
445
|
-
* @
|
|
446
|
-
* - ≠0: Failure.
|
|
508
|
+
* @platform android
|
|
447
509
|
* @detail api
|
|
448
|
-
* @
|
|
449
|
-
* @
|
|
450
|
-
*
|
|
451
|
-
* - You must call [startVideoCapture](#VeLivePusher-startvideocapture) to start SDK internal video capturing, and use SDK internal rendering before calling this API.
|
|
452
|
-
* - The camera exposure compensation setting will be invalid after calling [stopVideoCapture](#VeLivePusher-stopvideocapture) to stop internal capturing.
|
|
453
|
-
* @order 78
|
|
454
|
-
* @param value The range of the exposure compensation is [[getMinExposureCompensation](#VeLiveCameraDevice-getminexposurecompensation),[getMaxExposureCompensation](#VeLiveCameraDevice-getmaxexposurecompensation)], Default to 0, which means no exposure compensation.
|
|
510
|
+
* @brief Stops screen capture.
|
|
511
|
+
* @order 53
|
|
512
|
+
*
|
|
455
513
|
*/
|
|
456
|
-
|
|
514
|
+
android_stopScreenRecording(): void;
|
|
515
|
+
|
|
516
|
+
/** {en}
|
|
517
|
+
* @platform android
|
|
518
|
+
* @detail api
|
|
519
|
+
* @brief Gets whether the SDK is capturing the screen at this moment.
|
|
520
|
+
* @order 54
|
|
521
|
+
*
|
|
522
|
+
*/
|
|
523
|
+
android_isScreenRecording(): boolean;
|
|
524
|
+
|
|
525
|
+
/** {en}
|
|
526
|
+
* @detail api
|
|
527
|
+
* @brief Adds a video frame listener.
|
|
528
|
+
* @return <br>
|
|
529
|
+
* - 0: Success;
|
|
530
|
+
* - < 0: Failure.
|
|
531
|
+
* @order 55
|
|
532
|
+
* @param listener The listener. See VeLiveVideoFrameListener for details.
|
|
533
|
+
*
|
|
534
|
+
*/
|
|
535
|
+
addVideoFrameListener(listener: VeLiveVideoFrameListener): number;
|
|
536
|
+
|
|
537
|
+
/** {en}
|
|
538
|
+
* @detail api
|
|
539
|
+
* @brief Removes the video frame listener.
|
|
540
|
+
* @return <br>
|
|
541
|
+
* - 0: Success;
|
|
542
|
+
* - < 0: Failure.
|
|
543
|
+
* @notes <br>
|
|
544
|
+
* Calling this method will return a failure if the listener has not been added or has been removed.
|
|
545
|
+
* @order 56
|
|
546
|
+
* @param listener The listener. See VeLiveVideoFrameListener for details.
|
|
547
|
+
*
|
|
548
|
+
*/
|
|
549
|
+
removeVideoFrameListener(listener: VeLiveVideoFrameListener): number;
|
|
550
|
+
|
|
551
|
+
/** {en}
|
|
552
|
+
* @detail api
|
|
553
|
+
* @brief Adds an audio frame listener.
|
|
554
|
+
* @return <br>
|
|
555
|
+
* - 0: Success;
|
|
556
|
+
* - < 0: Failure.
|
|
557
|
+
* @order 57
|
|
558
|
+
* @param listener The listener. See VeLiveAudioFrameListener for details.
|
|
559
|
+
*
|
|
560
|
+
*/
|
|
561
|
+
addAudioFrameListener(listener: VeLiveAudioFrameListener): number;
|
|
562
|
+
|
|
563
|
+
/** {en}
|
|
564
|
+
* @detail api
|
|
565
|
+
* @brief Removes the audio frame listener.
|
|
566
|
+
* @return <br>
|
|
567
|
+
* - 0: Success;
|
|
568
|
+
* - < 0: Failure.
|
|
569
|
+
* @notes <br>
|
|
570
|
+
* Calling this method will return a failure if the listener has not been added or has been removed.
|
|
571
|
+
* @order 58
|
|
572
|
+
* @param listener The listener. See VeLiveAudioFrameListener for details.
|
|
573
|
+
*
|
|
574
|
+
*/
|
|
575
|
+
removeAudioFrameListener(listener: VeLiveAudioFrameListener): number;
|
|
576
|
+
|
|
577
|
+
/** {en}
|
|
578
|
+
* @detail api
|
|
579
|
+
* @brief Takes a screenshot.
|
|
580
|
+
* @order 59
|
|
581
|
+
* @param listener The listener for the screenshot. See VeLiveSnapshotListener for details.
|
|
582
|
+
*
|
|
583
|
+
*/
|
|
584
|
+
snapshot(listener: VeLiveSnapshotListener): void;
|
|
457
585
|
|
|
458
586
|
/** {en}
|
|
459
587
|
* @platform ios
|
|
460
588
|
* @detail api
|
|
461
|
-
* @group
|
|
462
|
-
* @brief
|
|
589
|
+
* @param applicationGroupIdentifier iOS app group identifier.
|
|
590
|
+
* @brief Starts screen capturing.
|
|
591
|
+
*/
|
|
592
|
+
ios_startScreenCapture(applicationGroupIdentifier: string): void;
|
|
593
|
+
|
|
594
|
+
/** {en}
|
|
595
|
+
* @platform ios
|
|
596
|
+
* @detail api
|
|
597
|
+
* @brief Stops screen capturing.
|
|
598
|
+
*/
|
|
599
|
+
ios_stopScreenCapture(): void;
|
|
600
|
+
|
|
601
|
+
/** {en}
|
|
602
|
+
* @platform ios
|
|
603
|
+
* @detail api
|
|
604
|
+
* @brief Initializes the live pusher.
|
|
605
|
+
* @param config The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
606
|
+
* @order 0
|
|
607
|
+
*/
|
|
608
|
+
ios_initWithConfig(config: $p_i.VeLivePusherConfiguration): this;
|
|
609
|
+
|
|
610
|
+
/** {en}
|
|
611
|
+
* @platform ios
|
|
612
|
+
* @brief Sets the observer for screen capturing events.
|
|
613
|
+
* @notes Calling this method will return a failure if the listener has not been added or has been removed.
|
|
614
|
+
* @return - 0: Success;
|
|
615
|
+
* - <0: Failure.
|
|
616
|
+
* @param observer The observer for screen capturing events. For details, refer to [VeLiveScreenCaptureStatusObserver](broadcast-sdk-for-ios-callback#VeLiveScreenCaptureStatusObserver).
|
|
617
|
+
*/
|
|
618
|
+
ios_setScreenCaptureObserver(observer: $p_i.id<$p_i.VeLiveScreenCaptureStatusObserver>): number;
|
|
619
|
+
|
|
620
|
+
/** {en}
|
|
621
|
+
* @platform ios
|
|
622
|
+
* @detail api
|
|
623
|
+
* @brief Pushes an external encoded video frame.
|
|
463
624
|
* @return <br>
|
|
464
|
-
* -
|
|
465
|
-
* -
|
|
466
|
-
* @notes <br>
|
|
467
|
-
* @order
|
|
625
|
+
* - 0: Success;
|
|
626
|
+
* - <0: Failure.
|
|
627
|
+
* @notes <br>Before calling this method, you must first call startVideoCapture:{@link #VeLivePusher#startVideoCapture} and set [VeLiveVideoCaptureType](broadcast-sdk-for-ios-type-definition#VeLiveVideoCaptureType) to `VeLiveVideoCaptureFrontCamera` or `VeLiveVideoCaptureExternal`.
|
|
628
|
+
* @order 44
|
|
629
|
+
* @param encodeFrame The external encoded video frame. See VeLiveVideoEncodeFrame {@link #VeLiveVideoEncodeFrame} for details.
|
|
468
630
|
*/
|
|
469
|
-
|
|
631
|
+
ios_pushExternalVideoEncodeFrame(encodeFrame: $p_i.VeLiveVideoEncodeFrame): number;
|
|
632
|
+
|
|
633
|
+
/** {en}
|
|
634
|
+
* @platform ios
|
|
635
|
+
* @detail api
|
|
636
|
+
* @brief Request to encode a new IDR frame.
|
|
637
|
+
* @notes <br>
|
|
638
|
+
* This method must be called after calling startPush: {@link #VeLivePusher#startPush} or startPushWithUrls: {@link #VeLivePusher#startPushWithUrls}.
|
|
639
|
+
* @order 47
|
|
640
|
+
*/
|
|
641
|
+
ios_requestIDRFrame(): void;
|
|
470
642
|
}
|
|
471
643
|
|
|
472
|
-
|
|
473
|
-
* @detail api
|
|
474
|
-
* @list overview
|
|
475
|
-
* @brief The special effects manager. With the special effects manager, you can do the following:
|
|
476
|
-
* - Set beauty AR
|
|
477
|
-
* - Set special effects
|
|
478
|
-
* - Set materials
|
|
479
|
-
* - Set stickers
|
|
480
|
-
* - Set filters
|
|
481
|
-
*/
|
|
482
|
-
export declare class VeLiveVideoEffectManager {
|
|
644
|
+
export declare class VeLiveMediaPlayer {
|
|
483
645
|
protected _instance: any;
|
|
484
646
|
protected __init(...args: any[]): void;
|
|
485
|
-
protected __new_instance(...args: any[]):
|
|
647
|
+
protected __new_instance(...args: any[]): any;
|
|
486
648
|
|
|
487
649
|
/** {en}
|
|
488
650
|
* @detail api
|
|
489
|
-
* @
|
|
490
|
-
* @
|
|
491
|
-
*
|
|
492
|
-
* - 0: Success;
|
|
493
|
-
* - -1: Failure.
|
|
494
|
-
* @order 89
|
|
495
|
-
* @param config The special effects configurations. See VeLiveVideoEffectLicenseConfiguration for details.
|
|
651
|
+
* @brief Destroys the media player instance.
|
|
652
|
+
* @order 100
|
|
653
|
+
*
|
|
496
654
|
*/
|
|
497
|
-
|
|
655
|
+
destroy(): void;
|
|
498
656
|
|
|
499
657
|
/** {en}
|
|
500
658
|
* @detail api
|
|
501
|
-
* @
|
|
502
|
-
* @brief Updates the special effects license. This method is effective only if you authenticate the license online.
|
|
503
|
-
* @param callback The result callback.
|
|
659
|
+
* @brief Sets the observer for playback statuses.
|
|
504
660
|
* @notes <br>
|
|
505
|
-
*
|
|
506
|
-
*
|
|
507
|
-
* @
|
|
661
|
+
* If you make multiple calls to this method, only the last call takes effect.
|
|
662
|
+
* @order 101
|
|
663
|
+
* @param listener The observer that listens for playback statuses. For details, see VeLiveMediaPlayerListener.
|
|
664
|
+
*
|
|
508
665
|
*/
|
|
509
|
-
|
|
666
|
+
setListener(listener: VeLiveMediaPlayerListener): void;
|
|
510
667
|
|
|
511
668
|
/** {en}
|
|
512
669
|
* @detail api
|
|
513
|
-
* @
|
|
514
|
-
* @
|
|
515
|
-
* @return
|
|
670
|
+
* @brief Sets the file path. Supported file formats include MP3, AAC, M4A, WAV.
|
|
671
|
+
* @param url The file path.
|
|
672
|
+
* @return <br>
|
|
516
673
|
* - 0: Success;
|
|
517
|
-
* -
|
|
518
|
-
* @
|
|
519
|
-
*
|
|
520
|
-
* - This method does not enable or disable video special effects. Call [setComposeNodes](broadcast-sdk-for-android-api#VeLiveVideoEffectManager-setcomposenodes) after calling this method to enable video special effects;
|
|
521
|
-
* - In most cases, the special effects engine will be destroyed when the effects manager is destroyed. However, if you have high performance requirements, you can call this method to manually destroy the special effects engine when you are not using special effects-related features;
|
|
522
|
-
* - Creating or destroying the special effects engine repeatedly can result in increased processing time.
|
|
523
|
-
* @order 92
|
|
524
|
-
* @param enable Whether to create or destroy the special effects engine.
|
|
525
|
-
* - true: Create;
|
|
526
|
-
* - false: (Default) Destroy.
|
|
527
|
-
* @param callback [VeLiveVideoEffectCallback](broadcast-sdk-for-android-callback\\#VeLiveVideoEffectCallback), the listener for special effect events.
|
|
674
|
+
* - ≠ 0: Failure.
|
|
675
|
+
* @order 102
|
|
676
|
+
*
|
|
528
677
|
*/
|
|
529
|
-
|
|
678
|
+
prepare(url: string): number;
|
|
530
679
|
|
|
531
680
|
/** {en}
|
|
532
|
-
* @platform android
|
|
533
681
|
* @detail api
|
|
534
|
-
* @
|
|
535
|
-
* @
|
|
536
|
-
*
|
|
682
|
+
* @brief Pauses playback.
|
|
683
|
+
* @notes <br>
|
|
684
|
+
* This method must be called after you call start {@link #start} to start playback.
|
|
685
|
+
* @order 103
|
|
686
|
+
*
|
|
687
|
+
*/
|
|
688
|
+
start(): Promise<number>;
|
|
689
|
+
|
|
690
|
+
/** {en}
|
|
691
|
+
* @detail api
|
|
692
|
+
* @brief Stops playback.
|
|
537
693
|
* @return <br>
|
|
538
|
-
*
|
|
539
|
-
*
|
|
694
|
+
* - 0: Success;
|
|
695
|
+
* - ≠ 0: Failure.
|
|
540
696
|
* @notes <br>
|
|
541
|
-
*
|
|
542
|
-
* @order
|
|
697
|
+
* This method must be called after you call start {@link #start} to start playback.
|
|
698
|
+
* @order 104
|
|
699
|
+
*
|
|
700
|
+
*/
|
|
701
|
+
stop(): Promise<number>;
|
|
702
|
+
|
|
703
|
+
/** {en}
|
|
704
|
+
* @detail api
|
|
705
|
+
* @brief Pauses playback.
|
|
706
|
+
* @notes <br>
|
|
707
|
+
* This method must be called after you call start {@link #start} to start playback.
|
|
708
|
+
* @order 105
|
|
709
|
+
*
|
|
710
|
+
*/
|
|
711
|
+
pause(): Promise<void>;
|
|
712
|
+
|
|
713
|
+
/** {en}
|
|
714
|
+
* @detail api
|
|
715
|
+
* @brief Resumes playback.
|
|
716
|
+
* @notes <br>This method must be called after you call [pause](#VeLiveMediaPlayer-pause) to pause playback.
|
|
717
|
+
* @order 106
|
|
718
|
+
*
|
|
719
|
+
*/
|
|
720
|
+
resume(): Promise<void>;
|
|
721
|
+
|
|
722
|
+
/** {en}
|
|
723
|
+
* @detail api
|
|
724
|
+
* @brief Gets the duration of the media file.
|
|
725
|
+
* @return <br>
|
|
726
|
+
* - \\\\> 0: The duration of the media file, in milliseconds;
|
|
727
|
+
* - ≤ 0: Failure.
|
|
728
|
+
* @notes <br>This method must be called after you call [start](#VeLiveMediaPlayer-start) to start playback.
|
|
729
|
+
* @order 107
|
|
730
|
+
*
|
|
731
|
+
*/
|
|
732
|
+
getDuration(): number;
|
|
733
|
+
|
|
734
|
+
/** {en}
|
|
735
|
+
* @detail api
|
|
736
|
+
* @brief Sets the playback progress.
|
|
737
|
+
* @param posMs The playback progress, in milliseconds.
|
|
738
|
+
* @return <br>
|
|
739
|
+
* - 0: Success;
|
|
740
|
+
* - ≠ 0: Failure.
|
|
741
|
+
* @order 108
|
|
742
|
+
*
|
|
543
743
|
*/
|
|
544
|
-
|
|
744
|
+
seek(posMs: number): number;
|
|
545
745
|
|
|
546
746
|
/** {en}
|
|
547
747
|
* @detail api
|
|
548
|
-
* @
|
|
549
|
-
* @
|
|
550
|
-
*
|
|
551
|
-
*
|
|
552
|
-
*
|
|
553
|
-
*
|
|
554
|
-
* @notes <br>
|
|
555
|
-
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable};
|
|
556
|
-
* - If you make multiple calls to this method, only the last call takes effect;
|
|
557
|
-
* - To add more effects to the existing effects settings, call appendComposeNodes {@link #VeLiveVideoEffectManager#appendComposeNodes}.
|
|
558
|
-
* @order 93
|
|
748
|
+
* @brief Enables or disables mixing the audio to the live stream.
|
|
749
|
+
* @param enable Whether to enable or disable mixing the audio to the live stream. <br>
|
|
750
|
+
* - ture: Enable;
|
|
751
|
+
* - false: (Default) Disable.
|
|
752
|
+
* @order 109
|
|
753
|
+
*
|
|
559
754
|
*/
|
|
560
|
-
|
|
755
|
+
enableMixer(enable: boolean): void;
|
|
561
756
|
|
|
562
757
|
/** {en}
|
|
563
758
|
* @detail api
|
|
564
|
-
* @
|
|
565
|
-
* @
|
|
566
|
-
* @param
|
|
567
|
-
* @
|
|
568
|
-
*
|
|
569
|
-
* - -1: Failure.
|
|
570
|
-
* @notes <br>
|
|
571
|
-
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
572
|
-
* @order 94
|
|
759
|
+
* @brief Enables or disables automatic volume equalization.
|
|
760
|
+
* @param sourceLufs The source volume.
|
|
761
|
+
* @param targetLufs The target volume.
|
|
762
|
+
* @order 110
|
|
763
|
+
*
|
|
573
764
|
*/
|
|
574
|
-
|
|
765
|
+
enableAutoEq(sourceLufs: number, targetLufs: number): void;
|
|
575
766
|
|
|
576
767
|
/** {en}
|
|
577
768
|
* @detail api
|
|
578
|
-
* @
|
|
579
|
-
* @
|
|
580
|
-
* @
|
|
581
|
-
*
|
|
582
|
-
* - 0: Success;
|
|
583
|
-
* - -1: Failure.
|
|
584
|
-
* @notes <br>
|
|
585
|
-
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
586
|
-
* @order 94
|
|
769
|
+
* @brief Sets the view for rendering the video. Supports MP4 format.
|
|
770
|
+
* @param view The view used by the media player to render video.
|
|
771
|
+
* @order 111
|
|
772
|
+
*
|
|
587
773
|
*/
|
|
588
|
-
|
|
774
|
+
setRenderView(view: View): void;
|
|
589
775
|
|
|
590
776
|
/** {en}
|
|
591
777
|
* @detail api
|
|
592
|
-
* @
|
|
593
|
-
* @brief Sets the intensity of a special effect.
|
|
594
|
-
* @param node The path to the special effects resource.
|
|
595
|
-
* @param key The key of the resource.
|
|
596
|
-
* @param intensity The intensity of the effect. The value range is [0.0, 1.0].
|
|
597
|
-
* @return <br>
|
|
598
|
-
* - 0: Success;
|
|
599
|
-
* - -1: Failure.
|
|
778
|
+
* @brief Sets the observer for audio and video frames.
|
|
600
779
|
* @notes <br>
|
|
601
|
-
*
|
|
602
|
-
*
|
|
603
|
-
* @
|
|
780
|
+
* If you make multiple calls to this method, only the last call takes effect.
|
|
781
|
+
* @order 112
|
|
782
|
+
* @param listener The observer that listens for audio and video frames. For details, see VeLiveMediaPlayerFrameListener
|
|
783
|
+
*
|
|
604
784
|
*/
|
|
605
|
-
|
|
785
|
+
setFrameListener(listener: VeLiveMediaPlayerFrameListener): void;
|
|
606
786
|
|
|
607
787
|
/** {en}
|
|
608
788
|
* @detail api
|
|
609
|
-
* @
|
|
610
|
-
* @
|
|
611
|
-
* @
|
|
612
|
-
*
|
|
613
|
-
* - 0: Success;
|
|
614
|
-
* - -1: Failure.
|
|
615
|
-
* @notes <br>
|
|
616
|
-
* Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
617
|
-
* @order 96
|
|
789
|
+
* @brief Sets the playback volume.
|
|
790
|
+
* @param volume The playback volume. The value range is [0.0, 4.0].
|
|
791
|
+
* @order 113
|
|
792
|
+
*
|
|
618
793
|
*/
|
|
619
|
-
|
|
794
|
+
setBGMVolume(volume: number): void;
|
|
620
795
|
|
|
621
796
|
/** {en}
|
|
622
797
|
* @detail api
|
|
623
|
-
* @
|
|
624
|
-
* @
|
|
625
|
-
* @
|
|
626
|
-
*
|
|
627
|
-
*
|
|
628
|
-
* @notes <br>Call this method after calling setFilter.
|
|
629
|
-
* @order 97
|
|
630
|
-
* @param intensity The intensity. The value range is [0.0, 1.0].
|
|
798
|
+
* @brief Sets the audio capture volume.
|
|
799
|
+
* @notes <br>This method must be called after you call [start](#VeLiveMediaPlayer-start) to start playing background music.
|
|
800
|
+
* @order 114
|
|
801
|
+
* @param volume The audio capture volume. The value range is [0.0, 4.0].
|
|
802
|
+
*
|
|
631
803
|
*/
|
|
632
|
-
|
|
804
|
+
setVoiceVolume(volume: number): void;
|
|
633
805
|
|
|
634
806
|
/** {en}
|
|
635
807
|
* @detail api
|
|
636
|
-
* @
|
|
637
|
-
* @
|
|
638
|
-
*
|
|
639
|
-
*
|
|
640
|
-
*
|
|
641
|
-
*
|
|
642
|
-
* @notes <br>
|
|
643
|
-
* Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
644
|
-
* @order 98
|
|
808
|
+
* @brief Sets whether to loop the video.
|
|
809
|
+
* @param loop Whether to loop the video. <br>
|
|
810
|
+
* - true: Loop;
|
|
811
|
+
* - false: (Default) Do not loop.
|
|
812
|
+
* @order 115
|
|
813
|
+
*
|
|
645
814
|
*/
|
|
646
|
-
|
|
815
|
+
enableBGMLoop(loop: boolean): void;
|
|
816
|
+
}
|
|
817
|
+
|
|
818
|
+
export declare class VeLivePusherConfiguration {
|
|
819
|
+
protected _instance: any;
|
|
647
820
|
|
|
648
821
|
/** {en}
|
|
649
|
-
* @
|
|
650
|
-
* @
|
|
651
|
-
* @brief Advanced settings for special effects.
|
|
652
|
-
* @param callback A callback function that takes a handle as an argument.
|
|
653
|
-
* @param isGLThread Whether the callback is called in the GL thread.
|
|
654
|
-
* @param isAsync Whether the callback is executed synchronously.
|
|
655
|
-
* @notes <br>
|
|
656
|
-
* Call the method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}. Do not perform frequent synchronization operations in the main thread.
|
|
657
|
-
* @order 99
|
|
822
|
+
* @platform ios
|
|
823
|
+
* @brief The audio capture configurations. See VeLiveAudioCaptureConfiguration {@link #VeLiveAudioCaptureConfiguration} for details.
|
|
658
824
|
*/
|
|
659
|
-
|
|
825
|
+
get ios_audioCaptureConfig(): $p_i.VeLiveAudioCaptureConfiguration;
|
|
826
|
+
set ios_audioCaptureConfig(value: $p_i.VeLiveAudioCaptureConfiguration);
|
|
660
827
|
|
|
661
828
|
/** {en}
|
|
662
829
|
* @platform ios
|
|
663
|
-
* @
|
|
664
|
-
* @group 方法
|
|
665
|
-
* @brief Sets the path to the algorithm models of the special effects.
|
|
666
|
-
* @param path The path to the algorithm models of the special effects.
|
|
667
|
-
* @return <br>
|
|
668
|
-
* - 0: Success;
|
|
669
|
-
* - -1: Failure.
|
|
670
|
-
* @notes <br>
|
|
671
|
-
* Call this method after you set the special effects license by calling {@link #VeLiveVideoEffectManager#setupWithConfig setupWithConfig:}.
|
|
672
|
-
* @order 77
|
|
830
|
+
* @brief The time interval between each attempt to reconnect, in seconds. The default value is `5`.
|
|
673
831
|
*/
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
/** {en}
|
|
678
|
-
* @detail api
|
|
679
|
-
* @list overview
|
|
680
|
-
* @brief The live pusher.
|
|
681
|
-
*/
|
|
682
|
-
export declare class VeLivePusher {
|
|
832
|
+
get ios_reconnectIntervalSeconds(): $p_i.int;
|
|
833
|
+
set ios_reconnectIntervalSeconds(value: $p_i.int);
|
|
683
834
|
|
|
684
835
|
/** {en}
|
|
685
|
-
* @
|
|
686
|
-
* @
|
|
687
|
-
* @brief Sets the level of the output log.
|
|
688
|
-
* @param logLevel The log level. See VeLivePusherLogLevel {@link #VeLivePusherLogLevel} for details.
|
|
689
|
-
* @order 60
|
|
836
|
+
* @platform ios
|
|
837
|
+
* @brief The number of attempts to reconnect after the initial attempt fails. The default value is `3`.
|
|
690
838
|
*/
|
|
691
|
-
|
|
839
|
+
get ios_reconnectCount(): $p_i.int;
|
|
840
|
+
set ios_reconnectCount(value: $p_i.int);
|
|
841
|
+
|
|
842
|
+
/** {en}
|
|
843
|
+
* @platform ios
|
|
844
|
+
* @brief Advanced parameters. You can leave this parameter empty.
|
|
845
|
+
*/
|
|
846
|
+
get ios_extraParameters(): $p_i.NSDictionary;
|
|
847
|
+
set ios_extraParameters(value: $p_i.NSDictionary);
|
|
848
|
+
protected __init(...args: any[]): void;
|
|
849
|
+
protected __new_instance(...args: any[]): any;
|
|
692
850
|
|
|
693
851
|
/** {en}
|
|
694
|
-
* @platform android
|
|
695
852
|
* @detail api
|
|
696
|
-
* @
|
|
697
|
-
* @
|
|
698
|
-
*
|
|
699
|
-
* @order
|
|
853
|
+
* @brief Sets the video capture configurations.
|
|
854
|
+
* @return <br>
|
|
855
|
+
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
856
|
+
* @order 6
|
|
857
|
+
* @param config The video capture configurations. See VeLiveVideoCaptureConfiguration for details.
|
|
858
|
+
*
|
|
700
859
|
*/
|
|
701
|
-
|
|
860
|
+
setVideoCaptureConfig(config: VeLiveVideoCaptureConfiguration): void;
|
|
702
861
|
|
|
703
862
|
/** {en}
|
|
704
863
|
* @platform android
|
|
705
864
|
* @detail api
|
|
706
|
-
* @
|
|
707
|
-
* @
|
|
708
|
-
* @
|
|
709
|
-
*
|
|
865
|
+
* @brief Sets the time interval between each attempt to reconnect.
|
|
866
|
+
* @param interval The time interval between each attempt to reconnect, in seconds. The default value is `5`.
|
|
867
|
+
* @order 2
|
|
868
|
+
*
|
|
710
869
|
*/
|
|
711
|
-
|
|
870
|
+
android_setReconnectIntervalSeconds(interval: number): this;
|
|
712
871
|
|
|
713
872
|
/** {en}
|
|
714
873
|
* @platform android
|
|
715
874
|
* @detail api
|
|
716
|
-
* @
|
|
717
|
-
* @brief Gets the context of OpenGL.
|
|
875
|
+
* @brief Gets the time interval between each attempt to reconnect.
|
|
718
876
|
* @return <br>
|
|
719
|
-
*
|
|
720
|
-
* @order
|
|
877
|
+
* The time interval between each attempt to reconnect, in seconds.
|
|
878
|
+
* @order 3
|
|
879
|
+
*
|
|
721
880
|
*/
|
|
722
|
-
|
|
723
|
-
protected _instance: any;
|
|
724
|
-
protected __init(...args: any[]): void;
|
|
725
|
-
protected __new_instance(...args: any[]): $p_a.VeLivePusher | $p_i.VeLivePusher;
|
|
881
|
+
android_getReconnectIntervalSeconds(): number;
|
|
726
882
|
|
|
727
883
|
/** {en}
|
|
884
|
+
* @platform android
|
|
728
885
|
* @detail api
|
|
729
|
-
* @
|
|
730
|
-
* @
|
|
731
|
-
* @order
|
|
886
|
+
* @brief Sets the number of attempts to reconnect after the initial attempt fails.
|
|
887
|
+
* @param maxCount The number of attempts to reconnect after the initial attempt fails. The default value is `3`.
|
|
888
|
+
* @order 4
|
|
889
|
+
*
|
|
732
890
|
*/
|
|
733
|
-
|
|
891
|
+
android_setReconnectCount(maxCount: number): this;
|
|
734
892
|
|
|
735
893
|
/** {en}
|
|
894
|
+
* @platform android
|
|
736
895
|
* @detail api
|
|
737
|
-
* @
|
|
738
|
-
* @
|
|
739
|
-
*
|
|
740
|
-
* @
|
|
741
|
-
*
|
|
742
|
-
*
|
|
743
|
-
* @order 1
|
|
896
|
+
* @brief Gets the number of attempts to reconnect after the initial attempt fails.
|
|
897
|
+
* @return <br>
|
|
898
|
+
* The number of attempts to reconnect after the initial attempt fails.
|
|
899
|
+
* @order 5
|
|
900
|
+
*
|
|
901
|
+
*
|
|
744
902
|
*/
|
|
745
|
-
|
|
903
|
+
android_getReconnectCount(): number;
|
|
746
904
|
|
|
747
905
|
/** {en}
|
|
906
|
+
* @platform android
|
|
748
907
|
* @detail api
|
|
749
|
-
* @
|
|
750
|
-
* @
|
|
751
|
-
* @
|
|
752
|
-
*
|
|
753
|
-
* @notes <br>
|
|
754
|
-
* - This method must be called after the live pusher is created;
|
|
755
|
-
* - If you make multiple calls to this method, only the last call takes effect.
|
|
756
|
-
* @order 15
|
|
908
|
+
* @brief Gets the video capture configurations.
|
|
909
|
+
* @return <br>The video capture configurations. See VeLiveVideoCaptureConfiguration for details.
|
|
910
|
+
* @order 7
|
|
911
|
+
*
|
|
757
912
|
*/
|
|
758
|
-
|
|
913
|
+
android_getVideoCaptureConfig(): $p_a.VeLiveVideoCaptureConfiguration;
|
|
759
914
|
|
|
760
915
|
/** {en}
|
|
916
|
+
* @platform android
|
|
761
917
|
* @detail api
|
|
762
|
-
* @
|
|
763
|
-
* @
|
|
764
|
-
* @
|
|
765
|
-
* @order
|
|
918
|
+
* @brief Sets the audio capture configurations.
|
|
919
|
+
* @return <br>
|
|
920
|
+
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
921
|
+
* @order 7
|
|
922
|
+
* @param config The audio capture configurations. See VeLiveAudioCaptureConfiguration for details.
|
|
923
|
+
*
|
|
766
924
|
*/
|
|
767
|
-
|
|
925
|
+
android_setAudioCaptureConfig(config: $p_a.VeLiveAudioCaptureConfiguration): this;
|
|
768
926
|
|
|
769
927
|
/** {en}
|
|
928
|
+
* @platform android
|
|
770
929
|
* @detail api
|
|
771
|
-
* @
|
|
772
|
-
* @
|
|
773
|
-
* @
|
|
930
|
+
* @brief Gets the audio capture configurations.
|
|
931
|
+
* @return <br>The audio capture configurations. See VeLiveAudioCaptureConfiguration for details.
|
|
932
|
+
* @order 8
|
|
933
|
+
*
|
|
934
|
+
*
|
|
774
935
|
*/
|
|
775
|
-
|
|
936
|
+
android_getAudioCaptureConfig(): $p_a.VeLiveAudioCaptureConfiguration;
|
|
776
937
|
|
|
777
938
|
/** {en}
|
|
939
|
+
* @platform android
|
|
778
940
|
* @detail api
|
|
779
|
-
* @
|
|
780
|
-
* @
|
|
781
|
-
* @
|
|
782
|
-
*
|
|
783
|
-
*
|
|
784
|
-
*
|
|
785
|
-
* @order 17
|
|
941
|
+
* @brief Sets the context of the application.
|
|
942
|
+
* @param context The context of the application.
|
|
943
|
+
* @return <br>
|
|
944
|
+
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
945
|
+
* @order 9
|
|
946
|
+
*
|
|
786
947
|
*/
|
|
787
|
-
|
|
948
|
+
android_setContext(context: $p_a.Context): this;
|
|
788
949
|
|
|
789
950
|
/** {en}
|
|
951
|
+
* @platform android
|
|
790
952
|
* @detail api
|
|
791
|
-
* @
|
|
792
|
-
* @
|
|
793
|
-
*
|
|
794
|
-
* @order
|
|
795
|
-
*
|
|
953
|
+
* @brief Gets the context of the application.
|
|
954
|
+
* @return <br>
|
|
955
|
+
* The context of the application.
|
|
956
|
+
* @order 10
|
|
957
|
+
*
|
|
796
958
|
*
|
|
797
959
|
*/
|
|
798
|
-
|
|
960
|
+
android_getContext(): $p_a.Context;
|
|
799
961
|
|
|
800
962
|
/** {en}
|
|
963
|
+
* @platform android
|
|
801
964
|
* @detail api
|
|
802
|
-
* @
|
|
803
|
-
* @
|
|
804
|
-
* @
|
|
805
|
-
* @
|
|
965
|
+
* @brief Sets advanced parameters. You can leave this parameter empty. If you need to use it, please contact BytePlus technical support.
|
|
966
|
+
* @param params Extension parameters.
|
|
967
|
+
* @return <br>
|
|
968
|
+
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
969
|
+
* @order 11
|
|
970
|
+
*
|
|
971
|
+
*
|
|
806
972
|
*/
|
|
807
|
-
|
|
973
|
+
android_setExtraParameters(params: string): this;
|
|
808
974
|
|
|
809
975
|
/** {en}
|
|
976
|
+
* @platform android
|
|
810
977
|
* @detail api
|
|
811
|
-
* @
|
|
812
|
-
* @
|
|
813
|
-
*
|
|
814
|
-
* @order
|
|
815
|
-
*
|
|
978
|
+
* @brief Gets advanced parameters.
|
|
979
|
+
* @return <br>
|
|
980
|
+
* Advanced parameters.
|
|
981
|
+
* @order 12
|
|
982
|
+
*
|
|
983
|
+
*
|
|
816
984
|
*/
|
|
817
|
-
|
|
985
|
+
android_getExtraParams(): $p_a.LiveSdkSetting;
|
|
818
986
|
|
|
819
987
|
/** {en}
|
|
988
|
+
* @platform android
|
|
820
989
|
* @detail api
|
|
821
|
-
* @
|
|
822
|
-
* @
|
|
823
|
-
*
|
|
824
|
-
* @order
|
|
990
|
+
* @brief Creates the live pusher.
|
|
991
|
+
* @return <br>
|
|
992
|
+
* The live pusher. See VeLivePusher {@link #VeLivePusher} for details.
|
|
993
|
+
* @order 1
|
|
994
|
+
*
|
|
995
|
+
*
|
|
825
996
|
*/
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
997
|
+
android_build(): $p_a.VeLivePusher;
|
|
998
|
+
}
|
|
999
|
+
|
|
1000
|
+
export declare class VeLiveVideoFrame {
|
|
1001
|
+
constructor(width: number, height: number, pts: number, texId: number, isOes: boolean, matrix: Matrix);
|
|
1002
|
+
constructor(width: number, height: number, pts: number, byteBuffer: ByteBuffer);
|
|
1003
|
+
constructor(width: number, height: number, pts: number, data: ArrayBuffer);
|
|
1004
|
+
constructor();
|
|
1005
|
+
constructor();
|
|
1006
|
+
protected _instance: any;
|
|
1007
|
+
get width(): number;
|
|
1008
|
+
set width(value: number);
|
|
1009
|
+
get height(): number;
|
|
1010
|
+
set height(value: number);
|
|
1011
|
+
/**
|
|
1012
|
+
* @platform android
|
|
835
1013
|
*/
|
|
836
|
-
|
|
1014
|
+
get android_ptsUs(): number;
|
|
1015
|
+
set android_ptsUs(value: number);
|
|
1016
|
+
get textureId(): number;
|
|
1017
|
+
set textureId(value: number);
|
|
1018
|
+
get data(): any;
|
|
1019
|
+
set data(value: any);
|
|
837
1020
|
|
|
838
1021
|
/** {en}
|
|
839
|
-
* @
|
|
840
|
-
* @
|
|
841
|
-
* @brief Switches audio capture type.
|
|
842
|
-
* @notes <br>This method must be called after [startVideoCapture](#VeLivePusher-startvideocapture) is called.
|
|
843
|
-
* @order 23
|
|
844
|
-
* @param type The audio capture type. See VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} for details.
|
|
1022
|
+
* @platform ios
|
|
1023
|
+
* @brief The video buffer type. The default value is `VeLiveVideoBufferTypeUnknown`. See VeLiveVideoBufferType {@link #VeLiveVideoBufferType} for details.
|
|
845
1024
|
*/
|
|
846
|
-
|
|
1025
|
+
get ios_bufferType(): $p_i.VeLiveVideoBufferType;
|
|
1026
|
+
set ios_bufferType(value: $p_i.VeLiveVideoBufferType);
|
|
847
1027
|
|
|
848
1028
|
/** {en}
|
|
849
|
-
* @
|
|
850
|
-
* @
|
|
851
|
-
* @brief Gets the current video capture type.
|
|
852
|
-
* @return <br>
|
|
853
|
-
* The video capture type. See VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} for details.
|
|
854
|
-
* @order 24
|
|
1029
|
+
* @platform ios
|
|
1030
|
+
* @brief The pixel format. When `bufferType` is `VeLiveVideoBufferTypeNSData`, you must specify `pixelFormat`. See VeLivePixelFormat {@link #VeLivePixelFormat} for details.
|
|
855
1031
|
*/
|
|
856
|
-
|
|
1032
|
+
get ios_pixelFormat(): $p_i.VeLivePixelFormat;
|
|
1033
|
+
set ios_pixelFormat(value: $p_i.VeLivePixelFormat);
|
|
857
1034
|
|
|
858
1035
|
/** {en}
|
|
859
|
-
* @
|
|
860
|
-
* @
|
|
861
|
-
* @brief Gets the current audio capture type.
|
|
862
|
-
* @return <br>
|
|
863
|
-
* The audio capture type. See VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} for details.
|
|
864
|
-
* @order 25
|
|
1036
|
+
* @platform ios
|
|
1037
|
+
* @brief The rotation angle in a clockwise direction. See VeLiveVideoRotation {@link #VeLiveVideoRotation} for details.
|
|
865
1038
|
*/
|
|
866
|
-
|
|
1039
|
+
get ios_rotation(): $p_i.VeLiveVideoRotation;
|
|
1040
|
+
set ios_rotation(value: $p_i.VeLiveVideoRotation);
|
|
867
1041
|
|
|
868
1042
|
/** {en}
|
|
869
|
-
* @
|
|
870
|
-
* @
|
|
871
|
-
* @brief Sets a static image to push. When using this method, you must call startVideoCapture {@link #VeLivePusher#startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureCustomImage`.
|
|
872
|
-
* @param image The static image to push.
|
|
873
|
-
* @order 26
|
|
1043
|
+
* @platform ios
|
|
1044
|
+
* @brief The timestamp of the video frame, in μs.
|
|
874
1045
|
*/
|
|
875
|
-
|
|
1046
|
+
get ios_pts(): $p_i.CMTime;
|
|
1047
|
+
set ios_pts(value: $p_i.CMTime);
|
|
876
1048
|
|
|
877
1049
|
/** {en}
|
|
878
|
-
* @
|
|
879
|
-
* @
|
|
880
|
-
* @brief Gets the camera manager. With the camera manager, you can do the following:
|
|
881
|
-
* - Control the flashlight
|
|
882
|
-
* - Set the camera zoom
|
|
883
|
-
* - Set autofocus
|
|
884
|
-
* @return <br>
|
|
885
|
-
* The camera manager. See VeLiveCameraDevice {@link #VeLiveCameraDevice} for details.
|
|
886
|
-
* @notes <br>
|
|
887
|
-
* To use this method, you must first call startVideoCapture {@link #startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureFrontCamera` or `VeLiveVideoCaptureBackCamera`.
|
|
888
|
-
* @order 27
|
|
1050
|
+
* @platform ios
|
|
1051
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypePixelBuffer`.
|
|
889
1052
|
*/
|
|
890
|
-
|
|
1053
|
+
get ios_pixelBuffer(): $p_i.CVPixelBufferRef;
|
|
1054
|
+
set ios_pixelBuffer(value: $p_i.CVPixelBufferRef);
|
|
891
1055
|
|
|
892
1056
|
/** {en}
|
|
893
|
-
* @
|
|
894
|
-
* @
|
|
895
|
-
* @brief Sets video encoding parameters for the pushed stream.
|
|
896
|
-
* @notes This method can be called before or after live streaming starts.
|
|
897
|
-
* @order 28
|
|
898
|
-
* @param config The video encoding parameters, including the video resolution, encoding format, target bitrate, and GOP size. For details, see VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration}.
|
|
1057
|
+
* @platform ios
|
|
1058
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypeSampleBuffer`.
|
|
899
1059
|
*/
|
|
900
|
-
|
|
1060
|
+
get ios_sampleBuffer(): $p_i.CMSampleBufferRef;
|
|
1061
|
+
set ios_sampleBuffer(value: $p_i.CMSampleBufferRef);
|
|
1062
|
+
protected __init(...args: any[]): void;
|
|
1063
|
+
protected __new_instance(...args: any[]): any;
|
|
901
1064
|
|
|
902
1065
|
/** {en}
|
|
903
1066
|
* @platform android
|
|
904
1067
|
* @detail api
|
|
905
|
-
* @
|
|
906
|
-
*
|
|
907
|
-
* @return <br>
|
|
908
|
-
* The video encoding parameters, including the video resolution, encoding format, target bitrate, and GOP size. For details, see VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration}.
|
|
909
|
-
* @order 29
|
|
1068
|
+
* @brief Increases the reference count of the `VeLiveVideoFrame` object. Call this method to increase the reference count by 1 if you need to continue using the `VeLiveVideoFrame` object.
|
|
1069
|
+
*
|
|
910
1070
|
*/
|
|
911
|
-
|
|
1071
|
+
android_retain(): void;
|
|
912
1072
|
|
|
913
1073
|
/** {en}
|
|
1074
|
+
* @platform android
|
|
914
1075
|
* @detail api
|
|
915
|
-
* @
|
|
916
|
-
*
|
|
917
|
-
* @notes <br>This method must be called before calling [startPush](#VeLivePusher-startpush) or [startPushWithUrls](#VeLivePusher-startpushwithurls).
|
|
918
|
-
* @order 30
|
|
919
|
-
* @param config The audio encoding parameters. See [VeLiveAudioEncoderConfiguration](147521#VeLiveAudioEncoderConfiguration) for details.
|
|
1076
|
+
* @brief Releases the reference to the `VeLiveVideoFrame` object. Call this method to reduce the reference count by 1 when you no longer need to use the `VeLiveVideoFrame` object. When the reference count is reduced to 0, it means there is no reference to the object, and the object can be safely released or destroyed.
|
|
1077
|
+
*
|
|
920
1078
|
*/
|
|
921
|
-
|
|
1079
|
+
android_release(): void;
|
|
922
1080
|
|
|
923
1081
|
/** {en}
|
|
924
1082
|
* @platform android
|
|
925
1083
|
* @detail api
|
|
926
|
-
* @
|
|
927
|
-
* @
|
|
928
|
-
*
|
|
929
|
-
*
|
|
1084
|
+
* @brief Gets the data type of the video.
|
|
1085
|
+
* @return <br>
|
|
1086
|
+
* The data type of the video. See VeLiveVideoBufferType {@link #VeLiveVideoBufferType} for details.
|
|
1087
|
+
*
|
|
930
1088
|
*/
|
|
931
|
-
|
|
1089
|
+
android_getBufferType(): $p_a.VeLiveVideoBufferType;
|
|
932
1090
|
|
|
933
1091
|
/** {en}
|
|
1092
|
+
* @platform android
|
|
934
1093
|
* @detail api
|
|
935
|
-
* @
|
|
936
|
-
* @
|
|
937
|
-
* @
|
|
938
|
-
* @
|
|
1094
|
+
* @brief Sets the data type of the video.
|
|
1095
|
+
* @param bufferType The data type of the video. See VeLiveVideoBufferType {@link #VeLiveVideoBufferType} for details.
|
|
1096
|
+
* @return <br>
|
|
1097
|
+
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1098
|
+
*
|
|
939
1099
|
*/
|
|
940
|
-
|
|
1100
|
+
android_setBufferType(bufferType: $p_a.VeLiveVideoBufferType): this;
|
|
941
1101
|
|
|
942
1102
|
/** {en}
|
|
1103
|
+
* @platform android
|
|
943
1104
|
* @detail api
|
|
944
|
-
* @
|
|
945
|
-
* @
|
|
946
|
-
*
|
|
947
|
-
*
|
|
948
|
-
* When the first push stream address in the array is unavailable, the SDK will automatically switch to the subsequent addresses.
|
|
949
|
-
* @order 33
|
|
1105
|
+
* @brief Gets the pixel format.
|
|
1106
|
+
* @return <br>
|
|
1107
|
+
* The pixel format. See VeLivePixelFormat {@link #VeLivePixelFormat} for details.
|
|
1108
|
+
*
|
|
950
1109
|
*/
|
|
951
|
-
|
|
1110
|
+
android_getPixelFormat(): $p_a.VeLivePixelFormat;
|
|
952
1111
|
|
|
953
1112
|
/** {en}
|
|
1113
|
+
* @platform android
|
|
954
1114
|
* @detail api
|
|
955
|
-
* @
|
|
956
|
-
* @
|
|
957
|
-
* @
|
|
958
|
-
*
|
|
959
|
-
*
|
|
1115
|
+
* @brief Sets the pixel format.
|
|
1116
|
+
* @param pixelFormat The pixel format. See VeLivePixelFormat {@link #VeLivePixelFormat} for details.
|
|
1117
|
+
* @return <br>
|
|
1118
|
+
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1119
|
+
*
|
|
960
1120
|
*/
|
|
961
|
-
|
|
1121
|
+
android_setPixelFormat(pixelFormat: $p_a.VeLivePixelFormat): this;
|
|
962
1122
|
|
|
963
1123
|
/** {en}
|
|
1124
|
+
* @platform android
|
|
964
1125
|
* @detail api
|
|
965
|
-
* @
|
|
966
|
-
* @brief Checks whether the streaming is currently ongoing. You can use this method to query the status of the live pusher.
|
|
1126
|
+
* @brief Gets the rotation angle in a clockwise direction.
|
|
967
1127
|
* @return <br>
|
|
968
|
-
*
|
|
969
|
-
*
|
|
970
|
-
* - false: The streaming has stopped.
|
|
971
|
-
* @order 35
|
|
1128
|
+
* The rotation angle in a clockwise direction. See VeLiveVideoRotation {@link #VeLiveVideoRotation} for details.
|
|
1129
|
+
*
|
|
972
1130
|
*/
|
|
973
|
-
|
|
1131
|
+
android_getRotation(): $p_a.VeLiveVideoRotation;
|
|
974
1132
|
|
|
975
1133
|
/** {en}
|
|
1134
|
+
* @platform android
|
|
976
1135
|
* @detail api
|
|
977
|
-
* @
|
|
978
|
-
* @
|
|
979
|
-
* @param image The watermark image. Setting it to null means disabling watermarking.
|
|
980
|
-
* @param x The horizontal offset of the watermark, which represents the ratio of the distance between the left edge of the watermark and the left edge of the video to the width of the video. The value range is [0.0,1.0].
|
|
981
|
-
* @param y The vertical offset of the watermark, which represents the ratio of the distance between the top edge of the watermark and the top edge of the video to the height of the video. The value range is [0.0,1.0].
|
|
982
|
-
* @param scale The uniform scaling of the watermark. The value range is [0.0, 1.0].
|
|
1136
|
+
* @brief Sets the rotation angle in a clockwise direction.
|
|
1137
|
+
* @param rotation The rotation angle in a clockwise direction. See VeLiveVideoRotation {@link #VeLiveVideoRotation} for details.
|
|
983
1138
|
* @return <br>
|
|
984
|
-
*
|
|
985
|
-
*
|
|
986
|
-
* @order 36
|
|
1139
|
+
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1140
|
+
*
|
|
987
1141
|
*/
|
|
988
|
-
|
|
1142
|
+
android_setRotation(rotation: $p_a.VeLiveVideoRotation): this;
|
|
989
1143
|
|
|
990
1144
|
/** {en}
|
|
1145
|
+
* @platform android
|
|
991
1146
|
* @detail api
|
|
992
|
-
* @
|
|
993
|
-
* @
|
|
994
|
-
*
|
|
995
|
-
*
|
|
996
|
-
* @param config The recording configurations. See VeLiveFileRecorderConfiguration for details.
|
|
997
|
-
* @param listener The listener for recording events. See VeLiveFileRecordingListener for details.
|
|
1147
|
+
* @brief Gets the width of the video frame.
|
|
1148
|
+
* @return <br>
|
|
1149
|
+
* The width of the video frame.
|
|
1150
|
+
*
|
|
998
1151
|
*/
|
|
999
|
-
|
|
1152
|
+
android_getWidth(): number;
|
|
1000
1153
|
|
|
1001
1154
|
/** {en}
|
|
1155
|
+
* @platform android
|
|
1002
1156
|
* @detail api
|
|
1003
|
-
* @
|
|
1004
|
-
* @
|
|
1005
|
-
*
|
|
1006
|
-
*
|
|
1157
|
+
* @brief Gets the height of the video frame.
|
|
1158
|
+
* @return <br>
|
|
1159
|
+
* The height of the video frame.
|
|
1160
|
+
*
|
|
1007
1161
|
*/
|
|
1008
|
-
|
|
1162
|
+
android_getHeight(): number;
|
|
1009
1163
|
|
|
1010
1164
|
/** {en}
|
|
1165
|
+
* @platform android
|
|
1011
1166
|
* @detail api
|
|
1012
|
-
* @
|
|
1013
|
-
* @brief Set advanced configurations. You can contact BytePlus technical support for more information about how to use this method.
|
|
1014
|
-
* @param key The JSON key.
|
|
1015
|
-
* @param value The JSON value.
|
|
1167
|
+
* @brief Gets the width of the rotated video frame.
|
|
1016
1168
|
* @return <br>
|
|
1017
|
-
*
|
|
1018
|
-
*
|
|
1019
|
-
* @order 39
|
|
1169
|
+
* The width of the rotated video frame.
|
|
1170
|
+
*
|
|
1020
1171
|
*/
|
|
1021
|
-
|
|
1172
|
+
android_getRotatedWidth(): number;
|
|
1022
1173
|
|
|
1023
1174
|
/** {en}
|
|
1175
|
+
* @platform android
|
|
1024
1176
|
* @detail api
|
|
1025
|
-
* @
|
|
1026
|
-
* @brief Pushes an external video frame.
|
|
1027
|
-
* @param frame The external video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1177
|
+
* @brief Gets the height of the rotated video frame.
|
|
1028
1178
|
* @return <br>
|
|
1029
|
-
*
|
|
1030
|
-
*
|
|
1031
|
-
* @notes <br>
|
|
1032
|
-
* To use this method, you must first call startVideoCapture {@link #startVideoCapture} and set VeLiveVideoCaptureType {@link #VeLiveVideoCaptureType} to `VeLiveVideoCaptureExternal`.
|
|
1033
|
-
* @order 40
|
|
1179
|
+
* The height of the rotated video frame.
|
|
1180
|
+
*
|
|
1034
1181
|
*/
|
|
1035
|
-
|
|
1182
|
+
android_getRotatedHeight(): number;
|
|
1036
1183
|
|
|
1037
1184
|
/** {en}
|
|
1185
|
+
* @platform android
|
|
1038
1186
|
* @detail api
|
|
1039
|
-
* @
|
|
1040
|
-
* @brief Pushes an external audio frame.
|
|
1041
|
-
* @param frame The external audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
1187
|
+
* @brief Gets the timestamp of the video frame.
|
|
1042
1188
|
* @return <br>
|
|
1043
|
-
*
|
|
1044
|
-
*
|
|
1045
|
-
* @notes <br>
|
|
1046
|
-
* To use this method, you must first call startAudioCapture {@link #AustartdioCapture} and set VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} to `VeLiveAudioCaptureExternal`.
|
|
1047
|
-
* @order 41
|
|
1189
|
+
* The timestamp of the video frame, in μs.
|
|
1190
|
+
*
|
|
1048
1191
|
*/
|
|
1049
|
-
|
|
1192
|
+
android_getPts(): number;
|
|
1050
1193
|
|
|
1051
1194
|
/** {en}
|
|
1195
|
+
* @platform android
|
|
1052
1196
|
* @detail api
|
|
1053
|
-
* @
|
|
1054
|
-
* @
|
|
1055
|
-
*
|
|
1056
|
-
*
|
|
1197
|
+
* @brief Gets the texture ID.
|
|
1198
|
+
* @return <br>
|
|
1199
|
+
* The texture ID.
|
|
1200
|
+
*
|
|
1057
1201
|
*/
|
|
1058
|
-
|
|
1202
|
+
android_getTextureId(): number;
|
|
1059
1203
|
|
|
1060
1204
|
/** {en}
|
|
1205
|
+
* @platform android
|
|
1061
1206
|
* @detail api
|
|
1062
|
-
* @
|
|
1063
|
-
* @
|
|
1064
|
-
*
|
|
1065
|
-
*
|
|
1066
|
-
* - < 0: Failure.
|
|
1067
|
-
* @notes <br>This method must be called after calling [startPush](#VeLivePusher-startpush) or [startPushWithUrls](#VeLivePusher-startpushwithurls).
|
|
1068
|
-
* @order 43
|
|
1069
|
-
* @param key The JSON key.
|
|
1070
|
-
* @param value The JSON value.
|
|
1071
|
-
* @param repeat The number of times the message is sent. For example, if you set `repeat` to `20` and set `isKeyFrame` to `true`, the SDK will add the SEI message to 20 consecutive key frames starting from the time the method is called.
|
|
1072
|
-
* @param isKeyFrame Whether SEI messages are only included in key frames. <br>
|
|
1073
|
-
* - true: Add the SEI message to key frames only;
|
|
1074
|
-
* - false: Add the SEI message to all types of frames.
|
|
1075
|
-
* @param allowsCovered Whether to allow overwriting. <br>
|
|
1076
|
-
* - true: Allow overwriting;
|
|
1077
|
-
* - false: Do not allow overwriting.
|
|
1207
|
+
* @brief Gets the texture matrix.
|
|
1208
|
+
* @return <br>
|
|
1209
|
+
* The texture matrix.
|
|
1210
|
+
*
|
|
1078
1211
|
*/
|
|
1079
|
-
|
|
1212
|
+
android_getTextureMatrix(): $p_a.Matrix;
|
|
1080
1213
|
|
|
1081
1214
|
/** {en}
|
|
1215
|
+
* @platform android
|
|
1082
1216
|
* @detail api
|
|
1083
|
-
* @
|
|
1084
|
-
* @
|
|
1085
|
-
*
|
|
1086
|
-
*
|
|
1087
|
-
* - false: (Default) Do not mute.
|
|
1088
|
-
* @order 44
|
|
1217
|
+
* @brief Gets the video data in the format of ByteBuffer.
|
|
1218
|
+
* @return <br>
|
|
1219
|
+
* The video data in the format of ByteBuffer.
|
|
1220
|
+
*
|
|
1089
1221
|
*/
|
|
1090
|
-
|
|
1222
|
+
android_getBuffer(): $p_a.ByteBuffer;
|
|
1091
1223
|
|
|
1092
1224
|
/** {en}
|
|
1225
|
+
* @platform android
|
|
1093
1226
|
* @detail api
|
|
1094
|
-
* @
|
|
1095
|
-
* @brief Checks whether the stream is muted.
|
|
1227
|
+
* @brief Gets the video data in the format of byte [].
|
|
1096
1228
|
* @return <br>
|
|
1097
|
-
*
|
|
1098
|
-
*
|
|
1099
|
-
* @order 45
|
|
1229
|
+
* The video data in the format of byte [].
|
|
1230
|
+
*
|
|
1100
1231
|
*/
|
|
1101
|
-
|
|
1232
|
+
android_getData(): ArrayBuffer;
|
|
1102
1233
|
|
|
1103
1234
|
/** {en}
|
|
1235
|
+
* @platform android
|
|
1104
1236
|
* @detail api
|
|
1105
|
-
* @
|
|
1106
|
-
* @brief Gets the special effects manager. With the special effects manager, you can do the following:
|
|
1107
|
-
* - Set beauty AR
|
|
1108
|
-
* - Set special effects
|
|
1109
|
-
* - Set materials
|
|
1110
|
-
* - Set stickers
|
|
1111
|
-
* - Set filters
|
|
1237
|
+
* @brief Gets the internal release callback.
|
|
1112
1238
|
* @return <br>
|
|
1113
|
-
*
|
|
1114
|
-
*
|
|
1115
|
-
* You must first integrate the BytePlus Effects SDK before calling this method.
|
|
1116
|
-
* @order 46
|
|
1239
|
+
* The internal release callback.
|
|
1240
|
+
*
|
|
1117
1241
|
*/
|
|
1118
|
-
|
|
1242
|
+
android_getReleaseCallback(): $p_a.Runnable;
|
|
1119
1243
|
|
|
1120
1244
|
/** {en}
|
|
1245
|
+
* @platform android
|
|
1121
1246
|
* @detail api
|
|
1122
|
-
* @
|
|
1123
|
-
* @
|
|
1124
|
-
* @
|
|
1125
|
-
*
|
|
1247
|
+
* @brief Sets the internal release callback.
|
|
1248
|
+
* @param releaseCallback The internal release callback.
|
|
1249
|
+
* @return <br>
|
|
1250
|
+
* The video frame object. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1251
|
+
*
|
|
1126
1252
|
*/
|
|
1127
|
-
|
|
1253
|
+
android_setReleaseCallback(releaseCallback: $p_a.Runnable): this;
|
|
1128
1254
|
|
|
1129
1255
|
/** {en}
|
|
1130
|
-
* @
|
|
1131
|
-
* @
|
|
1132
|
-
* @brief Gets the audio device manager.
|
|
1133
|
-
* @return <br>
|
|
1134
|
-
* The audio device manager. See VeLiveAudioDevice {@link #VeLiveAudioDevice} for details.
|
|
1135
|
-
* @notes <br>
|
|
1136
|
-
* To use this method, you must first call startAudioCapture {@link #startAudioCapture} and set VeLiveAudioCaptureType {@link #VeLiveAudioCaptureType} to `VeLiveAudioCaptureMicrophone`.
|
|
1137
|
-
* @order 48
|
|
1256
|
+
* @platform ios
|
|
1257
|
+
* @brief Triggered when the SDK has completed processing the video frame and no longer needs the memory. You can release the memory for the video frame after receiving this callback.
|
|
1138
1258
|
*/
|
|
1139
|
-
|
|
1259
|
+
ios_releaseCallback(): void;
|
|
1260
|
+
}
|
|
1261
|
+
|
|
1262
|
+
export declare class VeLiveCameraDevice {
|
|
1263
|
+
protected _instance: any;
|
|
1264
|
+
protected __init(...args: any[]): void;
|
|
1265
|
+
protected __new_instance(...args: any[]): any;
|
|
1140
1266
|
|
|
1141
1267
|
/** {en}
|
|
1268
|
+
* @platform android
|
|
1142
1269
|
* @detail api
|
|
1143
|
-
* @
|
|
1144
|
-
* @
|
|
1145
|
-
*
|
|
1146
|
-
* @
|
|
1270
|
+
* @brief Gets the frame rate range supported by the camera.
|
|
1271
|
+
* @return <br>
|
|
1272
|
+
* The frame rate range supported by the camera.
|
|
1273
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1274
|
+
* @order 66
|
|
1275
|
+
*
|
|
1147
1276
|
*/
|
|
1148
|
-
|
|
1277
|
+
android_getRealFpsRange(): Array<$p_a.int>;
|
|
1149
1278
|
|
|
1150
1279
|
/** {en}
|
|
1151
1280
|
* @detail api
|
|
1152
|
-
* @
|
|
1153
|
-
* @brief Creates the media player.
|
|
1281
|
+
* @brief Enables or disables the flashlight.
|
|
1154
1282
|
* @return <br>
|
|
1155
|
-
*
|
|
1156
|
-
*
|
|
1283
|
+
* - 0: Success;
|
|
1284
|
+
* - ≠ 0: Failure.
|
|
1285
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1286
|
+
* @order 67
|
|
1287
|
+
* @param enable Whether to enable the flashlight. <br>
|
|
1288
|
+
* - true: Enable;
|
|
1289
|
+
* - false: (Default) Disable.
|
|
1290
|
+
*
|
|
1157
1291
|
*/
|
|
1158
|
-
|
|
1292
|
+
enableTorch(enable: boolean): number;
|
|
1159
1293
|
|
|
1160
1294
|
/** {en}
|
|
1161
1295
|
* @detail api
|
|
1162
|
-
* @
|
|
1163
|
-
* @brief Gets the audio and video mixer.
|
|
1296
|
+
* @brief Sets the zoom factor of the camera.
|
|
1164
1297
|
* @return <br>
|
|
1165
|
-
*
|
|
1166
|
-
*
|
|
1298
|
+
* - 0: Success;
|
|
1299
|
+
* - ≠ 0: Failure.
|
|
1300
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1301
|
+
* @order 68
|
|
1302
|
+
* @param ratio The zoom factor. The SDK uses the original size by default. The range of the zoom factor is [[getMinZoomRatio](#VeLiveCameraDevice-getminzoomratio),[getMaxZoomRatio](#VeLiveCameraDevice-getmaxzoomratio)].
|
|
1303
|
+
*
|
|
1167
1304
|
*/
|
|
1168
|
-
|
|
1305
|
+
setZoomRatio(ratio: number): number;
|
|
1169
1306
|
|
|
1170
1307
|
/** {en}
|
|
1171
|
-
* @platform android
|
|
1172
1308
|
* @detail api
|
|
1173
|
-
* @
|
|
1174
|
-
* @
|
|
1175
|
-
*
|
|
1176
|
-
*
|
|
1177
|
-
* @
|
|
1309
|
+
* @brief Gets the current zoom factor of the camera.
|
|
1310
|
+
* @return <br>
|
|
1311
|
+
* - ≤ 0: The camera does not support zooming;
|
|
1312
|
+
* - \\\\> 0: The zoom factor.
|
|
1313
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1314
|
+
* @order 68
|
|
1178
1315
|
*
|
|
1179
1316
|
*/
|
|
1180
|
-
|
|
1317
|
+
getCurrentZoomRatio(): number;
|
|
1181
1318
|
|
|
1182
1319
|
/** {en}
|
|
1183
|
-
* @platform android
|
|
1184
1320
|
* @detail api
|
|
1185
|
-
* @
|
|
1186
|
-
* @
|
|
1187
|
-
*
|
|
1321
|
+
* @brief Gets the maximum zoom factor of the camera.
|
|
1322
|
+
* @return <br>
|
|
1323
|
+
* - ≤ 0: The camera does not support zooming;
|
|
1324
|
+
* - \\\\> 0: The maximum zoom factor.
|
|
1325
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1326
|
+
* @order 69
|
|
1327
|
+
*
|
|
1188
1328
|
*/
|
|
1189
|
-
|
|
1329
|
+
getMaxZoomRatio(): number;
|
|
1190
1330
|
|
|
1191
1331
|
/** {en}
|
|
1192
|
-
* @platform android
|
|
1193
1332
|
* @detail api
|
|
1194
|
-
* @
|
|
1195
|
-
* @
|
|
1196
|
-
*
|
|
1333
|
+
* @brief Gets the minimum zoom factor of the camera.
|
|
1334
|
+
* @return <br>
|
|
1335
|
+
* - ≤ 0: The camera does not support zooming;
|
|
1336
|
+
* - \\\\> 0: The minimum zoom factor.
|
|
1337
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1338
|
+
* @order 70
|
|
1339
|
+
*
|
|
1197
1340
|
*/
|
|
1198
|
-
|
|
1341
|
+
getMinZoomRatio(): number;
|
|
1199
1342
|
|
|
1200
1343
|
/** {en}
|
|
1201
1344
|
* @detail api
|
|
1202
|
-
* @
|
|
1203
|
-
* @brief Adds a video frame listener.
|
|
1345
|
+
* @brief Checks whether autofocus is supported.
|
|
1204
1346
|
* @return <br>
|
|
1205
|
-
*
|
|
1206
|
-
*
|
|
1207
|
-
* @
|
|
1208
|
-
* @
|
|
1347
|
+
* - true: Supported;
|
|
1348
|
+
* - false: Not supported.
|
|
1349
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1350
|
+
* @order 71
|
|
1351
|
+
*
|
|
1209
1352
|
*/
|
|
1210
|
-
|
|
1353
|
+
isAutoFocusEnabled(): boolean;
|
|
1211
1354
|
|
|
1212
1355
|
/** {en}
|
|
1213
1356
|
* @detail api
|
|
1214
|
-
* @
|
|
1215
|
-
* @brief Removes the video frame listener.
|
|
1357
|
+
* @brief Enables or disables autofocus.
|
|
1216
1358
|
* @return <br>
|
|
1217
|
-
*
|
|
1218
|
-
*
|
|
1219
|
-
* @notes
|
|
1220
|
-
*
|
|
1221
|
-
* @
|
|
1222
|
-
*
|
|
1359
|
+
* - 0: Success;
|
|
1360
|
+
* - ≠ 0: Failure.
|
|
1361
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1362
|
+
* @order 72
|
|
1363
|
+
* @param enable Whether to enable autofocus.
|
|
1364
|
+
* - true: (Default) Enable;
|
|
1365
|
+
* - false: Disable.
|
|
1366
|
+
*
|
|
1223
1367
|
*/
|
|
1224
|
-
|
|
1368
|
+
enableAutoFocus(enable: boolean): number;
|
|
1225
1369
|
|
|
1226
1370
|
/** {en}
|
|
1227
1371
|
* @detail api
|
|
1228
|
-
* @
|
|
1229
|
-
* @brief Adds an audio frame listener.
|
|
1372
|
+
* @brief Sets the focus position of the camera.
|
|
1230
1373
|
* @return <br>
|
|
1231
|
-
*
|
|
1232
|
-
*
|
|
1233
|
-
* @
|
|
1234
|
-
* @
|
|
1374
|
+
* - 0: Success;
|
|
1375
|
+
* - ≠ 0: Failure.
|
|
1376
|
+
* @notes <br>Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1377
|
+
* @order 73
|
|
1378
|
+
* @param viewW The width of the current view.
|
|
1379
|
+
* @param viewH The height of the current view.
|
|
1380
|
+
* @param x The horizontal coordinate of the focus point from the upper left corner of the current view.
|
|
1381
|
+
* @param y The vertical coordinate of the focus point from the upper left corner of the current view.
|
|
1382
|
+
*
|
|
1235
1383
|
*/
|
|
1236
|
-
|
|
1384
|
+
setFocusPosition(viewW: number, viewH: number, x: number, y: number): number;
|
|
1237
1385
|
|
|
1238
1386
|
/** {en}
|
|
1239
1387
|
* @detail api
|
|
1240
|
-
* @
|
|
1241
|
-
* @
|
|
1242
|
-
*
|
|
1243
|
-
*
|
|
1244
|
-
*
|
|
1245
|
-
*
|
|
1246
|
-
* Calling this method will return a failure if the listener has not been added or has been removed.
|
|
1247
|
-
* @order 58
|
|
1248
|
-
* @param listener The listener. See VeLiveAudioFrameListener for details.
|
|
1388
|
+
* @brief Checks if manual exposure setting is available for the currently used camera.
|
|
1389
|
+
* @return - YES: Available.
|
|
1390
|
+
* - NO: Unavailable.
|
|
1391
|
+
* @notes You must call [startVideoCapture](#VeLivePusher-startvideocapture) to start SDK internal video capturing before calling this API.
|
|
1392
|
+
* @order 74
|
|
1393
|
+
*
|
|
1249
1394
|
*/
|
|
1250
|
-
|
|
1395
|
+
isExposurePositionSupported(): boolean;
|
|
1251
1396
|
|
|
1252
1397
|
/** {en}
|
|
1398
|
+
* @return - =0: Success.
|
|
1399
|
+
* - ≠0: Failure.
|
|
1253
1400
|
* @detail api
|
|
1254
|
-
* @
|
|
1255
|
-
* @
|
|
1256
|
-
*
|
|
1257
|
-
* @
|
|
1401
|
+
* @brief Sets the manual exposure position for the currently used camera.
|
|
1402
|
+
* @notes - You must call [startVideoCapture](#VeLivePusher-startvideocapture) to start SDK internal video capturing, and use SDK internal rendering before calling this API.
|
|
1403
|
+
* - The camera exposure point setting will be invalid after calling [stopVideoCapture](#VeLivePusher-stopvideocapture) to stop internal capturing.
|
|
1404
|
+
* @order 75
|
|
1405
|
+
* @param viewW The width of the current view.
|
|
1406
|
+
* @param viewH The height of the current view.
|
|
1407
|
+
* @param x The horizontal coordinate of the focus point from the upper left corner of the current view.
|
|
1408
|
+
* @param y The vertical coordinate of the focus point from the upper left corner of the current view.
|
|
1409
|
+
*
|
|
1258
1410
|
*/
|
|
1259
|
-
|
|
1411
|
+
setExposurePosition(viewW: number, viewH: number, x: number, y: number): number;
|
|
1260
1412
|
|
|
1261
1413
|
/** {en}
|
|
1262
|
-
* @
|
|
1414
|
+
* @return - ≤0: The camera does not support exposure;
|
|
1415
|
+
* - \\>0: The minimum exposure compensation.
|
|
1263
1416
|
* @detail api
|
|
1264
|
-
* @
|
|
1265
|
-
* @
|
|
1266
|
-
* @
|
|
1267
|
-
*
|
|
1417
|
+
* @brief Gets the minimum exposure compensation of the camera.
|
|
1418
|
+
* @notes Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1419
|
+
* @order 76
|
|
1420
|
+
*
|
|
1268
1421
|
*/
|
|
1269
|
-
|
|
1422
|
+
getMinExposureCompensation(): number;
|
|
1270
1423
|
|
|
1271
1424
|
/** {en}
|
|
1272
|
-
* @
|
|
1273
|
-
*
|
|
1274
|
-
* @
|
|
1275
|
-
* @
|
|
1276
|
-
*
|
|
1277
|
-
* @
|
|
1425
|
+
* @return - ≤0: The camera does not support exposure;
|
|
1426
|
+
* - \\>0: The maximum exposure compensation.
|
|
1427
|
+
* @detail api
|
|
1428
|
+
* @brief Gets the maximum exposure compensation of the camera.
|
|
1429
|
+
* @notes Call this method after calling [startVideoCapture](#VeLivePusher-startvideocapture) to start camera capture.
|
|
1430
|
+
* @order 77
|
|
1431
|
+
*
|
|
1278
1432
|
*/
|
|
1279
|
-
|
|
1433
|
+
getMaxExposureCompensation(): number;
|
|
1280
1434
|
|
|
1281
1435
|
/** {en}
|
|
1282
|
-
* @
|
|
1436
|
+
* @return - =0: Success.
|
|
1437
|
+
* - ≠0: Failure.
|
|
1283
1438
|
* @detail api
|
|
1284
|
-
* @
|
|
1285
|
-
* @
|
|
1286
|
-
*
|
|
1287
|
-
*
|
|
1288
|
-
*
|
|
1289
|
-
* @
|
|
1290
|
-
*
|
|
1291
|
-
* @param encodeFrame The external encoded video frame. See VeLiveVideoEncodeFrame {@link #VeLiveVideoEncodeFrame} for details.
|
|
1439
|
+
* @brief Sets the exposure compensation for the currently used camera.
|
|
1440
|
+
* @notes <br>
|
|
1441
|
+
* - You must call [startVideoCapture](#VeLivePusher-startvideocapture) to start SDK internal video capturing, and use SDK internal rendering before calling this API.
|
|
1442
|
+
* - The camera exposure compensation setting will be invalid after calling [stopVideoCapture](#VeLivePusher-stopvideocapture) to stop internal capturing.
|
|
1443
|
+
* @order 78
|
|
1444
|
+
* @param value The range of the exposure compensation is [[getMinExposureCompensation](#VeLiveCameraDevice-getminexposurecompensation),[getMaxExposureCompensation](#VeLiveCameraDevice-getmaxexposurecompensation)], Default to 0, which means no exposure compensation.
|
|
1445
|
+
*
|
|
1292
1446
|
*/
|
|
1293
|
-
|
|
1447
|
+
setExposureCompensation(value: number): number;
|
|
1294
1448
|
|
|
1295
1449
|
/** {en}
|
|
1296
1450
|
* @platform ios
|
|
1297
1451
|
* @detail api
|
|
1298
|
-
* @
|
|
1299
|
-
* @
|
|
1300
|
-
*
|
|
1301
|
-
*
|
|
1302
|
-
* @
|
|
1452
|
+
* @brief Checks whether flashlight is supported.
|
|
1453
|
+
* @return <br>
|
|
1454
|
+
* - YES: Supported;
|
|
1455
|
+
* - NO: Not supported.
|
|
1456
|
+
* @notes <br>Call this method after calling startVideoCapture:{@link #VeLivePusher#startVideoCapture} to start camera capture.
|
|
1457
|
+
* @order 49
|
|
1303
1458
|
*/
|
|
1304
|
-
|
|
1459
|
+
ios_isTorchSupported(): boolean;
|
|
1305
1460
|
|
|
1306
1461
|
/** {en}
|
|
1307
1462
|
* @platform ios
|
|
1308
1463
|
* @detail api
|
|
1309
|
-
* @
|
|
1310
|
-
* @
|
|
1311
|
-
* @
|
|
1312
|
-
* @
|
|
1464
|
+
* @brief Sets camera parameters.
|
|
1465
|
+
* @notes <br>Call this method after calling startVideoCapture:{@link #VeLivePusher#startVideoCapture} to start camera capture.
|
|
1466
|
+
* @order 64
|
|
1467
|
+
* @param parameter The parameter name (key) and the corresponding value.
|
|
1313
1468
|
*/
|
|
1314
|
-
|
|
1469
|
+
ios_setParameter(parameter: $p_i.NSDictionary): void;
|
|
1315
1470
|
|
|
1316
1471
|
/** {en}
|
|
1317
1472
|
* @platform ios
|
|
1318
1473
|
* @detail api
|
|
1319
|
-
* @
|
|
1320
|
-
* @brief Gets the context of EAGL. This context is shared across threads.
|
|
1474
|
+
* @brief Gets camera parameters.
|
|
1321
1475
|
* @return <br>
|
|
1322
|
-
*
|
|
1323
|
-
* @
|
|
1476
|
+
* The value of the camera parameter. The data type is determined by the parameter name you set when calling the method.
|
|
1477
|
+
* @notes <br>Call this method after calling startVideoCapture:{@link #VeLivePusher#startVideoCapture} to start camera capture.
|
|
1478
|
+
* @order 65
|
|
1479
|
+
* @param key The parameter name.
|
|
1324
1480
|
*/
|
|
1325
|
-
|
|
1326
|
-
}
|
|
1327
|
-
/**
|
|
1328
|
-
* @hidden
|
|
1329
|
-
*/
|
|
1330
|
-
export declare class Parameter extends $p_a.Parameter {
|
|
1481
|
+
ios_getParameter(key: string): $p_i.id;
|
|
1331
1482
|
}
|
|
1332
1483
|
|
|
1333
|
-
|
|
1334
|
-
* @detail api
|
|
1335
|
-
* @list overview
|
|
1336
|
-
* @brief The audio and video mixer.
|
|
1337
|
-
*/
|
|
1338
|
-
export declare class VeLiveMixerManager {
|
|
1484
|
+
export declare class VeLiveVideoEffectManager {
|
|
1339
1485
|
protected _instance: any;
|
|
1340
1486
|
protected __init(...args: any[]): void;
|
|
1341
|
-
protected __new_instance(...args: any[]):
|
|
1487
|
+
protected __new_instance(...args: any[]): any;
|
|
1342
1488
|
|
|
1343
1489
|
/** {en}
|
|
1344
1490
|
* @detail api
|
|
1345
|
-
* @
|
|
1346
|
-
* @brief Adds a video stream to the mixer.
|
|
1491
|
+
* @brief Initializes the special effects manager.
|
|
1347
1492
|
* @return <br>
|
|
1348
|
-
*
|
|
1349
|
-
*
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
/** {en}
|
|
1354
|
-
* @detail api
|
|
1355
|
-
* @group 方法
|
|
1356
|
-
* @brief Gets the ID of the primary video stream.
|
|
1357
|
-
* @order 83
|
|
1493
|
+
* - 0: Success;
|
|
1494
|
+
* - -1: Failure.
|
|
1495
|
+
* @order 89
|
|
1496
|
+
* @param config The special effects configurations. See VeLiveVideoEffectLicenseConfiguration for details.
|
|
1497
|
+
*
|
|
1358
1498
|
*/
|
|
1359
|
-
|
|
1499
|
+
setupWithConfig(config: VeLiveVideoEffectLicenseConfiguration): number;
|
|
1360
1500
|
|
|
1361
1501
|
/** {en}
|
|
1362
1502
|
* @detail api
|
|
1363
|
-
* @
|
|
1364
|
-
* @
|
|
1365
|
-
* @
|
|
1503
|
+
* @brief Updates the special effects license. This method is effective only if you authenticate the license online.
|
|
1504
|
+
* @param callback The result callback.
|
|
1505
|
+
* @notes <br>
|
|
1506
|
+
* - Call this method after you set the video effects license by calling setupWithConfig {@link #setupWithConfig};
|
|
1507
|
+
* - This method is an asynchronous operation.
|
|
1508
|
+
* @order 90
|
|
1509
|
+
*
|
|
1366
1510
|
*/
|
|
1367
|
-
|
|
1511
|
+
updateLicense(callback: (result: number, message: string) => void): void;
|
|
1368
1512
|
|
|
1369
1513
|
/** {en}
|
|
1370
|
-
* @platform android
|
|
1371
1514
|
* @detail api
|
|
1372
|
-
* @
|
|
1373
|
-
* @
|
|
1374
|
-
*
|
|
1515
|
+
* @brief Creates or destroys the special effects engine.
|
|
1516
|
+
* @return <br>
|
|
1517
|
+
* - 0: Success;
|
|
1518
|
+
* - -1: Failure.
|
|
1519
|
+
* @notes <br>
|
|
1520
|
+
* - Call this method after calling [setupWithConfig](broadcast-sdk-for-android-api#VeLiveVideoEffectManager-setupwithconfig) and [setAlgorithmModelPath](broadcast-sdk-for-android-api#VeLiveVideoEffectManager-setalgorithmmodelpath) ;
|
|
1521
|
+
* - This method does not enable or disable video special effects. Call [setComposeNodes](broadcast-sdk-for-android-api#VeLiveVideoEffectManager-setcomposenodes) after calling this method to enable video special effects;
|
|
1522
|
+
* - In most cases, the special effects engine will be destroyed when the effects manager is destroyed. However, if you have high performance requirements, you can call this method to manually destroy the special effects engine when you are not using special effects-related features;
|
|
1523
|
+
* - Creating or destroying the special effects engine repeatedly can result in increased processing time.
|
|
1524
|
+
* @order 92
|
|
1525
|
+
* @param enable Whether to create or destroy the special effects engine.<br>
|
|
1526
|
+
* - true: Create;
|
|
1527
|
+
* - false: (Default) Destroy.
|
|
1528
|
+
* @param callback [VeLiveVideoEffectCallback](broadcast-sdk-for-android-callback\\#VeLiveVideoEffectCallback), the listener for special effect events.
|
|
1529
|
+
*
|
|
1375
1530
|
*/
|
|
1376
|
-
|
|
1531
|
+
setEnable(enable: boolean, callback: (result: number, msg: string) => void): void;
|
|
1377
1532
|
|
|
1378
1533
|
/** {en}
|
|
1379
1534
|
* @platform android
|
|
1380
1535
|
* @detail api
|
|
1381
|
-
* @
|
|
1382
|
-
* @
|
|
1383
|
-
* @
|
|
1536
|
+
* @brief Sets the path to the algorithm model package of the special effects.
|
|
1537
|
+
* @param path The path to the algorithm model package of the special effects.
|
|
1538
|
+
* @return <br>
|
|
1539
|
+
* - 0: Success;
|
|
1540
|
+
* - -1: Failure.
|
|
1541
|
+
* @notes <br>
|
|
1542
|
+
* Call this method after you set the special effects license by calling setupWithConfig {@link #setupWithConfig}.
|
|
1543
|
+
* @order 91
|
|
1544
|
+
*
|
|
1384
1545
|
*/
|
|
1385
|
-
|
|
1546
|
+
android_setAlgorithmModelPath(path: string): number;
|
|
1386
1547
|
|
|
1387
1548
|
/** {en}
|
|
1388
1549
|
* @detail api
|
|
1389
|
-
* @
|
|
1390
|
-
* @
|
|
1391
|
-
* @
|
|
1392
|
-
*
|
|
1393
|
-
*
|
|
1550
|
+
* @brief Sets the special effects you want to apply to the video. You can choose effects from ComposeMakeup.bundle.
|
|
1551
|
+
* @param nodes The paths to the special effects resource.
|
|
1552
|
+
* @return <br>
|
|
1553
|
+
* - 0: Success;
|
|
1554
|
+
* - -1: Failure.
|
|
1555
|
+
* @notes <br>
|
|
1556
|
+
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable};
|
|
1557
|
+
* - If you make multiple calls to this method, only the last call takes effect;
|
|
1558
|
+
* - To add more effects to the existing effects settings, call appendComposeNodes {@link #VeLiveVideoEffectManager#appendComposeNodes}.
|
|
1559
|
+
* @order 93
|
|
1560
|
+
*
|
|
1394
1561
|
*/
|
|
1395
|
-
|
|
1562
|
+
setComposeNodes(nodes: Array<string>): number;
|
|
1396
1563
|
|
|
1397
1564
|
/** {en}
|
|
1398
1565
|
* @detail api
|
|
1399
|
-
* @
|
|
1400
|
-
* @
|
|
1401
|
-
* @
|
|
1402
|
-
*
|
|
1403
|
-
*
|
|
1566
|
+
* @brief Adds one or more effects to the existing effects settings that you have configured by calling setComposeNodes {@link #VeLiveVideoEffectManager#setComposeNodes}.
|
|
1567
|
+
* @param nodes The paths to the special effects resource.
|
|
1568
|
+
* @return <br>
|
|
1569
|
+
* - 0: Success;
|
|
1570
|
+
* - -1: Failure.
|
|
1571
|
+
* @notes <br>
|
|
1572
|
+
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
1573
|
+
* @order 94
|
|
1574
|
+
*
|
|
1404
1575
|
*/
|
|
1405
|
-
|
|
1576
|
+
appendComposeNodes(nodes: Array<string>): number;
|
|
1406
1577
|
|
|
1407
1578
|
/** {en}
|
|
1408
1579
|
* @detail api
|
|
1409
|
-
* @
|
|
1410
|
-
* @
|
|
1411
|
-
* @
|
|
1580
|
+
* @brief Removes one or more special effects resource set by the setComposeNodes{@link #VeLiveVideoEffectManager#setComposeNodes} or appendComposeNodes{@link #VeLiveVideoEffectManager#appendComposeNodes} methods.
|
|
1581
|
+
* @param nodes The paths to the special effects resource.
|
|
1582
|
+
* @return <br>
|
|
1583
|
+
* - 0: Success;
|
|
1584
|
+
* - -1: Failure.
|
|
1585
|
+
* @notes <br>
|
|
1586
|
+
* - Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
1587
|
+
* @order 94
|
|
1588
|
+
*
|
|
1412
1589
|
*/
|
|
1413
|
-
|
|
1590
|
+
removeComposeNodes(nodes: Array<string>): number;
|
|
1414
1591
|
|
|
1415
1592
|
/** {en}
|
|
1416
1593
|
* @detail api
|
|
1417
|
-
* @
|
|
1418
|
-
* @
|
|
1419
|
-
* @param
|
|
1420
|
-
* @
|
|
1594
|
+
* @brief Sets the intensity of a special effect.
|
|
1595
|
+
* @param node The path to the special effects resource.
|
|
1596
|
+
* @param key The key of the resource.
|
|
1597
|
+
* @param intensity The intensity of the effect. The value range is [0.0, 1.0].
|
|
1598
|
+
* @return <br>
|
|
1599
|
+
* - 0: Success;
|
|
1600
|
+
* - -1: Failure.
|
|
1601
|
+
* @notes <br>
|
|
1602
|
+
* - Call this method after calling setComposeNodes {@link #VeLiveVideoEffectManager#setComposeNodes} or appendComposeNodes {@link #VeLiveVideoEffectManager#appendComposeNodes};
|
|
1603
|
+
* - This method is only applicable to special effects that contain the three parameters mentioned above. For effects that do not have the intensity parameter, such as stickers, the method does not have any effect.
|
|
1604
|
+
* @order 95
|
|
1605
|
+
*
|
|
1421
1606
|
*/
|
|
1422
|
-
|
|
1607
|
+
updateComposerNodeIntensity(node: string, key: string, intensity: number): number;
|
|
1423
1608
|
|
|
1424
1609
|
/** {en}
|
|
1425
1610
|
* @detail api
|
|
1426
|
-
* @
|
|
1427
|
-
* @
|
|
1428
|
-
* @
|
|
1429
|
-
*
|
|
1611
|
+
* @brief Sets the color filter.
|
|
1612
|
+
* @param path The absolute path to the filter resource.
|
|
1613
|
+
* @return <br>
|
|
1614
|
+
* - 0: Success;
|
|
1615
|
+
* - -1: Failure.
|
|
1616
|
+
* @notes <br>
|
|
1617
|
+
* Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
1618
|
+
* @order 96
|
|
1619
|
+
*
|
|
1430
1620
|
*/
|
|
1431
|
-
|
|
1621
|
+
setFilter(path: string): number;
|
|
1432
1622
|
|
|
1433
1623
|
/** {en}
|
|
1434
|
-
* @platform ios
|
|
1435
1624
|
* @detail api
|
|
1436
|
-
* @
|
|
1437
|
-
* @
|
|
1438
|
-
*
|
|
1439
|
-
*
|
|
1440
|
-
* @
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
/** {en}
|
|
1445
|
-
* @platform ios
|
|
1625
|
+
* @brief Sets the intensity of the color filter.
|
|
1626
|
+
* @return <br>
|
|
1627
|
+
* - 0: Success;
|
|
1628
|
+
* - -1: Failure.
|
|
1629
|
+
* @notes <br>Call this method after calling setFilter.
|
|
1630
|
+
* @order 97
|
|
1631
|
+
* @param intensity The intensity. The value range is [0.0, 1.0].
|
|
1632
|
+
*
|
|
1446
1633
|
*/
|
|
1447
|
-
|
|
1448
|
-
}
|
|
1449
|
-
|
|
1450
|
-
/** {en}
|
|
1451
|
-
* @detail api
|
|
1452
|
-
* @list overview
|
|
1453
|
-
* @brief The media player.
|
|
1454
|
-
*/
|
|
1455
|
-
export declare class VeLiveMediaPlayer {
|
|
1456
|
-
protected _instance: any;
|
|
1457
|
-
protected __init(...args: any[]): void;
|
|
1458
|
-
protected __new_instance(...args: any[]): $p_a.VeLiveMediaPlayer | $p_i.VeLiveMediaPlayer;
|
|
1634
|
+
updateFilterIntensity(intensity: number): number;
|
|
1459
1635
|
|
|
1460
1636
|
/** {en}
|
|
1461
1637
|
* @detail api
|
|
1462
|
-
* @
|
|
1463
|
-
* @
|
|
1464
|
-
* @
|
|
1638
|
+
* @brief Sets the sticker.
|
|
1639
|
+
* @param path The absolute path to the sticker resource.
|
|
1640
|
+
* @return <br>
|
|
1641
|
+
* - 0: Success;
|
|
1642
|
+
* - -1: Failure.
|
|
1643
|
+
* @notes <br>
|
|
1644
|
+
* Call this method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}.
|
|
1645
|
+
* @order 98
|
|
1646
|
+
*
|
|
1465
1647
|
*/
|
|
1466
|
-
|
|
1648
|
+
setSticker(path: string): number;
|
|
1467
1649
|
|
|
1468
1650
|
/** {en}
|
|
1469
1651
|
* @detail api
|
|
1470
|
-
* @
|
|
1471
|
-
* @
|
|
1652
|
+
* @brief Advanced settings for special effects.
|
|
1653
|
+
* @param callback A callback function that takes a handle as an argument.
|
|
1654
|
+
* @param isGLThread Whether the callback is called in the GL thread.
|
|
1655
|
+
* @param isAsync Whether the callback is executed synchronously.
|
|
1472
1656
|
* @notes <br>
|
|
1473
|
-
*
|
|
1474
|
-
* @order
|
|
1475
|
-
*
|
|
1657
|
+
* Call the method after calling setEnable {@link #VeLiveVideoEffectManager #setEnable}. Do not perform frequent synchronization operations in the main thread.
|
|
1658
|
+
* @order 99
|
|
1659
|
+
*
|
|
1476
1660
|
*/
|
|
1477
|
-
|
|
1661
|
+
setAdvancedFeature(callback: (handle: void) => void, isGLThread: boolean, isAsync: boolean): number;
|
|
1478
1662
|
|
|
1479
1663
|
/** {en}
|
|
1664
|
+
* @platform ios
|
|
1480
1665
|
* @detail api
|
|
1481
|
-
* @
|
|
1482
|
-
* @
|
|
1483
|
-
* @param url The file path.
|
|
1666
|
+
* @brief Sets the path to the algorithm models of the special effects.
|
|
1667
|
+
* @param path The path to the algorithm models of the special effects.
|
|
1484
1668
|
* @return <br>
|
|
1485
|
-
*
|
|
1486
|
-
*
|
|
1487
|
-
* @
|
|
1669
|
+
* - 0: Success;
|
|
1670
|
+
* - -1: Failure.
|
|
1671
|
+
* @notes <br>
|
|
1672
|
+
* Call this method after you set the special effects license by calling setupWithConfig:{@link #VeLiveVideoEffectManager#setupWithConfig}.
|
|
1673
|
+
* @order 77
|
|
1488
1674
|
*/
|
|
1489
|
-
|
|
1675
|
+
ios_setAlgoModelPath(path: string): number;
|
|
1676
|
+
}
|
|
1677
|
+
|
|
1678
|
+
export declare class VeLiveMixerManager {
|
|
1679
|
+
protected _instance: any;
|
|
1680
|
+
protected __init(...args: any[]): void;
|
|
1681
|
+
protected __new_instance(...args: any[]): any;
|
|
1490
1682
|
|
|
1491
1683
|
/** {en}
|
|
1492
1684
|
* @detail api
|
|
1493
|
-
* @
|
|
1494
|
-
* @
|
|
1495
|
-
*
|
|
1496
|
-
*
|
|
1497
|
-
*
|
|
1685
|
+
* @brief Adds a video stream to the mixer.
|
|
1686
|
+
* @return <br>
|
|
1687
|
+
* The video stream ID.
|
|
1688
|
+
* @order 79
|
|
1689
|
+
*
|
|
1498
1690
|
*/
|
|
1499
|
-
|
|
1691
|
+
addVideoStream(): number;
|
|
1500
1692
|
|
|
1501
1693
|
/** {en}
|
|
1694
|
+
* @platform android
|
|
1502
1695
|
* @detail api
|
|
1503
|
-
* @
|
|
1504
|
-
* @brief Stops playback.
|
|
1696
|
+
* @brief Adds an audio stream to the mixer.
|
|
1505
1697
|
* @return <br>
|
|
1506
|
-
*
|
|
1507
|
-
*
|
|
1508
|
-
*
|
|
1509
|
-
* This method must be called after you call start {@link #start} to start playback.
|
|
1510
|
-
* @order 104
|
|
1698
|
+
* The audio stream ID.
|
|
1699
|
+
* @order 80
|
|
1700
|
+
*
|
|
1511
1701
|
*/
|
|
1512
|
-
|
|
1702
|
+
android_addAudioStream_type(type: $p_a.VeLiveAudioMixType): number;
|
|
1513
1703
|
|
|
1514
1704
|
/** {en}
|
|
1515
1705
|
* @detail api
|
|
1516
|
-
* @
|
|
1517
|
-
* @
|
|
1518
|
-
*
|
|
1519
|
-
* This method must be called after you call start {@link #start} to start playback.
|
|
1520
|
-
* @order 105
|
|
1706
|
+
* @brief Gets the ID of the primary video stream.
|
|
1707
|
+
* @order 83
|
|
1708
|
+
*
|
|
1521
1709
|
*/
|
|
1522
|
-
|
|
1710
|
+
getOriginVideoStream(): number;
|
|
1523
1711
|
|
|
1524
1712
|
/** {en}
|
|
1525
1713
|
* @detail api
|
|
1526
|
-
* @
|
|
1527
|
-
* @
|
|
1528
|
-
*
|
|
1529
|
-
* @order 106
|
|
1714
|
+
* @brief Gets the ID of the primary audio stream.
|
|
1715
|
+
* @order 84
|
|
1716
|
+
*
|
|
1530
1717
|
*/
|
|
1531
|
-
|
|
1718
|
+
getOriginAudioStream(): number;
|
|
1532
1719
|
|
|
1533
1720
|
/** {en}
|
|
1721
|
+
* @platform android
|
|
1534
1722
|
* @detail api
|
|
1535
|
-
* @
|
|
1536
|
-
* @
|
|
1537
|
-
*
|
|
1538
|
-
* - \\\\> 0: The duration of the media file, in milliseconds;
|
|
1539
|
-
* - ≤ 0: Failure.
|
|
1540
|
-
* @notes <br>This method must be called after you call [start](#VeLiveMediaPlayer-start) to start playback.
|
|
1541
|
-
* @order 107
|
|
1723
|
+
* @brief Gets the ID of the primary screen stream.
|
|
1724
|
+
* @order 85
|
|
1725
|
+
*
|
|
1542
1726
|
*/
|
|
1543
|
-
|
|
1727
|
+
android_getOriginScreenStream(): number;
|
|
1544
1728
|
|
|
1545
1729
|
/** {en}
|
|
1730
|
+
* @platform android
|
|
1546
1731
|
* @detail api
|
|
1547
|
-
* @
|
|
1548
|
-
* @
|
|
1549
|
-
*
|
|
1550
|
-
* @return <br>
|
|
1551
|
-
* - 0: Success;
|
|
1552
|
-
* - ≠ 0: Failure.
|
|
1553
|
-
* @order 108
|
|
1732
|
+
* @brief Gets the ID of the primary system audio stream.
|
|
1733
|
+
* @order 86
|
|
1734
|
+
*
|
|
1554
1735
|
*/
|
|
1555
|
-
|
|
1736
|
+
android_getOriginSystemAudioStream(): number;
|
|
1556
1737
|
|
|
1557
1738
|
/** {en}
|
|
1558
1739
|
* @detail api
|
|
1559
|
-
* @
|
|
1560
|
-
* @
|
|
1561
|
-
* @param
|
|
1562
|
-
*
|
|
1563
|
-
*
|
|
1564
|
-
* @order 109
|
|
1740
|
+
* @brief Sends a custom video frame with a specified stream ID.
|
|
1741
|
+
* @param frame The custom video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
1742
|
+
* @param streamId The ID of the video stream to mix.
|
|
1743
|
+
* @order 87
|
|
1744
|
+
*
|
|
1565
1745
|
*/
|
|
1566
|
-
|
|
1746
|
+
sendCustomVideoFrame(frame: VeLiveVideoFrame, streamId: number): void;
|
|
1567
1747
|
|
|
1568
1748
|
/** {en}
|
|
1569
1749
|
* @detail api
|
|
1570
|
-
* @
|
|
1571
|
-
* @
|
|
1572
|
-
* @param
|
|
1573
|
-
* @
|
|
1574
|
-
*
|
|
1750
|
+
* @brief Sends a custom audio frame with a specified stream ID.
|
|
1751
|
+
* @param frame The custom audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
1752
|
+
* @param streamId The ID of the audio stream to mix.
|
|
1753
|
+
* @order 88
|
|
1754
|
+
*
|
|
1575
1755
|
*/
|
|
1576
|
-
|
|
1756
|
+
sendCustomAudioFrame(frame: VeLiveAudioFrame, streamId: number): void;
|
|
1577
1757
|
|
|
1578
1758
|
/** {en}
|
|
1579
1759
|
* @detail api
|
|
1580
|
-
* @
|
|
1581
|
-
* @
|
|
1582
|
-
*
|
|
1583
|
-
* @order 111
|
|
1760
|
+
* @brief Updates the configurations for audio and video mixing.
|
|
1761
|
+
* @param mixDescription The updated configurations for audio and video mixing. See VeLiveStreamMixDescription {@link #VeLiveStreamMixDescription} for details.
|
|
1762
|
+
*
|
|
1584
1763
|
*/
|
|
1585
|
-
|
|
1764
|
+
updateStreamMixDescription(mixDescription: VeLiveStreamMixDescription): void;
|
|
1586
1765
|
|
|
1587
1766
|
/** {en}
|
|
1588
1767
|
* @detail api
|
|
1589
|
-
* @
|
|
1590
|
-
* @
|
|
1591
|
-
* @
|
|
1592
|
-
*
|
|
1593
|
-
* @order 112
|
|
1594
|
-
* @param listener The observer that listens for audio and video frames. For details, see VeLiveMediaPlayerFrameListener
|
|
1768
|
+
* @brief Removes a non-primary video stream from the mixer.
|
|
1769
|
+
* @param streamId The ID of the video stream to remove.
|
|
1770
|
+
* @order 80
|
|
1771
|
+
*
|
|
1595
1772
|
*/
|
|
1596
|
-
|
|
1773
|
+
removeVideoStream(streamId: number): void;
|
|
1597
1774
|
|
|
1598
1775
|
/** {en}
|
|
1599
1776
|
* @detail api
|
|
1600
|
-
* @
|
|
1601
|
-
* @
|
|
1602
|
-
* @
|
|
1603
|
-
*
|
|
1777
|
+
* @brief Removes a non-primary audio stream from the mixer.
|
|
1778
|
+
* @param streamId The ID of the audio stream to remove.
|
|
1779
|
+
* @order 82
|
|
1780
|
+
*
|
|
1604
1781
|
*/
|
|
1605
|
-
|
|
1782
|
+
removeAudioStream(streamId: number): void;
|
|
1606
1783
|
|
|
1607
1784
|
/** {en}
|
|
1785
|
+
* @platform ios
|
|
1608
1786
|
* @detail api
|
|
1609
|
-
* @
|
|
1610
|
-
* @
|
|
1611
|
-
* @
|
|
1612
|
-
* @order
|
|
1613
|
-
* @param volume The audio capture volume. The value range is [0.0, 4.0].
|
|
1787
|
+
* @brief Sets the volume of a non-primary audio stream. If you set VeLiveAudioMixType{@link #VeLiveAudioMixType} to `VeLiveAudioMixPlayAndPush`, this method takes effect on both the host and the audience sides.
|
|
1788
|
+
* @param streamId The audio stream ID.
|
|
1789
|
+
* @param volume The audio volume. The value range is [0.0,4.0].
|
|
1790
|
+
* @order 70
|
|
1614
1791
|
*/
|
|
1615
|
-
|
|
1792
|
+
ios_setAudioStream(streamId: number, volume: number): void;
|
|
1616
1793
|
|
|
1617
1794
|
/** {en}
|
|
1618
|
-
* @
|
|
1619
|
-
* @group 方法
|
|
1620
|
-
* @brief Sets whether to loop the video.
|
|
1621
|
-
* @param loop Whether to loop the video. <br>
|
|
1622
|
-
* - true: Loop;
|
|
1623
|
-
* - false: (Default) Do not loop.
|
|
1624
|
-
* @order 115
|
|
1795
|
+
* @platform ios
|
|
1625
1796
|
*/
|
|
1626
|
-
|
|
1797
|
+
ios_getAppAudioStream(): number;
|
|
1627
1798
|
}
|
|
1628
1799
|
|
|
1629
|
-
/** {en}
|
|
1630
|
-
* @detail api
|
|
1631
|
-
* @list overview
|
|
1632
|
-
* @brief The information of an audio frame.
|
|
1633
|
-
*/
|
|
1634
1800
|
export declare class VeLiveAudioFrame {
|
|
1801
|
+
constructor();
|
|
1802
|
+
constructor(sampleRate: VeLiveAudioSampleRate, channel: VeLiveAudioChannel, pts: number, buffer: ByteBuffer);
|
|
1803
|
+
constructor();
|
|
1635
1804
|
protected _instance: any;
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
get bufferType(): any;
|
|
1639
|
-
set bufferType(value: any);
|
|
1805
|
+
get bufferType(): VeLiveAudioBufferType;
|
|
1806
|
+
set bufferType(value: VeLiveAudioBufferType);
|
|
1640
1807
|
get sampleRate(): any;
|
|
1641
1808
|
set sampleRate(value: any);
|
|
1642
1809
|
get channels(): any;
|
|
@@ -1658,276 +1825,143 @@ export declare class VeLiveAudioFrame {
|
|
|
1658
1825
|
set android_samplesPerChannel(value: any);
|
|
1659
1826
|
|
|
1660
1827
|
/** {en}
|
|
1828
|
+
* @platform ios
|
|
1829
|
+
* @brief The audio frame timestamp, in μs, when `bufferType` is `VeLiveAudioBufferNSData`.
|
|
1830
|
+
*/
|
|
1831
|
+
get ios_pts(): $p_i.CMTime;
|
|
1832
|
+
set ios_pts(value: $p_i.CMTime);
|
|
1833
|
+
|
|
1834
|
+
/** {en}
|
|
1835
|
+
* @platform ios
|
|
1836
|
+
* @brief The audio data, when `bufferType` is `VeLiveAudioBufferTypeSampleBuffer`.
|
|
1837
|
+
*/
|
|
1838
|
+
get ios_sampleBuffer(): $p_i.CMSampleBufferRef;
|
|
1839
|
+
set ios_sampleBuffer(value: $p_i.CMSampleBufferRef);
|
|
1840
|
+
|
|
1841
|
+
/** {en}
|
|
1842
|
+
* @platform ios
|
|
1843
|
+
* @brief The audio data, when `bufferType` is `VeLiveAudioBufferTypeNSData`. The audio data is of type float32 and is stored in little-endian byte order.
|
|
1844
|
+
*/
|
|
1845
|
+
get ios_data(): $p_i.NSData;
|
|
1846
|
+
set ios_data(value: $p_i.NSData);
|
|
1847
|
+
protected __init(...args: any[]): void;
|
|
1848
|
+
protected __new_instance(...args: any[]): any;
|
|
1849
|
+
|
|
1850
|
+
/** {en}
|
|
1851
|
+
* @platform android
|
|
1661
1852
|
* @detail api
|
|
1662
|
-
* @group 方法
|
|
1663
1853
|
* @brief Gets the audio data type.
|
|
1664
1854
|
* @return <br>
|
|
1665
1855
|
* The audio data type. See VeLiveAudioBufferType {@link #VeLiveAudioBufferType} for details.
|
|
1856
|
+
*
|
|
1666
1857
|
*/
|
|
1667
|
-
|
|
1858
|
+
android_getBufferType(): $p_a.VeLiveAudioBufferType;
|
|
1668
1859
|
|
|
1669
1860
|
/** {en}
|
|
1861
|
+
* @platform android
|
|
1670
1862
|
* @detail api
|
|
1671
|
-
* @group 方法
|
|
1672
1863
|
* @brief Gets the audio sample rate.
|
|
1673
1864
|
* @return <br>
|
|
1674
1865
|
* The audio sample rate. See VeLiveAudioSampleRate {@link #VeLiveAudioSampleRate} for details.
|
|
1866
|
+
*
|
|
1675
1867
|
*/
|
|
1676
|
-
|
|
1868
|
+
android_getSampleRate(): $p_a.VeLiveAudioSampleRate;
|
|
1677
1869
|
|
|
1678
1870
|
/** {en}
|
|
1871
|
+
* @platform android
|
|
1679
1872
|
* @detail api
|
|
1680
|
-
* @group 方法
|
|
1681
1873
|
* @brief Gets the number of audio channels.
|
|
1682
1874
|
* @return <br>
|
|
1683
1875
|
* The number of audio channels. See VeLiveAudioChannel {@link #VeLiveAudioChannel} for details.
|
|
1876
|
+
*
|
|
1684
1877
|
*/
|
|
1685
|
-
|
|
1878
|
+
android_getChannels(): $p_a.VeLiveAudioChannel;
|
|
1686
1879
|
|
|
1687
1880
|
/** {en}
|
|
1688
1881
|
* @platform android
|
|
1689
1882
|
* @detail api
|
|
1690
|
-
* @group 方法
|
|
1691
1883
|
* @brief Gets the audio bit depth.
|
|
1692
1884
|
* @return <br>
|
|
1693
1885
|
* The audio bit depth.
|
|
1886
|
+
*
|
|
1694
1887
|
*/
|
|
1695
1888
|
android_getSamplesPerChannel(): number;
|
|
1696
1889
|
|
|
1697
1890
|
/** {en}
|
|
1891
|
+
* @platform android
|
|
1698
1892
|
* @detail api
|
|
1699
|
-
* @group 方法
|
|
1700
1893
|
* @brief Gets the audio timestamp, in μs.
|
|
1701
1894
|
* @return <br>
|
|
1702
1895
|
* The timestamp of the audio frame, in μs.
|
|
1896
|
+
*
|
|
1703
1897
|
*/
|
|
1704
|
-
|
|
1898
|
+
android_getPts(): number;
|
|
1705
1899
|
|
|
1706
1900
|
/** {en}
|
|
1707
1901
|
* @platform android
|
|
1708
1902
|
* @detail api
|
|
1709
|
-
* @group 方法
|
|
1710
1903
|
* @brief Gets the audio data. The audio data is of type float32 and is stored in little-endian byte order.
|
|
1711
1904
|
* @return <br>
|
|
1712
1905
|
* The audio data in the format of ByteBuffer.
|
|
1906
|
+
*
|
|
1713
1907
|
*/
|
|
1714
|
-
android_getBuffer():
|
|
1908
|
+
android_getBuffer(): $p_a.ByteBuffer;
|
|
1715
1909
|
}
|
|
1716
1910
|
|
|
1717
|
-
/** {en}
|
|
1718
|
-
* @detail api
|
|
1719
|
-
* @list overview
|
|
1720
|
-
* @brief The audio device manager.
|
|
1721
|
-
*/
|
|
1722
1911
|
export declare class VeLiveAudioDevice {
|
|
1723
1912
|
protected _instance: any;
|
|
1724
1913
|
protected __init(...args: any[]): void;
|
|
1725
|
-
protected __new_instance(...args: any[]):
|
|
1914
|
+
protected __new_instance(...args: any[]): any;
|
|
1726
1915
|
|
|
1727
1916
|
/** {en}
|
|
1728
1917
|
* @detail api
|
|
1729
|
-
* @group 方法
|
|
1730
1918
|
* @brief Sets the volume.
|
|
1731
1919
|
* @param level The volume. The value range is [0.0, 4.0].
|
|
1732
1920
|
* @order 74
|
|
1921
|
+
*
|
|
1733
1922
|
*/
|
|
1734
1923
|
setVoiceLoudness(level: number): void;
|
|
1735
1924
|
|
|
1736
1925
|
/** {en}
|
|
1737
1926
|
* @detail api
|
|
1738
|
-
* @group 方法
|
|
1739
1927
|
* @brief Gets the current volume.
|
|
1740
1928
|
* @return <br>
|
|
1741
1929
|
* The current volume.
|
|
1742
1930
|
* @order 75
|
|
1931
|
+
*
|
|
1743
1932
|
*/
|
|
1744
1933
|
getVoiceLoudness(): number;
|
|
1745
1934
|
|
|
1746
1935
|
/** {en}
|
|
1747
1936
|
* @detail api
|
|
1748
|
-
* @group 方法
|
|
1749
1937
|
* @brief Checks whether in-ear monitoring is supported.
|
|
1750
1938
|
* @return <br>
|
|
1751
1939
|
* - true: Supported;
|
|
1752
1940
|
* - false: Not supported.
|
|
1753
1941
|
* @order 76
|
|
1942
|
+
*
|
|
1754
1943
|
*/
|
|
1755
1944
|
isSupportHardwareEcho(): boolean;
|
|
1756
1945
|
|
|
1757
1946
|
/** {en}
|
|
1758
1947
|
* @detail api
|
|
1759
|
-
* @group 方法
|
|
1760
1948
|
* @brief Enables or disables in-ear monitoring.
|
|
1761
1949
|
* @param enable Whether to enable in-ear monitoring. <br>
|
|
1762
1950
|
* - true: Enable;
|
|
1763
1951
|
* - false: (Default) Disable.
|
|
1764
1952
|
* @order 77
|
|
1953
|
+
*
|
|
1765
1954
|
*/
|
|
1766
1955
|
enableEcho(enable: boolean): void;
|
|
1767
1956
|
|
|
1768
1957
|
/** {en}
|
|
1769
1958
|
* @detail api
|
|
1770
|
-
* @group 方法
|
|
1771
1959
|
* @brief Checks whether in-ear monitoring is enabled.
|
|
1772
1960
|
* @return <br>
|
|
1773
1961
|
* - true: Enabled;
|
|
1774
1962
|
* - false: Disabled.
|
|
1775
1963
|
* @order 78
|
|
1776
|
-
*/
|
|
1777
|
-
isEnableEcho(): boolean;
|
|
1778
|
-
}
|
|
1779
|
-
|
|
1780
|
-
/** {en}
|
|
1781
|
-
* @detail api
|
|
1782
|
-
* @list overview
|
|
1783
|
-
* @brief The initial configurations for the live pusher.
|
|
1784
|
-
*/
|
|
1785
|
-
export declare class VeLivePusherConfiguration {
|
|
1786
|
-
protected _instance: any;
|
|
1787
|
-
protected __init(...args: any[]): void;
|
|
1788
|
-
protected __new_instance(...args: any[]): $p_a.VeLivePusherConfiguration | $p_i.VeLivePusherConfiguration;
|
|
1789
|
-
|
|
1790
|
-
/** {en}
|
|
1791
|
-
* @detail api
|
|
1792
|
-
* @group 方法
|
|
1793
|
-
* @brief Sets the time interval between each attempt to reconnect.
|
|
1794
|
-
* @param interval The time interval between each attempt to reconnect, in seconds. The default value is `5`.
|
|
1795
|
-
* @order 2
|
|
1796
|
-
*/
|
|
1797
|
-
setReconnectIntervalSeconds(interval: number): VeLivePusherConfiguration;
|
|
1798
|
-
|
|
1799
|
-
/** {en}
|
|
1800
|
-
* @detail api
|
|
1801
|
-
* @group 方法
|
|
1802
|
-
* @brief Gets the time interval between each attempt to reconnect.
|
|
1803
|
-
* @return <br>
|
|
1804
|
-
* The time interval between each attempt to reconnect, in seconds.
|
|
1805
|
-
* @order 3
|
|
1806
|
-
*/
|
|
1807
|
-
getReconnectIntervalSeconds(): number;
|
|
1808
|
-
|
|
1809
|
-
/** {en}
|
|
1810
|
-
* @detail api
|
|
1811
|
-
* @group 方法
|
|
1812
|
-
* @brief Sets the number of attempts to reconnect after the initial attempt fails.
|
|
1813
|
-
* @param maxCount The number of attempts to reconnect after the initial attempt fails. The default value is `3`.
|
|
1814
|
-
* @order 4
|
|
1815
|
-
*/
|
|
1816
|
-
setReconnectCount(maxCount: number): VeLivePusherConfiguration;
|
|
1817
|
-
|
|
1818
|
-
/** {en}
|
|
1819
|
-
* @detail api
|
|
1820
|
-
* @group 方法
|
|
1821
|
-
* @brief Gets the number of attempts to reconnect after the initial attempt fails.
|
|
1822
|
-
* @return <br>
|
|
1823
|
-
* The number of attempts to reconnect after the initial attempt fails.
|
|
1824
|
-
* @order 5
|
|
1825
|
-
*
|
|
1826
|
-
*/
|
|
1827
|
-
getReconnectCount(): number;
|
|
1828
|
-
|
|
1829
|
-
/** {en}
|
|
1830
|
-
* @detail api
|
|
1831
|
-
* @group 方法
|
|
1832
|
-
* @brief Sets the video capture configurations.
|
|
1833
|
-
* @return <br>
|
|
1834
|
-
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
1835
|
-
* @order 6
|
|
1836
|
-
* @param config The video capture configurations. See VeLiveVideoCaptureConfiguration for details.
|
|
1837
|
-
*/
|
|
1838
|
-
setVideoCaptureConfig(config: VeLiveVideoCaptureConfiguration): VeLivePusherConfiguration;
|
|
1839
|
-
|
|
1840
|
-
/** {en}
|
|
1841
|
-
* @detail api
|
|
1842
|
-
* @group 方法
|
|
1843
|
-
* @brief Gets the video capture configurations.
|
|
1844
|
-
* @return <br>The video capture configurations. See VeLiveVideoCaptureConfiguration for details.
|
|
1845
|
-
* @order 7
|
|
1846
|
-
*/
|
|
1847
|
-
getVideoCaptureConfig(): VeLiveVideoCaptureConfiguration;
|
|
1848
|
-
|
|
1849
|
-
/** {en}
|
|
1850
|
-
* @detail api
|
|
1851
|
-
* @group 方法
|
|
1852
|
-
* @brief Sets the audio capture configurations.
|
|
1853
|
-
* @return <br>
|
|
1854
|
-
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
1855
|
-
* @order 7
|
|
1856
|
-
* @param config The audio capture configurations. See VeLiveAudioCaptureConfiguration for details.
|
|
1857
|
-
*/
|
|
1858
|
-
setAudioCaptureConfig(config: VeLiveAudioCaptureConfiguration): VeLivePusherConfiguration;
|
|
1859
|
-
|
|
1860
|
-
/** {en}
|
|
1861
|
-
* @detail api
|
|
1862
|
-
* @group 方法
|
|
1863
|
-
* @brief Gets the audio capture configurations.
|
|
1864
|
-
* @return <br>The audio capture configurations. See VeLiveAudioCaptureConfiguration for details.
|
|
1865
|
-
* @order 8
|
|
1866
|
-
*
|
|
1867
|
-
*/
|
|
1868
|
-
getAudioCaptureConfig(): VeLiveAudioCaptureConfiguration;
|
|
1869
|
-
|
|
1870
|
-
/** {en}
|
|
1871
|
-
* @platform android
|
|
1872
|
-
* @detail api
|
|
1873
|
-
* @group 方法
|
|
1874
|
-
* @brief Sets the context of the application.
|
|
1875
|
-
* @param context The context of the application.
|
|
1876
|
-
* @return <br>
|
|
1877
|
-
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
1878
|
-
* @order 9
|
|
1879
|
-
*/
|
|
1880
|
-
android_setContext(context: $p_a.Context): VeLivePusherConfiguration;
|
|
1881
|
-
|
|
1882
|
-
/** {en}
|
|
1883
|
-
* @platform android
|
|
1884
|
-
* @detail api
|
|
1885
|
-
* @group 方法
|
|
1886
|
-
* @brief Gets the context of the application.
|
|
1887
|
-
* @return <br>
|
|
1888
|
-
* The context of the application.
|
|
1889
|
-
* @order 10
|
|
1890
|
-
*
|
|
1891
|
-
*/
|
|
1892
|
-
android_getContext(): $p_a.Context;
|
|
1893
|
-
|
|
1894
|
-
/** {en}
|
|
1895
|
-
* @detail api
|
|
1896
|
-
* @group 方法
|
|
1897
|
-
* @brief Sets advanced parameters. You can leave this parameter empty. If you need to use it, please contact BytePlus technical support.
|
|
1898
|
-
* @param params Extension parameters.
|
|
1899
|
-
* @return <br>
|
|
1900
|
-
* The pusher configurations. See VeLivePusherConfiguration {@link #VeLivePusherConfiguration} for details.
|
|
1901
|
-
* @order 11
|
|
1902
|
-
*
|
|
1903
|
-
*/
|
|
1904
|
-
setExtraParameters(params: string): VeLivePusherConfiguration;
|
|
1905
|
-
|
|
1906
|
-
/** {en}
|
|
1907
|
-
* @platform android
|
|
1908
|
-
* @detail api
|
|
1909
|
-
* @group 方法
|
|
1910
|
-
* @brief Gets advanced parameters.
|
|
1911
|
-
* @return <br>
|
|
1912
|
-
* Advanced parameters.
|
|
1913
|
-
* @order 12
|
|
1914
|
-
*
|
|
1915
|
-
*/
|
|
1916
|
-
android_getExtraParams(): $p_a.LiveSdkSetting;
|
|
1917
|
-
|
|
1918
|
-
/** {en}
|
|
1919
|
-
* @platform android
|
|
1920
|
-
* @detail api
|
|
1921
|
-
* @group 方法
|
|
1922
|
-
* @brief Creates the live pusher.
|
|
1923
|
-
* @return <br>
|
|
1924
|
-
* The live pusher. See VeLivePusher {@link #VeLivePusher} for details.
|
|
1925
|
-
* @order 1
|
|
1926
1964
|
*
|
|
1927
1965
|
*/
|
|
1928
|
-
|
|
1929
|
-
}
|
|
1930
|
-
export declare class VeLiveFileRecorderManager extends $p_i.VeLiveFileRecorderManager {
|
|
1931
|
-
}
|
|
1932
|
-
export declare class VeLivePusherScreenCapture extends $p_i.VeLivePusher {
|
|
1966
|
+
isEnableEcho(): boolean;
|
|
1933
1967
|
}
|