@byteplus/react-native-live-push 1.1.3-rc.4 → 1.3.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/build.gradle +2 -2
- package/android/src/main/java/com/volcengine/velive/rn/push/ClassHelper.java +9 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/NativeVariableManager.java +5 -8
- package/android/src/main/java/com/volcengine/velive/rn/push/VeLivePushModule.java +1 -0
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerManager.java +2 -4
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerView.java +50 -145
- package/android/src/main/java/com/volcengine/velive/rn/push/mixer/MixerViewManager.java +1 -37
- package/ios/VeLiveMixerHelper.h +16 -11
- package/ios/VeLiveMixerHelper.m +39 -13
- package/ios/VeLiveMixerView.h +1 -8
- package/ios/VeLiveMixerView.m +178 -231
- package/ios/VeLiveMixerViewManager.m +2 -38
- package/lib/commonjs/index.js +23205 -20306
- package/lib/commonjs/typescript/android/index.d.ts +0 -3
- package/lib/commonjs/typescript/codegen/android/api.d.ts +190 -644
- package/lib/commonjs/typescript/codegen/android/callback.d.ts +234 -2
- package/lib/commonjs/typescript/codegen/android/errorcode.d.ts +66 -0
- package/lib/commonjs/typescript/codegen/android/keytype.d.ts +1014 -181
- package/lib/commonjs/typescript/codegen/ios/api.d.ts +890 -0
- package/lib/commonjs/typescript/codegen/ios/callback.d.ts +162 -0
- package/lib/commonjs/typescript/codegen/ios/errorcode.d.ts +101 -1
- package/lib/commonjs/typescript/codegen/ios/keytype.d.ts +694 -0
- package/lib/commonjs/typescript/codegen/pack/api.d.ts +303 -686
- package/lib/commonjs/typescript/codegen/pack/callback.d.ts +37 -38
- package/lib/commonjs/typescript/codegen/pack/errorcode.d.ts +75 -5
- package/lib/commonjs/typescript/codegen/pack/keytype.d.ts +1002 -298
- package/lib/commonjs/typescript/core/api.d.ts +2 -1
- package/lib/commonjs/typescript/core/keytype.d.ts +2 -3
- package/lib/commonjs/typescript/core/pusher.d.ts +0 -3
- package/lib/commonjs/typescript/view/MixView.d.ts +1 -9
- package/lib/module/index.js +23206 -20306
- package/lib/module/typescript/android/index.d.ts +0 -3
- package/lib/module/typescript/codegen/android/api.d.ts +190 -644
- package/lib/module/typescript/codegen/android/callback.d.ts +234 -2
- package/lib/module/typescript/codegen/android/errorcode.d.ts +66 -0
- package/lib/module/typescript/codegen/android/keytype.d.ts +1014 -181
- package/lib/module/typescript/codegen/ios/api.d.ts +890 -0
- package/lib/module/typescript/codegen/ios/callback.d.ts +162 -0
- package/lib/module/typescript/codegen/ios/errorcode.d.ts +101 -1
- package/lib/module/typescript/codegen/ios/keytype.d.ts +694 -0
- package/lib/module/typescript/codegen/pack/api.d.ts +303 -686
- package/lib/module/typescript/codegen/pack/callback.d.ts +37 -38
- package/lib/module/typescript/codegen/pack/errorcode.d.ts +75 -5
- package/lib/module/typescript/codegen/pack/keytype.d.ts +1002 -298
- package/lib/module/typescript/core/api.d.ts +2 -1
- package/lib/module/typescript/core/keytype.d.ts +2 -3
- package/lib/module/typescript/core/pusher.d.ts +0 -3
- package/lib/module/typescript/view/MixView.d.ts +1 -9
- package/lib/typescript/android/index.d.ts +0 -3
- package/lib/typescript/codegen/android/api.d.ts +190 -644
- package/lib/typescript/codegen/android/callback.d.ts +234 -2
- package/lib/typescript/codegen/android/errorcode.d.ts +66 -0
- package/lib/typescript/codegen/android/keytype.d.ts +1014 -181
- package/lib/typescript/codegen/ios/api.d.ts +890 -0
- package/lib/typescript/codegen/ios/callback.d.ts +162 -0
- package/lib/typescript/codegen/ios/errorcode.d.ts +101 -1
- package/lib/typescript/codegen/ios/keytype.d.ts +694 -0
- package/lib/typescript/codegen/pack/api.d.ts +303 -686
- package/lib/typescript/codegen/pack/callback.d.ts +37 -38
- package/lib/typescript/codegen/pack/errorcode.d.ts +75 -5
- package/lib/typescript/codegen/pack/keytype.d.ts +1002 -298
- package/lib/typescript/core/api.d.ts +2 -1
- package/lib/typescript/core/keytype.d.ts +2 -3
- package/lib/typescript/core/pusher.d.ts +0 -3
- package/lib/typescript/view/MixView.d.ts +1 -9
- package/package.json +1 -1
- package/react-native-velive-push.podspec +3 -3
- package/android/src/main/java/com/volcengine/velive/rn/push/ScreenCaptureHelper.java +0 -73
|
@@ -1,448 +1,1142 @@
|
|
|
1
1
|
import { int, BOOL, NSDictionary, float, CMTime, GLuint, CVPixelBufferRef, CMSampleBufferRef, NSData, NSArray, NSString } from './types';
|
|
2
2
|
export declare enum VeLiveVideoEffectLicenseType {
|
|
3
3
|
|
|
4
|
+
/** {en}
|
|
5
|
+
* @brief Authenticate offline.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
4
8
|
VeLiveVideoEffectLicenseTypeOffLine = 0,
|
|
5
9
|
|
|
10
|
+
/** {en}
|
|
11
|
+
* @brief Authenticate online.
|
|
12
|
+
*
|
|
13
|
+
*/
|
|
6
14
|
VeLiveVideoEffectLicenseTypeOnLine = 1
|
|
7
15
|
}
|
|
8
16
|
export declare enum VeLiveNetworkQuality {
|
|
9
17
|
|
|
18
|
+
/** {en}
|
|
19
|
+
* @brief Network status not found.
|
|
20
|
+
*
|
|
21
|
+
*/
|
|
10
22
|
VeLiveNetworkQualityUnknown = -1,
|
|
11
23
|
|
|
24
|
+
/** {en}
|
|
25
|
+
* @brief Bad network condition.
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
12
28
|
VeLiveNetworkQualityBad = 0,
|
|
13
29
|
|
|
30
|
+
/** {en}
|
|
31
|
+
* @brief Poor network condition.
|
|
32
|
+
*
|
|
33
|
+
*/
|
|
14
34
|
VeLiveNetworkQualityPoor = 1,
|
|
15
35
|
|
|
36
|
+
/** {en}
|
|
37
|
+
* @brief Good network condition.
|
|
38
|
+
*
|
|
39
|
+
*/
|
|
16
40
|
VeLiveNetworkQualityGood = 2
|
|
17
41
|
}
|
|
18
42
|
export declare enum VeLiveAudioChannel {
|
|
19
43
|
|
|
44
|
+
/** {en}
|
|
45
|
+
* @brief Mono, which is suitable for voice communication and saves bandwidth.
|
|
46
|
+
*
|
|
47
|
+
*/
|
|
20
48
|
VeLiveAudioChannelMono = 1,
|
|
21
49
|
|
|
50
|
+
/** {en}
|
|
51
|
+
* @brief Stereo, which provides a richer audio experience and is suitable for music playback.
|
|
52
|
+
*
|
|
53
|
+
*/
|
|
22
54
|
VeLiveAudioChannelStereo = 2
|
|
23
55
|
}
|
|
24
56
|
export declare enum VeLiveVideoEncodeFrameType {
|
|
25
57
|
|
|
58
|
+
/** {en}
|
|
59
|
+
* @brief IDR frame.
|
|
60
|
+
*
|
|
61
|
+
*/
|
|
26
62
|
VeLiveVideoEncodeFrameTypeIDR = 1,
|
|
27
63
|
|
|
64
|
+
/** {en}
|
|
65
|
+
* @brief SPS/PPS frame.
|
|
66
|
+
*
|
|
67
|
+
*/
|
|
28
68
|
VeLiveVideoEncodeFrameTypeSPSPPS = 2,
|
|
29
69
|
|
|
70
|
+
/** {en}
|
|
71
|
+
* @brief B frame.
|
|
72
|
+
*
|
|
73
|
+
*/
|
|
30
74
|
VeLiveVideoEncodeFrameTypeB = 3,
|
|
31
75
|
|
|
76
|
+
/** {en}
|
|
77
|
+
* @brief P frame.
|
|
78
|
+
*
|
|
79
|
+
*/
|
|
32
80
|
VeLiveVideoEncodeFrameTypeP = 4
|
|
33
81
|
}
|
|
34
82
|
export declare class VeLiveVideoEncoderConfiguration {
|
|
35
83
|
|
|
84
|
+
/** {en}
|
|
85
|
+
* @brief The video resolution. See [VeLiveVideoResolution](#VeLiveVideoResolution) for details. The default value is `VeLiveVideoResolution720P`.
|
|
86
|
+
*/
|
|
36
87
|
resolution: VeLiveVideoResolution;
|
|
37
88
|
|
|
89
|
+
/** {en}
|
|
90
|
+
* @brief The video codec. The default value is `VeLiveVideoCodecH264`. See [VeLiveVideoCodec](#VeLiveVideoCodec) for details.
|
|
91
|
+
*/
|
|
38
92
|
codec: VeLiveVideoCodec;
|
|
39
93
|
|
|
94
|
+
/** {en}
|
|
95
|
+
* @brief The target video encoding bitrate, in Kbps. The default value depends on the value of the `resolution` parameter.
|
|
96
|
+
*/
|
|
40
97
|
bitrate: int;
|
|
41
98
|
|
|
99
|
+
/** {en}
|
|
100
|
+
* @brief The minimum video encoding bitrate, in Kbps, when the adaptive bitrate (ABR) feature is enabled. The default value depends on the value of the `resolution` parameter.
|
|
101
|
+
*/
|
|
42
102
|
minBitrate: int;
|
|
43
103
|
|
|
104
|
+
/** {en}
|
|
105
|
+
* @brief The maximum video encoding bitrate, in Kbps, when the adaptive bitrate (ABR) feature is enabled. The default value depends on the value of the `resolution` parameter.
|
|
106
|
+
*/
|
|
44
107
|
maxBitrate: int;
|
|
45
108
|
|
|
109
|
+
/** {en}
|
|
110
|
+
* @brief The video GOP size, in seconds. The default value is `2`.
|
|
111
|
+
*/
|
|
46
112
|
gopSize: int;
|
|
47
113
|
|
|
114
|
+
/** {en}
|
|
115
|
+
* @brief The encoded frame rate, in fps. The default value is `15`.
|
|
116
|
+
*/
|
|
48
117
|
fps: int;
|
|
49
118
|
|
|
119
|
+
/** {en}
|
|
120
|
+
* @brief Whether to enable B frames. <br>
|
|
121
|
+
* - YES: Enable.
|
|
122
|
+
* - NO: (Default) Disable.
|
|
123
|
+
*/
|
|
50
124
|
enableBFrame: BOOL;
|
|
51
125
|
|
|
126
|
+
/** {en}
|
|
127
|
+
* @brief Whether to enable hardware encoding.<br>
|
|
128
|
+
* - YES: (Default) Enable;
|
|
129
|
+
* - NO: Disable.
|
|
130
|
+
*/
|
|
52
131
|
enableAccelerate: BOOL;
|
|
53
132
|
|
|
133
|
+
/** {en}
|
|
134
|
+
* @brief Creates a VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration} object and specifies the video resolution.
|
|
135
|
+
* @param resolution The video resolution. See VeLiveVideoResolution {@link #VeLiveVideoResolution} for details.
|
|
136
|
+
* @return <br>
|
|
137
|
+
* The VeLiveVideoEncoderConfiguration {@link #VeLiveVideoEncoderConfiguration} object.
|
|
138
|
+
*/
|
|
54
139
|
initWithResolution(resolution: VeLiveVideoResolution): this;
|
|
55
140
|
}
|
|
56
141
|
export declare enum VeLiveVideoFrameSource {
|
|
57
142
|
|
|
143
|
+
/** {en}
|
|
144
|
+
* @brief The original video frame captured by the camera or other video sources.
|
|
145
|
+
*
|
|
146
|
+
*/
|
|
58
147
|
VeLiveVideoFrameSourceCapture = 1,
|
|
59
148
|
|
|
149
|
+
/** {en}
|
|
150
|
+
* @brief The video frame prior to encoding after undergoing various processes, such as filtering and rotation.
|
|
151
|
+
*
|
|
152
|
+
*/
|
|
60
153
|
VeLiveVideoFrameSourcePreEncode = 2
|
|
61
154
|
}
|
|
62
155
|
export declare enum VeLiveAudioBufferType {
|
|
63
156
|
|
|
157
|
+
/** {en}
|
|
158
|
+
* @brief Unknown data type.
|
|
159
|
+
*
|
|
160
|
+
*/
|
|
64
161
|
VeLiveAudioBufferTypeUnknown = -1,
|
|
65
162
|
|
|
163
|
+
/** {en}
|
|
164
|
+
* @brief CMSampleBufferRef.
|
|
165
|
+
*
|
|
166
|
+
*/
|
|
66
167
|
VeLiveAudioBufferTypeSampleBuffer = 0,
|
|
67
168
|
|
|
169
|
+
/** {en}
|
|
170
|
+
* @brief NSData.
|
|
171
|
+
*
|
|
172
|
+
*/
|
|
68
173
|
VeLiveAudioBufferTypeNSData = 1
|
|
69
174
|
}
|
|
70
175
|
export declare class VeLivePusherConfiguration {
|
|
71
176
|
|
|
177
|
+
/** {en}
|
|
178
|
+
* @brief The video capture configurations. See [VeLiveVideoCaptureConfiguration](#VeLiveVideoCaptureConfiguration) for details.
|
|
179
|
+
*/
|
|
72
180
|
videoCaptureConfig: VeLiveVideoCaptureConfiguration;
|
|
73
181
|
|
|
182
|
+
/** {en}
|
|
183
|
+
* @brief The audio capture configurations. See [VeLiveAudioCaptureConfiguration](#VeLiveAudioCaptureConfiguration) for details.
|
|
184
|
+
*/
|
|
74
185
|
audioCaptureConfig: VeLiveAudioCaptureConfiguration;
|
|
75
186
|
|
|
187
|
+
/** {en}
|
|
188
|
+
* @brief The time interval between each attempt to reconnect, in seconds. The default value is `5`.
|
|
189
|
+
*/
|
|
76
190
|
reconnectIntervalSeconds: int;
|
|
77
191
|
|
|
192
|
+
/** {en}
|
|
193
|
+
* @brief The number of attempts to reconnect after the initial attempt fails. The default value is `3`.
|
|
194
|
+
*/
|
|
78
195
|
reconnectCount: int;
|
|
79
196
|
|
|
197
|
+
/** {en}
|
|
198
|
+
* @brief Advanced parameters. You can leave this parameter empty.
|
|
199
|
+
*/
|
|
80
200
|
extraParameters: NSDictionary;
|
|
81
201
|
init(): this;
|
|
82
202
|
}
|
|
83
203
|
export declare enum VeLiveVideoCaptureType {
|
|
84
204
|
|
|
205
|
+
/** {en}
|
|
206
|
+
* @brief Capture the video with the front-facing camera.
|
|
207
|
+
*
|
|
208
|
+
*/
|
|
85
209
|
VeLiveVideoCaptureFrontCamera = 0,
|
|
86
210
|
|
|
211
|
+
/** {en}
|
|
212
|
+
* @brief Capture the video with the rear camera.
|
|
213
|
+
*
|
|
214
|
+
*/
|
|
87
215
|
VeLiveVideoCaptureBackCamera = 1,
|
|
88
216
|
|
|
217
|
+
/** {en}
|
|
218
|
+
* @brief Capture the video with dual cameras.
|
|
219
|
+
*
|
|
220
|
+
*/
|
|
89
221
|
VeLiveVideoCaptureDualCamera = 2,
|
|
90
222
|
|
|
223
|
+
/** {en}
|
|
224
|
+
* @brief Capture the video with an external device or source.
|
|
225
|
+
*
|
|
226
|
+
*/
|
|
91
227
|
VeLiveVideoCaptureExternal = 4,
|
|
92
228
|
|
|
229
|
+
/** {en}
|
|
230
|
+
* @brief Use a static image as the video source.
|
|
231
|
+
*
|
|
232
|
+
*/
|
|
93
233
|
VeLiveVideoCaptureCustomImage = 5,
|
|
94
234
|
|
|
235
|
+
/** {en}
|
|
236
|
+
* @brief Use the last frame as the video source.
|
|
237
|
+
*
|
|
238
|
+
*/
|
|
95
239
|
VeLiveVideoCaptureLastFrame = 6,
|
|
96
240
|
|
|
241
|
+
/** {en}
|
|
242
|
+
* @brief Use a black frame as the video source. This is usually used for debugging purposes or in special circumstances.
|
|
243
|
+
*
|
|
244
|
+
*/
|
|
97
245
|
VeLiveVideoCaptureDummyFrame = 7
|
|
98
246
|
}
|
|
99
247
|
export declare class VeLiveFileRecorderConfiguration {
|
|
100
248
|
|
|
249
|
+
/** {en}
|
|
250
|
+
* @brief The width of the recorded video, in pixels. The default value is `360`.
|
|
251
|
+
*/
|
|
101
252
|
width: int;
|
|
102
253
|
|
|
254
|
+
/** {en}
|
|
255
|
+
* @brief The height of the recorded video, in pixels. The default value is `640`.
|
|
256
|
+
*/
|
|
103
257
|
height: int;
|
|
104
258
|
|
|
259
|
+
/** {en}
|
|
260
|
+
* @deprecated
|
|
261
|
+
* @brief The frame rate of the recorded video. The default value is `15`. The value range is [1,15].
|
|
262
|
+
*/
|
|
105
263
|
fps: int;
|
|
106
264
|
|
|
265
|
+
/** {en}
|
|
266
|
+
* @brief The encoding bitrate of the recorded video, in Kbps. The default value is `2000`.
|
|
267
|
+
*/
|
|
107
268
|
bitrate: int;
|
|
108
269
|
init(): this;
|
|
109
270
|
}
|
|
110
271
|
export declare enum VeLiveVideoBufferType {
|
|
111
272
|
|
|
273
|
+
/** {en}
|
|
274
|
+
* @brief Unknown data type, which is the default type if you do not specify any type.
|
|
275
|
+
*
|
|
276
|
+
*/
|
|
112
277
|
VeLiveVideoBufferTypeUnKnown = -1,
|
|
113
278
|
|
|
279
|
+
/** {en}
|
|
280
|
+
* @brief CVPixelBuffer.
|
|
281
|
+
*
|
|
282
|
+
*/
|
|
114
283
|
VeLiveVideoBufferTypePixelBuffer = 0,
|
|
115
284
|
|
|
285
|
+
/** {en}
|
|
286
|
+
* @brief CMSampleBufferRef.
|
|
287
|
+
*
|
|
288
|
+
*/
|
|
116
289
|
VeLiveVideoBufferTypeSampleBuffer = 1,
|
|
117
290
|
|
|
291
|
+
/** {en}
|
|
292
|
+
* @brief NSData.
|
|
293
|
+
*
|
|
294
|
+
*/
|
|
118
295
|
VeLiveVideoBufferTypeNSData = 2,
|
|
119
296
|
|
|
297
|
+
/** {en}
|
|
298
|
+
* @brief OpenGL texture.
|
|
299
|
+
*
|
|
300
|
+
*/
|
|
120
301
|
VeLiveVideoBufferTypeTexture = 3
|
|
121
302
|
}
|
|
122
303
|
export declare class VeLiveMixVideoLayout {
|
|
123
304
|
|
|
305
|
+
/** {en}
|
|
306
|
+
* @brief The unique identifier for a video stream.
|
|
307
|
+
*/
|
|
124
308
|
streamId: int;
|
|
125
309
|
|
|
310
|
+
/** {en}
|
|
311
|
+
* @brief The horizontal offset, which represents the ratio of the distance between the left edge of the video and the left edge of the screen to the width of the screen. The value range is [0.0,1.0], where `0.0` indicates the left edge and `1.0` indicates the right edge.
|
|
312
|
+
*/
|
|
126
313
|
x: float;
|
|
127
314
|
|
|
315
|
+
/** {en}
|
|
316
|
+
* @brief The vertical offset, which represents the ratio of the distance between the top edge of the video and the top edge of the screen to the height of the screen. The value range is [0.0,1.0], where `0.0` indicates the top edge and `1.0` indicates the bottom edge.
|
|
317
|
+
*/
|
|
128
318
|
y: float;
|
|
129
319
|
|
|
320
|
+
/** {en}
|
|
321
|
+
* @brief The ratio of the video width to the screen width. The value range is [0.0,1.0], where `1.0` indicates that the video occupies the entire screen width.
|
|
322
|
+
*/
|
|
130
323
|
width: float;
|
|
131
324
|
|
|
325
|
+
/** {en}
|
|
326
|
+
* @brief The ratio of the video height to the screen height. The value range is [0.0,1.0], where `1.0` indicates that the video occupies the entire screen height.
|
|
327
|
+
*/
|
|
132
328
|
height: float;
|
|
133
329
|
|
|
330
|
+
/** {en}
|
|
331
|
+
* @brief The video transparency. The value range is [0.0, 1.0], where `0.0` indicates full transparency and `1.0` indicates full opacity.
|
|
332
|
+
*/
|
|
134
333
|
alpha: float;
|
|
135
334
|
|
|
335
|
+
/** {en}
|
|
336
|
+
* @brief The level of video within the final mixed video. The value range is [0,100], where `0` represents the bottom layer. The higher the value, the higher the level of the video in the final output.
|
|
337
|
+
*/
|
|
136
338
|
zOrder: int;
|
|
137
339
|
|
|
340
|
+
/** {en}
|
|
341
|
+
* @brief The render mode of the video. See [VeLivePusherRenderMode](#VeLivePusherRenderMode) for details.
|
|
342
|
+
*/
|
|
138
343
|
renderMode: VeLivePusherRenderMode;
|
|
344
|
+
|
|
345
|
+
/** {en}
|
|
346
|
+
* @brief Whether to retain the original Alpha channel value of the video stream. The default is retain. When the value of [alpha](#VeLiveMixVideoLayout-alpha) is within the range of [0.0, 1.0], this configuration is ignored.<br/>
|
|
347
|
+
*
|
|
348
|
+
* - YES: Retain;
|
|
349
|
+
* - NO: Do not retain.
|
|
350
|
+
*/
|
|
351
|
+
enableAlpha: BOOL;
|
|
139
352
|
init(): this;
|
|
140
353
|
}
|
|
141
354
|
export declare class VeLiveMixAudioLayout {
|
|
142
355
|
|
|
356
|
+
/** {en}
|
|
357
|
+
* @brief The unique identifier for an audio stream.
|
|
358
|
+
*/
|
|
143
359
|
streamId: int;
|
|
144
360
|
|
|
361
|
+
/** {en}
|
|
362
|
+
* @detail api
|
|
363
|
+
* @brief The volume of the mixed audio stream. The value range is [0.0,4.0]. If you set [VeLiveAudioMixType](#VeLiveAudioMixType) to `VeLiveAudioMixPlayAndPush`, this property takes effect on both the host and the audience sides.
|
|
364
|
+
*/
|
|
145
365
|
volume: float;
|
|
146
366
|
init(): this;
|
|
147
367
|
}
|
|
148
368
|
export declare enum VeLiveAudioProfile {
|
|
149
369
|
|
|
370
|
+
/** {en}
|
|
371
|
+
* @brief LC-AAC.
|
|
372
|
+
*
|
|
373
|
+
*/
|
|
150
374
|
VeLiveAudioAACProfileLC = 0,
|
|
151
375
|
|
|
376
|
+
/** {en}
|
|
377
|
+
* @brief HEv1-AAC.
|
|
378
|
+
*
|
|
379
|
+
*/
|
|
152
380
|
VeLiveAudioAACProfileHEv1 = 1,
|
|
153
381
|
|
|
382
|
+
/** {en}
|
|
383
|
+
* @brief HEv2-AAC.
|
|
384
|
+
*
|
|
385
|
+
*/
|
|
154
386
|
VeLiveAudioAACProfileHEv2 = 2
|
|
155
387
|
}
|
|
156
388
|
export declare class VeLiveVideoFrame {
|
|
157
389
|
|
|
390
|
+
/** {en}
|
|
391
|
+
* @brief The video buffer type. The default value is `VeLiveVideoBufferTypeUnknown`. See [VeLiveVideoBufferType](#VeLiveVideoBufferType) for details.
|
|
392
|
+
*/
|
|
158
393
|
bufferType: VeLiveVideoBufferType;
|
|
159
394
|
|
|
395
|
+
/** {en}
|
|
396
|
+
* @brief The pixel format. When `bufferType` is `VeLiveVideoBufferTypeNSData`, you must specify `pixelFormat`. See [VeLivePixelFormat](#VeLivePixelFormat) for details.
|
|
397
|
+
*/
|
|
160
398
|
pixelFormat: VeLivePixelFormat;
|
|
161
399
|
|
|
400
|
+
/** {en}
|
|
401
|
+
* @brief The rotation angle in a clockwise direction. See [VeLiveVideoRotation](#VeLiveVideoRotation) for details.
|
|
402
|
+
*/
|
|
162
403
|
rotation: VeLiveVideoRotation;
|
|
163
404
|
|
|
405
|
+
/** {en}
|
|
406
|
+
* @brief The width of the video, in pixels.
|
|
407
|
+
*/
|
|
164
408
|
width: int;
|
|
165
409
|
|
|
410
|
+
/** {en}
|
|
411
|
+
* @brief The height of the video, in pixels.
|
|
412
|
+
*/
|
|
166
413
|
height: int;
|
|
167
414
|
|
|
415
|
+
/** {en}
|
|
416
|
+
* @brief The timestamp of the video frame, in μs.
|
|
417
|
+
*/
|
|
168
418
|
pts: CMTime;
|
|
169
419
|
|
|
420
|
+
/** {en}
|
|
421
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypeTexture`.
|
|
422
|
+
*/
|
|
170
423
|
textureId: GLuint;
|
|
171
424
|
|
|
425
|
+
/** {en}
|
|
426
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypePixelBuffer`.
|
|
427
|
+
*/
|
|
172
428
|
pixelBuffer: CVPixelBufferRef;
|
|
173
429
|
|
|
430
|
+
/** {en}
|
|
431
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypeSampleBuffer`.
|
|
432
|
+
*/
|
|
174
433
|
sampleBuffer: CMSampleBufferRef;
|
|
175
434
|
|
|
435
|
+
/** {en}
|
|
436
|
+
* @brief The video data, when `bufferType` is `VeLiveVideoBufferTypeNSData`.
|
|
437
|
+
*/
|
|
176
438
|
data: NSData;
|
|
177
439
|
|
|
440
|
+
/** {en}
|
|
441
|
+
* @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.
|
|
442
|
+
*/
|
|
178
443
|
releaseCallback(): void;
|
|
179
444
|
init(): this;
|
|
180
445
|
}
|
|
181
446
|
export declare enum VeLiveVideoFluencyLevel {
|
|
182
447
|
|
|
448
|
+
/** {en}
|
|
449
|
+
* @brief Smooth. The frame rate reaches the expected rate.
|
|
450
|
+
*
|
|
451
|
+
*/
|
|
183
452
|
VeLiveVideoFluencyLevelSmooth = 0,
|
|
184
453
|
|
|
454
|
+
/** {en}
|
|
455
|
+
* @brief Minor freeze. The frame rate is 1 to 3 fps lower than the expected rate.
|
|
456
|
+
*
|
|
457
|
+
*/
|
|
185
458
|
VeLiveVideoFluencyLevelSluggish = 1,
|
|
186
459
|
|
|
460
|
+
/** {en}
|
|
461
|
+
* @brief Severe freeze. The frame rate is 4 fps lower than the expected rate.
|
|
462
|
+
*
|
|
463
|
+
*/
|
|
187
464
|
VeLiveVideoFluencyLevelBlocked = 2,
|
|
188
465
|
|
|
466
|
+
/** {en}
|
|
467
|
+
* @brief Completely frozen. The frame rate is below 2 fps.
|
|
468
|
+
*
|
|
469
|
+
*/
|
|
189
470
|
VeLiveVideoFluencyLevelStuck = 3
|
|
190
471
|
}
|
|
191
472
|
export declare enum VeLiveVideoMirrorType {
|
|
192
473
|
|
|
474
|
+
/** {en}
|
|
475
|
+
* @brief Mirror the captured video. When turned on, both the preview and the pushed video are mirrored.
|
|
476
|
+
*
|
|
477
|
+
*/
|
|
193
478
|
VeLiveVideoMirrorCapture = 0,
|
|
194
479
|
|
|
480
|
+
/** {en}
|
|
481
|
+
* @brief Mirror the preview. When turned on, only the preview is mirrored.
|
|
482
|
+
*
|
|
483
|
+
*/
|
|
195
484
|
VeLiveVideoMirrorPreview = 1,
|
|
196
485
|
|
|
486
|
+
/** {en}
|
|
487
|
+
* @brief Mirror the video before encoding. When turned on, only the pushed video is mirrored.
|
|
488
|
+
*
|
|
489
|
+
*/
|
|
197
490
|
VeLiveVideoMirrorPushStream = 2
|
|
198
491
|
}
|
|
199
492
|
export declare class VeLiveAudioCaptureConfiguration {
|
|
200
493
|
|
|
494
|
+
/** {en}
|
|
495
|
+
* @brief The sample rate. See [VeLiveAudioSampleRate](#VeLiveAudioSampleRate) for details. The default value is `VeLiveAudioSampleRate44100`.
|
|
496
|
+
*/
|
|
201
497
|
sampleRate: VeLiveAudioSampleRate;
|
|
202
498
|
|
|
499
|
+
/** {en}
|
|
500
|
+
* @brief The number of audio channels. See [VeLiveAudioChannel](#VeLiveAudioChannel) for details. The default value is `VeLiveAudioChannelStereo`.
|
|
501
|
+
*/
|
|
203
502
|
channel: VeLiveAudioChannel;
|
|
204
503
|
init(): this;
|
|
205
504
|
}
|
|
206
505
|
export declare enum VeLiveVideoResolution {
|
|
207
506
|
|
|
507
|
+
/** {en}
|
|
508
|
+
* @brief 360P. The predefined configurations are as follows:
|
|
509
|
+
* - Resolution in landscape mode: 640x360
|
|
510
|
+
* - Resolution in portrait mode: 360x640
|
|
511
|
+
* - Frame rate: 15 fps
|
|
512
|
+
* - Target bitrate: 500 kbps
|
|
513
|
+
* - Minimum bitrate: 250 kbps
|
|
514
|
+
* - Maximum bitrate: 800 kbps
|
|
515
|
+
*
|
|
516
|
+
*/
|
|
208
517
|
VeLiveVideoResolution360P = 0,
|
|
209
518
|
|
|
519
|
+
/** {en}
|
|
520
|
+
* @brief 480P. The predefined configurations are as follows:
|
|
521
|
+
* - Resolution in landscape mode: 864x480
|
|
522
|
+
* - Resolution in portrait mode: 480x864
|
|
523
|
+
* - Frame rate: 15 fps
|
|
524
|
+
* - Target bitrate: 800 kbps
|
|
525
|
+
* - Minimum bitrate: 320 kbps
|
|
526
|
+
* - Maximum bitrate: 1266 kbps
|
|
527
|
+
*
|
|
528
|
+
*/
|
|
210
529
|
VeLiveVideoResolution480P = 1,
|
|
211
530
|
|
|
531
|
+
/** {en}
|
|
532
|
+
* @brief 540P. The predefined configurations are as follows:
|
|
533
|
+
* - Resolution in landscape mode: 960x540
|
|
534
|
+
* - Resolution in portrait mode: 540x960
|
|
535
|
+
* - Frame rate: 15 fps
|
|
536
|
+
* - Target bitrate: 1000 kbps
|
|
537
|
+
* - Minimum bitrate: 500 kbps
|
|
538
|
+
* - Maximum bitrate: 1520 kbps
|
|
539
|
+
*
|
|
540
|
+
*/
|
|
212
541
|
VeLiveVideoResolution540P = 2,
|
|
213
542
|
|
|
543
|
+
/** {en}
|
|
544
|
+
* @brief 720P. The predefined configurations are as follows:
|
|
545
|
+
* - Resolution in landscape mode: 1280x720
|
|
546
|
+
* - Resolution in portrait mode: 720x1280
|
|
547
|
+
* - Frame rate: 15 fps
|
|
548
|
+
* - Target bitrate: 1200 kbps
|
|
549
|
+
* - Minimum bitrate: 800 kbps
|
|
550
|
+
* - Maximum bitrate: 1900 kbps
|
|
551
|
+
*
|
|
552
|
+
*/
|
|
214
553
|
VeLiveVideoResolution720P = 3,
|
|
215
554
|
|
|
555
|
+
/** {en}
|
|
556
|
+
* @brief 1080P. The predefined configurations are as follows:
|
|
557
|
+
* - Resolution in landscape mode: 1920x1080
|
|
558
|
+
* - Resolution in portrait mode: 1080x1920
|
|
559
|
+
* - Frame rate: 20 fps
|
|
560
|
+
* - Target bitrate: 2500 kbps
|
|
561
|
+
* - Minimum bitrate: 1000 kbps
|
|
562
|
+
* - Maximum bitrate: 3800 kbps
|
|
563
|
+
*
|
|
564
|
+
*/
|
|
216
565
|
VeLiveVideoResolution1080P = 4,
|
|
217
566
|
|
|
567
|
+
/** {en}
|
|
568
|
+
* @brief The resolution of the streamed screen. The predefined configurations are as follows:
|
|
569
|
+
* - Frame rate: 15 fps
|
|
570
|
+
* - Target bitrate: 2500 kbps
|
|
571
|
+
* - Minimum bitrate: 1000 kbps
|
|
572
|
+
* - Maximum bitrate: 3800 kbps
|
|
573
|
+
*
|
|
574
|
+
*/
|
|
218
575
|
VeLiveVideoResolutionScreen = 10
|
|
219
576
|
}
|
|
220
577
|
export declare enum VeLiveVideoRotation {
|
|
221
578
|
|
|
579
|
+
/** {en}
|
|
580
|
+
* @brief Do not rotate.
|
|
581
|
+
*
|
|
582
|
+
*/
|
|
222
583
|
VeLiveVideoRotation0 = 0,
|
|
223
584
|
|
|
585
|
+
/** {en}
|
|
586
|
+
* @brief Rotate by 90 degrees clockwise.
|
|
587
|
+
*
|
|
588
|
+
*/
|
|
224
589
|
VeLiveVideoRotation90 = 1,
|
|
225
590
|
|
|
591
|
+
/** {en}
|
|
592
|
+
* @brief Rotate by 180 degrees clockwise.
|
|
593
|
+
*
|
|
594
|
+
*/
|
|
226
595
|
VeLiveVideoRotation180 = 2,
|
|
227
596
|
|
|
597
|
+
/** {en}
|
|
598
|
+
* @brief Rotate by 270 degrees clockwise.
|
|
599
|
+
*
|
|
600
|
+
*/
|
|
228
601
|
VeLiveVideoRotation270 = 3
|
|
229
602
|
}
|
|
230
603
|
export declare class VeLiveStreamMixDescription {
|
|
231
604
|
|
|
605
|
+
/** {en}
|
|
606
|
+
* @brief An array of video mixing configurations, where each array element represents the mixing configurations of a video stream. See [VeLiveMixVideoLayout](#VeLiveMixVideoLayout) for details.
|
|
607
|
+
*/
|
|
232
608
|
mixVideoStreams: NSArray<VeLiveMixVideoLayout>;
|
|
233
609
|
|
|
610
|
+
/** {en}
|
|
611
|
+
* @brief An array of audio mixing configurations, where each array element represents the mixing configurations of an audio stream. See [VeLiveMixAudioLayout](#VeLiveMixAudioLayout) for details.
|
|
612
|
+
*/
|
|
234
613
|
mixAudioStreams: NSArray<VeLiveMixAudioLayout>;
|
|
235
614
|
|
|
615
|
+
/** {en}
|
|
616
|
+
* @brief The background color of the mixed video, in #RRGGBB format.
|
|
617
|
+
*/
|
|
236
618
|
backgroundColor: NSString;
|
|
237
619
|
init(): this;
|
|
238
620
|
}
|
|
239
621
|
export declare enum VeLiveAudioCaptureType {
|
|
240
622
|
|
|
623
|
+
/** {en}
|
|
624
|
+
* @brief Capture the audio with the default microphone.
|
|
625
|
+
*
|
|
626
|
+
*/
|
|
241
627
|
VeLiveAudioCaptureMicrophone = 0,
|
|
242
628
|
|
|
629
|
+
/** {en}
|
|
630
|
+
* @brief Capture the audio in voice call mode, which will activate the 3A features of the hardware, including automatic gain control, automatic frequency control, and automatic noise suppression.
|
|
631
|
+
*
|
|
632
|
+
*/
|
|
243
633
|
VeLiveAudioCaptureVoiceCommunication = 1,
|
|
244
634
|
|
|
635
|
+
/** {en}
|
|
636
|
+
* @brief Capture the audio with an external device or source.
|
|
637
|
+
*
|
|
638
|
+
*/
|
|
245
639
|
VeLiveAudioCaptureExternal = 2,
|
|
246
640
|
|
|
641
|
+
/** {en}
|
|
642
|
+
* @brief Use muted frames as the audio source.
|
|
643
|
+
*
|
|
644
|
+
*/
|
|
247
645
|
VeLiveAudioCaptureMuteFrame = 3
|
|
248
646
|
}
|
|
249
647
|
export declare enum VeLiveVideoCodec {
|
|
250
648
|
|
|
649
|
+
/** {en}
|
|
650
|
+
* @brief H.264.
|
|
651
|
+
*
|
|
652
|
+
*/
|
|
251
653
|
VeLiveVideoCodecH264 = 0,
|
|
252
654
|
|
|
655
|
+
/** {en}
|
|
656
|
+
* @brief ByteVC1, an encoding format developed by BytePlus.
|
|
657
|
+
*
|
|
658
|
+
*/
|
|
253
659
|
VeLiveVideoCodecByteVC1 = 1
|
|
254
660
|
}
|
|
255
661
|
export declare class VeLiveVideoEncodeFrame {
|
|
256
662
|
|
|
663
|
+
/** {en}
|
|
664
|
+
* @brief The display timestamp, in μs. The display timestamp indicates when the frame should be rendered.
|
|
665
|
+
*/
|
|
257
666
|
pts: CMTime;
|
|
258
667
|
|
|
668
|
+
/** {en}
|
|
669
|
+
* @brief The dts time, or the decoding timestamp, in μs. The decoding timestamp indicates when the frame should be decoded.
|
|
670
|
+
*/
|
|
259
671
|
dts: CMTime;
|
|
260
672
|
|
|
673
|
+
/** {en}
|
|
674
|
+
* @brief The type of the encoded frame. See [VeLiveVideoEncodeFrameType:](#VeLiveVideoEncodeFrameType) for details.
|
|
675
|
+
*/
|
|
261
676
|
videoEcodeFrameType: VeLiveVideoEncodeFrameType;
|
|
262
677
|
|
|
678
|
+
/** {en}
|
|
679
|
+
* @brief The encoded data of the video frame. The encoded data is represented by an object of type NSData.
|
|
680
|
+
*/
|
|
263
681
|
data: NSData;
|
|
264
682
|
init(): this;
|
|
265
683
|
}
|
|
266
684
|
export declare class VeLiveAudioEncoderConfiguration {
|
|
267
685
|
|
|
686
|
+
/** {en}
|
|
687
|
+
* @brief The audio encoding bitrate, in Kbps. The default value is `64`.
|
|
688
|
+
*/
|
|
268
689
|
bitrate: int;
|
|
269
690
|
|
|
691
|
+
/** {en}
|
|
692
|
+
* @brief The encoding sample rate. The default value is `VeLiveAudioSampleRate44100`. See [VeLiveAudioSampleRate](#VeLiveAudioSampleRate) for details.
|
|
693
|
+
*/
|
|
270
694
|
sampleRate: VeLiveAudioSampleRate;
|
|
271
695
|
|
|
696
|
+
/** {en}
|
|
697
|
+
* @brief The number of audio channels. The default value is `VeLiveAudioChannelStereo`. See [VeLiveAudioChannel](#VeLiveAudioChannel) for details.
|
|
698
|
+
*/
|
|
272
699
|
channel: VeLiveAudioChannel;
|
|
273
700
|
|
|
701
|
+
/** {en}
|
|
702
|
+
* @brief The AAC encoding format. The default value is `VeLiveAudioAACProfileLC`. See [VeLiveAudioProfile](#VeLiveAudioProfile) for details.
|
|
703
|
+
*/
|
|
274
704
|
profile: VeLiveAudioProfile;
|
|
275
705
|
init(): this;
|
|
276
706
|
}
|
|
277
707
|
export declare enum VeLivePusherLogLevel {
|
|
278
708
|
|
|
709
|
+
/** {en}
|
|
710
|
+
* @brief Output VERBOSE, DEBUG, INFO, WARNING and ERROR.
|
|
711
|
+
*
|
|
712
|
+
*/
|
|
279
713
|
VeLivePusherLogLevelVerbose = 0,
|
|
280
714
|
|
|
715
|
+
/** {en}
|
|
716
|
+
* @brief Output DEBUG, INFO, WARNING and ERROR.
|
|
717
|
+
*
|
|
718
|
+
*/
|
|
281
719
|
VeLivePusherLogLevelDebug = 1,
|
|
282
720
|
|
|
721
|
+
/** {en}
|
|
722
|
+
* @brief Output INFO, WARNING and ERROR.
|
|
723
|
+
*
|
|
724
|
+
*/
|
|
283
725
|
VeLivePusherLogLevelInfo = 2,
|
|
284
726
|
|
|
727
|
+
/** {en}
|
|
728
|
+
* @brief Output WARNING and ERROR.
|
|
729
|
+
*
|
|
730
|
+
*/
|
|
285
731
|
VeLivePusherLogLevelWarn = 3,
|
|
286
732
|
|
|
733
|
+
/** {en}
|
|
734
|
+
* @brief Output ERROR.
|
|
735
|
+
*
|
|
736
|
+
*/
|
|
287
737
|
VeLivePusherLogLevelError = 4,
|
|
288
738
|
|
|
739
|
+
/** {en}
|
|
740
|
+
* @brief Disable logging.
|
|
741
|
+
*
|
|
742
|
+
*/
|
|
289
743
|
VeLivePusherLogLevelNone = 5
|
|
290
744
|
}
|
|
291
745
|
export declare enum VeLiveAudioMixType {
|
|
292
746
|
|
|
747
|
+
/** {en}
|
|
748
|
+
* @brief The audience can hear the mixed audio, but the host cannot.
|
|
749
|
+
*
|
|
750
|
+
*/
|
|
293
751
|
VeLiveAudioMixPush = 0,
|
|
294
752
|
|
|
753
|
+
/** {en}
|
|
754
|
+
* @brief Both the host and audience can hear the mixed audio.
|
|
755
|
+
*
|
|
756
|
+
*/
|
|
295
757
|
VeLiveAudioMixPlayAndPush = 1
|
|
296
758
|
}
|
|
297
759
|
export declare enum VeLivePusherRenderMode {
|
|
298
760
|
|
|
761
|
+
/** {en}
|
|
762
|
+
* @brief Uniformly scale the video until the screen is completely filled. Part of the video may be cropped.
|
|
763
|
+
*
|
|
764
|
+
*/
|
|
299
765
|
VeLivePusherRenderModeHidden = 0,
|
|
300
766
|
|
|
767
|
+
/** {en}
|
|
768
|
+
* @brief Display the full video. The video is uniformly scaled until one dimension of the video hits the boundary of the screen. Any remaining space on the screen will be filled with background color.
|
|
769
|
+
*
|
|
770
|
+
*/
|
|
301
771
|
VeLivePusherRenderModeFit = 1,
|
|
302
772
|
|
|
773
|
+
/** {en}
|
|
774
|
+
* @brief Stretch the video to fill the screen. The aspect ratio of the video might change.
|
|
775
|
+
*
|
|
776
|
+
*/
|
|
303
777
|
VeLivePusherRenderModeFill = 2
|
|
304
778
|
}
|
|
305
779
|
export declare class VeLiveVideoEffectLicenseConfiguration {
|
|
306
780
|
|
|
781
|
+
/** {en}
|
|
782
|
+
* @brief The special effects license type. See [VeLiveVideoEffectLicenseType](#VeLiveVideoEffectLicenseType) for details.
|
|
783
|
+
*/
|
|
307
784
|
type: VeLiveVideoEffectLicenseType;
|
|
308
785
|
|
|
786
|
+
/** {en}
|
|
787
|
+
* @brief The local path to the video effects license, when [VeLiveVideoEffectLicenseType](#VeLiveVideoEffectLicenseType) is `VeLiveVideoEffectLicenseTypeOffLine`.
|
|
788
|
+
*/
|
|
309
789
|
path: NSString;
|
|
310
790
|
|
|
791
|
+
/** {en}
|
|
792
|
+
* @brief The online authentication key for the video effects license, when [VeLiveVideoEffectLicenseType](#VeLiveVideoEffectLicenseType) is `VeLiveVideoEffectLicenseTypeOnLine`.
|
|
793
|
+
*/
|
|
311
794
|
key: NSString;
|
|
312
795
|
|
|
796
|
+
/** {en}
|
|
797
|
+
* @brief The online authentication secret for the video effects license, when [VeLiveVideoEffectLicenseType](#VeLiveVideoEffectLicenseType) is `VeLiveVideoEffectLicenseTypeOnLine`.
|
|
798
|
+
*/
|
|
313
799
|
secret: NSString;
|
|
314
800
|
|
|
801
|
+
/** {en}
|
|
802
|
+
* @brief The online authentication address for the video effects license, when [VeLiveVideoEffectLicenseType](#VeLiveVideoEffectLicenseType) is `VeLiveVideoEffectLicenseTypeOnLine`.
|
|
803
|
+
*/
|
|
315
804
|
url: NSString;
|
|
316
805
|
|
|
806
|
+
/** {en}
|
|
807
|
+
* @detail api
|
|
808
|
+
* @brief Initializes the license configurations in local authentication mode.
|
|
809
|
+
* @param path The local cache path for the video effects license. You can get the path through the [path](#VeLiveVideoEffectLicenseConfiguration-path) property.
|
|
810
|
+
* @return A [VeLiveVideoEffectLicenseConfiguration](#VeLiveVideoEffectLicenseConfiguration) object that uses the specified local path for license authentication.
|
|
811
|
+
*/
|
|
317
812
|
initWithPath(path: NSString): this;
|
|
318
813
|
|
|
814
|
+
/** {en}
|
|
815
|
+
* @detail api
|
|
816
|
+
* @brief Initializes the license configurations in online authentication mode.
|
|
817
|
+
* @param key The online authentication key for the video effects license. You can get it through the [key](#VeLiveVideoEffectLicenseConfiguration-key) property.
|
|
818
|
+
* @param secret The online authentication secret for the video effects license. You can get it through the [secret](#VeLiveVideoEffectLicenseConfiguration-secret) property.
|
|
819
|
+
* @param url The online authentication address for the video effects license. You can get it through the [url](#VeLiveVideoEffectLicenseConfiguration-url) property. If you set it to nil, the SDK will use the default URL.
|
|
820
|
+
* @return A [VeLiveVideoEffectLicenseConfiguration](#VeLiveVideoEffectLicenseConfiguration) object that uses the specified key, secret and address for online license authentication.
|
|
821
|
+
*/
|
|
319
822
|
initWithKey(key: NSString, secret: NSString, url: NSString): this;
|
|
320
823
|
}
|
|
321
824
|
export declare enum VeLiveAudioFrameSource {
|
|
322
825
|
|
|
826
|
+
/** {en}
|
|
827
|
+
* @brief The original audio frame captured by the microphone or other audio sources.
|
|
828
|
+
*
|
|
829
|
+
*/
|
|
323
830
|
VeLiveAudioFrameSourceCapture = 1,
|
|
324
831
|
|
|
832
|
+
/** {en}
|
|
833
|
+
* @brief The audio frame prior to encoding after undergoing various processes, such as noise cancellation and echo cancellation.
|
|
834
|
+
*
|
|
835
|
+
*/
|
|
325
836
|
VeLiveAudioFrameSourcePreEncode = 2
|
|
326
837
|
}
|
|
327
838
|
export declare enum VeLivePushStatus {
|
|
328
839
|
|
|
840
|
+
/** {en}
|
|
841
|
+
* @brief The initial state.
|
|
842
|
+
*
|
|
843
|
+
*/
|
|
329
844
|
VeLivePushStatusNone = 0,
|
|
330
845
|
|
|
846
|
+
/** {en}
|
|
847
|
+
* @brief Connecting to the server.
|
|
848
|
+
*
|
|
849
|
+
*/
|
|
331
850
|
VeLivePushStatusConnecting = 1,
|
|
332
851
|
|
|
852
|
+
/** {en}
|
|
853
|
+
* @brief The connection with the server is established.
|
|
854
|
+
*
|
|
855
|
+
*/
|
|
333
856
|
VeLivePushStatusConnectSuccess = 2,
|
|
334
857
|
|
|
858
|
+
/** {en}
|
|
859
|
+
* @brief Reconnecting to the server.
|
|
860
|
+
*
|
|
861
|
+
*/
|
|
335
862
|
VeLivePushStatusReconnecting = 3,
|
|
336
863
|
|
|
864
|
+
/** {en}
|
|
865
|
+
* @brief Stops connecting to the server.
|
|
866
|
+
*
|
|
867
|
+
*/
|
|
337
868
|
VeLivePushStatusConnectStop = 4,
|
|
338
869
|
|
|
870
|
+
/** {en}
|
|
871
|
+
* @brief Fails to connect to the server.
|
|
872
|
+
*
|
|
873
|
+
*/
|
|
339
874
|
VeLivePushStatusConnectError = 5,
|
|
340
875
|
|
|
876
|
+
/** {en}
|
|
877
|
+
* @brief The connection with the server is lost.
|
|
878
|
+
*
|
|
879
|
+
*/
|
|
341
880
|
VeLivePushStatusDisconnected = 6
|
|
342
881
|
}
|
|
343
882
|
export declare enum VeLiveFirstFrameType {
|
|
344
883
|
|
|
884
|
+
/** {en}
|
|
885
|
+
* @brief The first audio or video frame captured by the microphone or the camera.
|
|
886
|
+
*
|
|
887
|
+
*/
|
|
345
888
|
VeLiveFirstCaptureFrame = 0,
|
|
346
889
|
|
|
890
|
+
/** {en}
|
|
891
|
+
* @brief The first video frame rendered, which is the first frame displayed on the screen.
|
|
892
|
+
*
|
|
893
|
+
*/
|
|
347
894
|
VeLiveFirstRenderFrame = 1,
|
|
348
895
|
|
|
896
|
+
/** {en}
|
|
897
|
+
* @brief The first audio or video frame encoded.
|
|
898
|
+
*
|
|
899
|
+
*/
|
|
349
900
|
VeLiveFirstEncodedFrame = 2,
|
|
350
901
|
|
|
902
|
+
/** {en}
|
|
903
|
+
* @brief The first audio or video frame transmitted through the network.
|
|
904
|
+
*
|
|
905
|
+
*/
|
|
351
906
|
VeLiveFirstSendFrame = 3,
|
|
352
907
|
|
|
908
|
+
/** {en}
|
|
909
|
+
* @brief The first audio frame captured from the app after screen streaming starts.
|
|
910
|
+
*
|
|
911
|
+
*/
|
|
353
912
|
VeLiveFirstAppAudioCaptureFrame = 4
|
|
354
913
|
}
|
|
355
914
|
export declare enum VeLiveAudioSampleRate {
|
|
356
915
|
|
|
916
|
+
/** {en}
|
|
917
|
+
* @brief 44.1K. This sample rate is suitable for most audio processing scenarios, and is the standard sampling rate for music CDs.
|
|
918
|
+
*
|
|
919
|
+
*/
|
|
357
920
|
VeLiveAudioSampleRate44100 = 44100
|
|
358
921
|
}
|
|
359
922
|
export declare class VeLivePusherStatistics {
|
|
360
923
|
|
|
924
|
+
/** {en}
|
|
925
|
+
* @brief The width of the captured video, in pixels.
|
|
926
|
+
*/
|
|
361
927
|
captureWidth: int;
|
|
362
928
|
|
|
929
|
+
/** {en}
|
|
930
|
+
* @brief The height of the captured video, in pixels.
|
|
931
|
+
*/
|
|
363
932
|
captureHeight: int;
|
|
364
933
|
|
|
934
|
+
/** {en}
|
|
935
|
+
* @brief The captured frame rate, in fps.
|
|
936
|
+
*/
|
|
365
937
|
captureFps: int;
|
|
366
938
|
|
|
939
|
+
/** {en}
|
|
940
|
+
* @brief The width of the encoded video, in pixels.
|
|
941
|
+
*/
|
|
367
942
|
encodeWidth: int;
|
|
368
943
|
|
|
944
|
+
/** {en}
|
|
945
|
+
* @brief The height of the encoded video, in pixels.
|
|
946
|
+
*/
|
|
369
947
|
encodeHeight: int;
|
|
370
948
|
|
|
949
|
+
/** {en}
|
|
950
|
+
* @brief The encoded frame rate, in fps.
|
|
951
|
+
*/
|
|
371
952
|
encodeFps: int;
|
|
372
953
|
|
|
954
|
+
/** {en}
|
|
955
|
+
* @brief The encoded video bitrate, in Kbps.
|
|
956
|
+
*/
|
|
373
957
|
encodeVideoBitrate: int;
|
|
374
958
|
|
|
959
|
+
/** {en}
|
|
960
|
+
* @brief The encoded audio bitrate, in Kbps.
|
|
961
|
+
*/
|
|
375
962
|
encodeAudioBitrate: int;
|
|
376
963
|
|
|
964
|
+
/** {en}
|
|
965
|
+
* @brief The transmission frame rate, in fps. You can use this parameter to showcase the real-time frame rate on the user interface.
|
|
966
|
+
*/
|
|
377
967
|
transportFps: int;
|
|
378
968
|
|
|
969
|
+
/** {en}
|
|
970
|
+
* @brief The transmission bitrate, in Kbps. You can use this parameter to showcase the real-time bitrate on the user interface.
|
|
971
|
+
*/
|
|
379
972
|
transportVideoBitrate: int;
|
|
380
973
|
|
|
974
|
+
/** {en}
|
|
975
|
+
* @brief The encoded frame rate you specify in the setVideoEncoderConfiguration:{@link #VeLivePusher#setVideoEncoderConfiguration} method, in fps.
|
|
976
|
+
*/
|
|
381
977
|
fps: int;
|
|
382
978
|
|
|
979
|
+
/** {en}
|
|
980
|
+
* @brief The encoded bitrate you specify in the [setVideoEncoderConfiguration](docs-broadcast-sdk-for-ios-api#VeLivePusher-setvideoencoderconfiguration) method, in Kbps.
|
|
981
|
+
*/
|
|
383
982
|
videoBitrate: int;
|
|
384
983
|
|
|
984
|
+
/** {en}
|
|
985
|
+
* @brief The minimum encoded bitrate you specify in the [etVideoEncoderConfiguration:](docs-broadcast-sdk-for-ios-api#VeLivePusher-setvideoencoderconfiguration) method, in Kbps.
|
|
986
|
+
*/
|
|
385
987
|
minVideoBitrate: int;
|
|
386
988
|
|
|
989
|
+
/** {en}
|
|
990
|
+
* @brief The maximum encoded bitrate you specify in the setVideoEncoderConfiguration:{@link #VeLivePusher#setVideoEncoderConfiguration} method, in Kbps.
|
|
991
|
+
*/
|
|
387
992
|
maxVideoBitrate: int;
|
|
388
993
|
|
|
994
|
+
/** {en}
|
|
995
|
+
* @brief The push stream address.
|
|
996
|
+
*/
|
|
389
997
|
url: NSString;
|
|
390
998
|
|
|
999
|
+
/** {en}
|
|
1000
|
+
* @brief The video codec.
|
|
1001
|
+
*/
|
|
391
1002
|
codec: NSString;
|
|
392
1003
|
init(): this;
|
|
393
1004
|
}
|
|
394
1005
|
export declare enum VeLivePixelFormat {
|
|
395
1006
|
|
|
1007
|
+
/** {en}
|
|
1008
|
+
* @brief Unknown format.
|
|
1009
|
+
*
|
|
1010
|
+
*/
|
|
396
1011
|
VeLivePixelFormatUnknown = -1,
|
|
397
1012
|
|
|
1013
|
+
/** {en}
|
|
1014
|
+
* @brief I420.
|
|
1015
|
+
*
|
|
1016
|
+
*/
|
|
398
1017
|
VeLivePixelFormatI420 = 0,
|
|
399
1018
|
|
|
1019
|
+
/** {en}
|
|
1020
|
+
* @brief NV12.
|
|
1021
|
+
*
|
|
1022
|
+
*/
|
|
400
1023
|
VeLivePixelFormatNV12 = 1,
|
|
401
1024
|
|
|
1025
|
+
/** {en}
|
|
1026
|
+
* @brief NV21 format.
|
|
1027
|
+
*
|
|
1028
|
+
*/
|
|
402
1029
|
VeLivePixelFormatNV21 = 2,
|
|
403
1030
|
|
|
1031
|
+
/** {en}
|
|
1032
|
+
* @brief RAGBA.
|
|
1033
|
+
*
|
|
1034
|
+
*/
|
|
404
1035
|
VeLivePixelFormatBGRA32 = 3,
|
|
405
1036
|
|
|
1037
|
+
/** {en}
|
|
1038
|
+
* @brief OpenGL 2D texture.
|
|
1039
|
+
*
|
|
1040
|
+
*/
|
|
406
1041
|
VeLivePixelFormat2DTexture = 4
|
|
407
1042
|
}
|
|
408
1043
|
export declare class VeLiveVideoCaptureConfiguration {
|
|
409
1044
|
|
|
1045
|
+
/** {en}
|
|
1046
|
+
* @brief The width of the captured video, in pixels. The default value is `720`.
|
|
1047
|
+
*/
|
|
410
1048
|
width: int;
|
|
411
1049
|
|
|
1050
|
+
/** {en}
|
|
1051
|
+
* @brief The height of the captured video, in pixels. The default value is `1280`.
|
|
1052
|
+
*/
|
|
412
1053
|
height: int;
|
|
413
1054
|
|
|
1055
|
+
/** {en}
|
|
1056
|
+
* @brief The captured frame rate, in fps. The default value is `15`.
|
|
1057
|
+
*/
|
|
414
1058
|
fps: int;
|
|
415
1059
|
|
|
1060
|
+
/** {en}
|
|
1061
|
+
* @brief The pixel format. The default format is kCVPixelFormatType_420YpCbCr8BiPlanarFullRange.
|
|
1062
|
+
* @note The following formats are supported:
|
|
1063
|
+
* - kCVPixelFormatType_32BGRA
|
|
1064
|
+
* - kCVPixelFormatType_420YpCbCr8BiPlanarFullRange
|
|
1065
|
+
* - kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange
|
|
1066
|
+
* - kCVPixelFormatType_420YpCbCr10BiPlanarVideoRange
|
|
1067
|
+
*/
|
|
416
1068
|
pixelFormat: OSType;
|
|
417
1069
|
init(): this;
|
|
418
1070
|
}
|
|
419
1071
|
export declare class VeLiveAudioFrame {
|
|
420
1072
|
|
|
1073
|
+
/** {en}
|
|
1074
|
+
* @brief The audio data type. The default value is `VeLiveAudioBufferTypeUnknown`. See [VeLiveAudioBufferType](#VeLiveAudioBufferType) for details.
|
|
1075
|
+
*/
|
|
421
1076
|
bufferType: VeLiveAudioBufferType;
|
|
422
1077
|
|
|
1078
|
+
/** {en}
|
|
1079
|
+
* @brief The audio sample rate. See [VeLiveAudioSampleRate](#VeLiveAudioSampleRate) for details.
|
|
1080
|
+
*/
|
|
423
1081
|
sampleRate: VeLiveAudioSampleRate;
|
|
424
1082
|
|
|
1083
|
+
/** {en}
|
|
1084
|
+
* @brief The number of audio channels. See [VeLiveAudioChannel](#VeLiveAudioChannel) for details.
|
|
1085
|
+
*/
|
|
425
1086
|
channels: VeLiveAudioChannel;
|
|
426
1087
|
|
|
1088
|
+
/** {en}
|
|
1089
|
+
* @brief The audio frame timestamp, in μs, when `bufferType` is `VeLiveAudioBufferNSData`.
|
|
1090
|
+
*/
|
|
427
1091
|
pts: CMTime;
|
|
428
1092
|
|
|
1093
|
+
/** {en}
|
|
1094
|
+
* @brief The audio data, when `bufferType` is `VeLiveAudioBufferTypeSampleBuffer`.
|
|
1095
|
+
*/
|
|
429
1096
|
sampleBuffer: CMSampleBufferRef;
|
|
430
1097
|
|
|
1098
|
+
/** {en}
|
|
1099
|
+
* @brief The audio data, when `bufferType` is `VeLiveAudioBufferTypeNSData`. The audio data is of type float32 and is stored in little-endian byte order.
|
|
1100
|
+
*/
|
|
431
1101
|
data: NSData;
|
|
432
1102
|
init(): this;
|
|
433
1103
|
}
|
|
434
1104
|
export declare enum VeLiveAudioPowerLevel {
|
|
435
1105
|
|
|
1106
|
+
/** {en}
|
|
1107
|
+
* @brief Muted. The volume is 1 dB or less.
|
|
1108
|
+
*
|
|
1109
|
+
*/
|
|
436
1110
|
VeLiveAudioPowerLevelSilent = 0,
|
|
437
1111
|
|
|
1112
|
+
/** {en}
|
|
1113
|
+
* @brief Quiet. The volume is below 15 dB.
|
|
1114
|
+
*
|
|
1115
|
+
*/
|
|
438
1116
|
VeLiveAudioPowerLevelQuiet = 1,
|
|
439
1117
|
|
|
1118
|
+
/** {en}
|
|
1119
|
+
* @brief Soft, close to whisper. The volume is between 16 dB and 30 dB.
|
|
1120
|
+
*
|
|
1121
|
+
*/
|
|
440
1122
|
VeLiveAudioPowerLevelLight = 2,
|
|
441
1123
|
|
|
1124
|
+
/** {en}
|
|
1125
|
+
* @brief Normal, similar to the volume in a daily conversation. The volume is between 30 dB and 60 dB.
|
|
1126
|
+
*
|
|
1127
|
+
*/
|
|
442
1128
|
VeLiveAudioPowerLevelNormal = 3,
|
|
443
1129
|
|
|
1130
|
+
/** {en}
|
|
1131
|
+
* @brief Loud, similar to the volume of the noise at cafes. The volume is between 61 dB and 85 dB.
|
|
1132
|
+
*
|
|
1133
|
+
*/
|
|
444
1134
|
VeLiveAudioPowerLevelLoud = 4,
|
|
445
1135
|
|
|
1136
|
+
/** {en}
|
|
1137
|
+
* @brief Noisy, similar to the volume of the noise on a busy street or at a concert. The volume is higher than 85 dB.
|
|
1138
|
+
*
|
|
1139
|
+
*/
|
|
446
1140
|
VeLiveAudioPowerLevelNoisy = 5
|
|
447
1141
|
}
|
|
448
1142
|
export declare enum UIInterfaceOrientation {
|