@byteplus/react-native-live-push 1.0.1 → 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,383 +1,209 @@
|
|
|
1
|
-
import { VeLiveVideoFrame, VeLiveAudioFrame } from './api';
|
|
2
1
|
import * as $p_a from '../android/index';
|
|
3
2
|
import * as $p_i from '../ios/index';
|
|
3
|
+
import { VeLiveVideoFrame, VeLiveAudioFrame } from './api';
|
|
4
|
+
import { Bitmap, JSONObject } from './types';
|
|
4
5
|
import { VeLivePusherStatus, VeLiveFirstFrameType, VeLiveNetworkQuality, VeLiveAudioPowerLevel, VeLivePusherStatistics } from './keytype';
|
|
5
6
|
|
|
6
|
-
/** {en}
|
|
7
|
-
* @detail callback
|
|
8
|
-
* @list overview
|
|
9
|
-
* @brief A custom video processing callback.
|
|
10
|
-
*/
|
|
11
7
|
export interface VeLiveVideoFrameFilter {
|
|
12
|
-
|
|
13
|
-
/** {en}
|
|
14
|
-
* @detail callback
|
|
15
|
-
* @group 回调
|
|
16
|
-
* @brief Occurs when the SDK captures a video frame. You can use the callback to process the frame in a custom way.
|
|
17
|
-
* @param srcFrame The source video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
18
|
-
* @param dstFrame The processed video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
19
|
-
* @order 15
|
|
20
|
-
* @return
|
|
21
|
-
* - 0: The video frame is successfully processed;
|
|
22
|
-
* - < 0: The processing has failed. The frame will be discarded by the SDK;
|
|
23
|
-
* - \> 0: The processing has failed. The frame will be passed to the encoder by the SDK.
|
|
24
|
-
*/
|
|
25
|
-
onVideoProcess?(srcFrame: VeLiveVideoFrame, dstFrame: VeLiveVideoFrame): number;
|
|
26
|
-
}
|
|
27
|
-
export declare class android_VeLiveVideoFrameFilter extends $p_a.VeLiveVideoFrameFilter {
|
|
28
|
-
protected _instance: VeLiveVideoFrameFilter;
|
|
29
|
-
constructor(_instance: VeLiveVideoFrameFilter);
|
|
30
|
-
onVideoProcess(arg_0: $p_a.VeLiveVideoFrame, arg_1: $p_a.VeLiveVideoFrame): number;
|
|
31
|
-
}
|
|
32
|
-
export declare class ios_VeLiveVideoFrameFilter extends $p_i.VeLiveVideoFrameFilter {
|
|
33
|
-
protected _instance: VeLiveVideoFrameFilter;
|
|
34
|
-
constructor(_instance: VeLiveVideoFrameFilter);
|
|
35
|
-
onVideoProcess(arg_0: $p_i.VeLiveVideoFrame, arg_1: $p_i.VeLiveVideoFrame): number;
|
|
36
8
|
}
|
|
37
9
|
|
|
38
|
-
/** {en}
|
|
39
|
-
* @detail callback
|
|
40
|
-
* @list overview
|
|
41
|
-
* @brief The listener for video frames.
|
|
42
|
-
*/
|
|
43
10
|
export interface VeLiveVideoFrameListener {
|
|
44
11
|
|
|
45
12
|
/** {en}
|
|
46
13
|
* @detail callback
|
|
47
|
-
* @
|
|
48
|
-
* @brief Occurs when a video frame is captured. This callback will be triggered only if you return `VeLiveVideoFrameSourceCapture` when implementing the {@link #VeLiveVideoFrameListener#getObservedVideoFrameSource getObservedVideoFrameSource} callback method.
|
|
14
|
+
* @brief Occurs when a video frame is captured. This callback will be triggered only if you return `VeLiveVideoFrameSourceCapture` when implementing the getObservedVideoFrameSource{@link #VeLiveVideoFrameListener#getObservedVideoFrameSource} callback method.
|
|
49
15
|
* @param frame The captured video frame. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
50
16
|
* @order 18
|
|
17
|
+
*
|
|
51
18
|
*/
|
|
52
19
|
onCaptureVideoFrame?(frame: VeLiveVideoFrame): void;
|
|
53
20
|
|
|
54
21
|
/** {en}
|
|
55
22
|
* @detail callback
|
|
56
|
-
* @
|
|
57
|
-
* @brief Occurs when a video frame is to be encoded. This callback will be triggered only if you return `VeLiveVideoFrameSourcePreEncode` when implementing the {@link #VeLiveVideoFrameListener#getObservedVideoFrameSource getObservedVideoFrameSource} callback method.
|
|
23
|
+
* @brief Occurs when a video frame is to be encoded. This callback will be triggered only if you return `VeLiveVideoFrameSourcePreEncode` when implementing the getObservedVideoFrameSource{@link #VeLiveVideoFrameListener#getObservedVideoFrameSource} callback method.
|
|
58
24
|
* @param frame The video frame to be encoded. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
59
25
|
* @order 19
|
|
26
|
+
*
|
|
60
27
|
*/
|
|
61
28
|
onPreEncodeVideoFrame?(frame: VeLiveVideoFrame): void;
|
|
62
29
|
}
|
|
63
|
-
export declare class android_VeLiveVideoFrameListener extends $p_a.VeLiveVideoFrameListener {
|
|
64
|
-
protected _instance: VeLiveVideoFrameListener;
|
|
65
|
-
constructor(_instance: VeLiveVideoFrameListener);
|
|
66
|
-
onCaptureVideoFrame(arg_0: $p_a.VeLiveVideoFrame): void;
|
|
67
|
-
onPreEncodeVideoFrame(arg_0: $p_a.VeLiveVideoFrame): void;
|
|
68
|
-
}
|
|
69
|
-
export declare class ios_VeLiveVideoFrameListener extends $p_i.VeLiveVideoFrameListener {
|
|
70
|
-
protected _instance: VeLiveVideoFrameListener;
|
|
71
|
-
constructor(_instance: VeLiveVideoFrameListener);
|
|
72
|
-
onCaptureVideoFrame(arg_0: $p_i.VeLiveVideoFrame): void;
|
|
73
|
-
onPreEncodeVideoFrame(arg_0: $p_i.VeLiveVideoFrame): void;
|
|
74
|
-
}
|
|
75
30
|
|
|
76
|
-
/** {en}
|
|
77
|
-
* @platform android
|
|
78
|
-
* @detail callback
|
|
79
|
-
* @list overview
|
|
80
|
-
* @brief The listener for special effect events.
|
|
81
|
-
*/
|
|
82
|
-
export interface VeLiveVideoEffectCallback {
|
|
83
|
-
|
|
84
|
-
/** {en}
|
|
85
|
-
* @platform android
|
|
86
|
-
* @detail callback
|
|
87
|
-
* @group 回调
|
|
88
|
-
* @brief Occurs when special effects are processed.
|
|
89
|
-
* @param result The result.
|
|
90
|
-
* @param msg The message.
|
|
91
|
-
*/
|
|
92
|
-
android_onResult?(result: number, msg: string): void;
|
|
93
|
-
}
|
|
94
|
-
export declare class android_VeLiveVideoEffectCallback extends $p_a.VeLiveVideoEffectCallback {
|
|
95
|
-
protected _instance: VeLiveVideoEffectCallback;
|
|
96
|
-
constructor(_instance: VeLiveVideoEffectCallback);
|
|
97
|
-
onResult(arg_0: $p_a.int, arg_1: string): void;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
/** {en}
|
|
101
|
-
* @detail callback
|
|
102
|
-
* @list overview
|
|
103
|
-
* @brief Observer that listens for playback-related events of the media player.
|
|
104
|
-
*/
|
|
105
31
|
export interface VeLiveMediaPlayerListener {
|
|
106
32
|
|
|
107
33
|
/** {en}
|
|
108
34
|
* @detail callback
|
|
109
|
-
* @group 回调
|
|
110
35
|
* @brief Occurs when the playback starts.
|
|
111
|
-
*
|
|
112
|
-
* @order 1
|
|
36
|
+
*
|
|
113
37
|
*/
|
|
114
|
-
onStart?(
|
|
38
|
+
onStart?(): void;
|
|
115
39
|
|
|
116
40
|
/** {en}
|
|
117
41
|
* @detail callback
|
|
118
|
-
* @group 回调
|
|
119
42
|
* @brief Occurs every 100 ms to report the playback progress.
|
|
120
43
|
* @param timeMs The playback progress, in milliseconds.
|
|
44
|
+
*
|
|
121
45
|
*/
|
|
122
46
|
onProgress?(timeMs: number): void;
|
|
123
47
|
|
|
124
48
|
/** {en}
|
|
125
49
|
* @detail callback
|
|
126
|
-
* @group 回调
|
|
127
50
|
* @brief Occurs when the playback stops.
|
|
51
|
+
*
|
|
128
52
|
*/
|
|
129
53
|
onStop?(): void;
|
|
130
54
|
|
|
131
55
|
/** {en}
|
|
132
56
|
* @detail callback
|
|
133
|
-
* @group 回调
|
|
134
57
|
* @brief Occurs when an error occurs in the media player.
|
|
135
58
|
* @param code The error code. See VeLivePusherErrorCode {@link #VeLivePusherErrorCode} for details.
|
|
136
59
|
* @param msg The error message.
|
|
60
|
+
*
|
|
137
61
|
*/
|
|
138
|
-
onError?(
|
|
139
|
-
}
|
|
140
|
-
export declare class android_VeLiveMediaPlayerListener extends $p_a.VeLiveMediaPlayerListener {
|
|
141
|
-
protected _instance: VeLiveMediaPlayerListener;
|
|
142
|
-
constructor(_instance: VeLiveMediaPlayerListener);
|
|
143
|
-
onStart(arg_0: $p_a.Bundle): void;
|
|
144
|
-
onProgress(arg_0: $p_a.long): void;
|
|
145
|
-
onStop(): void;
|
|
146
|
-
onError(arg_0: $p_a.int, arg_1: string): void;
|
|
147
|
-
}
|
|
148
|
-
export declare class ios_VeLiveMediaPlayerListener extends $p_i.VeLiveMediaPlayerListener {
|
|
149
|
-
protected _instance: VeLiveMediaPlayerListener;
|
|
150
|
-
constructor(_instance: VeLiveMediaPlayerListener);
|
|
151
|
-
onStart(): void;
|
|
152
|
-
onProgress(arg_0: $p_i.long): void;
|
|
153
|
-
onStop(): void;
|
|
154
|
-
onError(arg_0: $p_i.NSError): void;
|
|
62
|
+
onError?(error: number): void;
|
|
155
63
|
}
|
|
156
64
|
|
|
157
|
-
/** {en}
|
|
158
|
-
* @detail callback
|
|
159
|
-
* @list overview
|
|
160
|
-
* @brief The listener for audio frames.
|
|
161
|
-
*/
|
|
162
65
|
export interface VeLiveAudioFrameListener {
|
|
163
66
|
|
|
164
67
|
/** {en}
|
|
165
68
|
* @detail callback
|
|
166
|
-
* @
|
|
167
|
-
* @brief Occurs when an audio frame is captured. This callback will be triggered only if you return `VeLiveAudioFrameSourceCapture` when implementing the {@link #VeLiveAudioFrameListener#getObservedAudioFrameSource getObservedAudioFrameSource} callback method.
|
|
69
|
+
* @brief Occurs when an audio frame is captured. This callback will be triggered only if you return `VeLiveAudioFrameSourceCapture` when implementing the getObservedAudioFrameSource{@link #VeLiveAudioFrameListener#getObservedAudioFrameSource} callback method.
|
|
168
70
|
* @param frame The captured audio frame data. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
169
71
|
* @order 21
|
|
72
|
+
*
|
|
170
73
|
*/
|
|
171
74
|
onCaptureAudioFrame?(frame: VeLiveAudioFrame): void;
|
|
172
75
|
|
|
173
76
|
/** {en}
|
|
174
77
|
* @detail callback
|
|
175
|
-
* @
|
|
176
|
-
* @brief Occurs when an audio frame is to be encoded. This callback will be triggered only if you return `VeLiveAudioFrameSourcePreEncode` when implementing the {@link #VeLiveAudioFrameListener#getObservedAudioFrameSource getObservedAudioFrameSource} callback method.
|
|
78
|
+
* @brief Occurs when an audio frame is to be encoded. This callback will be triggered only if you return `VeLiveAudioFrameSourcePreEncode` when implementing the getObservedAudioFrameSource{@link #VeLiveAudioFrameListener#getObservedAudioFrameSource} callback method.
|
|
177
79
|
* @param frame The audio frame to be encoded. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
178
80
|
* @order 22
|
|
81
|
+
*
|
|
179
82
|
*/
|
|
180
83
|
onPreEncodeAudioFrame?(frame: VeLiveAudioFrame): void;
|
|
181
84
|
}
|
|
182
|
-
export declare class android_VeLiveAudioFrameListener extends $p_a.VeLiveAudioFrameListener {
|
|
183
|
-
protected _instance: VeLiveAudioFrameListener;
|
|
184
|
-
constructor(_instance: VeLiveAudioFrameListener);
|
|
185
|
-
onCaptureAudioFrame(arg_0: $p_a.VeLiveAudioFrame): void;
|
|
186
|
-
onPreEncodeAudioFrame(arg_0: $p_a.VeLiveAudioFrame): void;
|
|
187
|
-
}
|
|
188
|
-
export declare class ios_VeLiveAudioFrameListener extends $p_i.VeLiveAudioFrameListener {
|
|
189
|
-
protected _instance: VeLiveAudioFrameListener;
|
|
190
|
-
constructor(_instance: VeLiveAudioFrameListener);
|
|
191
|
-
onCaptureAudioFrame(arg_0: $p_i.VeLiveAudioFrame): void;
|
|
192
|
-
onPreEncodeAudioFrame(arg_0: $p_i.VeLiveAudioFrame): void;
|
|
193
|
-
}
|
|
194
85
|
|
|
195
|
-
/** {en}
|
|
196
|
-
* @detail callback
|
|
197
|
-
* @list overview
|
|
198
|
-
* @brief Observer that listens for audio and video frames of the media player.
|
|
199
|
-
*/
|
|
200
86
|
export interface VeLiveMediaPlayerFrameListener {
|
|
201
87
|
|
|
202
88
|
/** {en}
|
|
203
89
|
* @detail callback
|
|
204
|
-
* @group 回调
|
|
205
90
|
* @brief Occurs when the media player decodes an audio frame.
|
|
206
91
|
* @param frame The audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
92
|
+
*
|
|
207
93
|
*/
|
|
208
94
|
onAudioFrame?(frame: VeLiveAudioFrame): void;
|
|
209
95
|
|
|
210
96
|
/** {en}
|
|
211
97
|
* @detail callback
|
|
212
|
-
* @group 回调
|
|
213
98
|
* @brief Occurs when the media player decodes a video frame.
|
|
214
99
|
* @param frame The video frame, including the timestamp, pixel format, and other information. See VeLiveVideoFrame {@link #VeLiveVideoFrame} for details.
|
|
100
|
+
*
|
|
215
101
|
*/
|
|
216
102
|
onVideoFrame?(frame: VeLiveVideoFrame): void;
|
|
217
103
|
}
|
|
218
|
-
export declare class android_VeLiveMediaPlayerFrameListener extends $p_a.VeLiveMediaPlayerFrameListener {
|
|
219
|
-
protected _instance: VeLiveMediaPlayerFrameListener;
|
|
220
|
-
constructor(_instance: VeLiveMediaPlayerFrameListener);
|
|
221
|
-
onAudioFrame(arg_0: $p_a.VeLiveAudioFrame): void;
|
|
222
|
-
onVideoFrame(arg_0: $p_a.VeLiveVideoFrame): void;
|
|
223
|
-
}
|
|
224
|
-
export declare class ios_VeLiveMediaPlayerFrameListener extends $p_i.VeLiveMediaPlayerFrameListener {
|
|
225
|
-
protected _instance: VeLiveMediaPlayerFrameListener;
|
|
226
|
-
constructor(_instance: VeLiveMediaPlayerFrameListener);
|
|
227
|
-
onAudioFrame(arg_0: $p_i.VeLiveAudioFrame): void;
|
|
228
|
-
onVideoFrame(arg_0: $p_i.VeLiveVideoFrame): void;
|
|
229
|
-
}
|
|
230
104
|
|
|
231
|
-
/** {en}
|
|
232
|
-
* @detail callback
|
|
233
|
-
* @list overview
|
|
234
|
-
* @brief The listener for screenshot capturing events.
|
|
235
|
-
*/
|
|
236
105
|
export interface VeLiveSnapshotListener {
|
|
237
106
|
|
|
238
107
|
/** {en}
|
|
239
108
|
* @detail callback
|
|
240
|
-
* @group 回调
|
|
241
109
|
* @brief Occurs when a screenshot is successfully taken after snapshot {@link #VeLivePusher#snapshot} is called.
|
|
242
110
|
* @param image The screenshot image.
|
|
243
111
|
* @order 15
|
|
112
|
+
*
|
|
244
113
|
*/
|
|
245
|
-
onSnapshotComplete?(image:
|
|
246
|
-
}
|
|
247
|
-
export declare class android_VeLiveSnapshotListener extends $p_a.VeLiveSnapshotListener {
|
|
248
|
-
protected _instance: VeLiveSnapshotListener;
|
|
249
|
-
constructor(_instance: VeLiveSnapshotListener);
|
|
250
|
-
onSnapshotComplete(arg_0: $p_a.Bitmap): void;
|
|
251
|
-
}
|
|
252
|
-
export declare class ios_VeLiveSnapshotListener extends $p_i.VeLiveSnapshotListener {
|
|
253
|
-
protected _instance: VeLiveSnapshotListener;
|
|
254
|
-
constructor(_instance: VeLiveSnapshotListener);
|
|
255
|
-
onSnapshotComplete(arg_0: $p_i.UIImage): void;
|
|
114
|
+
onSnapshotComplete?(image: Bitmap): void;
|
|
256
115
|
}
|
|
257
116
|
|
|
258
|
-
/** {en}
|
|
259
|
-
* @detail callback
|
|
260
|
-
* @list overview
|
|
261
|
-
* @brief A custom audio processing callback.
|
|
262
|
-
*/
|
|
263
117
|
export interface VeLiveAudioFrameFilter {
|
|
264
|
-
|
|
265
|
-
/** {en}
|
|
266
|
-
* @detail callback
|
|
267
|
-
* @group 回调
|
|
268
|
-
* @brief Occurs when the SDK captures an audio frame. You can use the callback to process the frame in a custom way.
|
|
269
|
-
* @param srcFrame The source audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
270
|
-
* @param dstFrame The processed audio frame. See VeLiveAudioFrame {@link #VeLiveAudioFrame} for details.
|
|
271
|
-
* - 0: Success;
|
|
272
|
-
* - ≠ 0: Failure. The frame will be passed to the encoder by the SDK.
|
|
273
|
-
* @order 16
|
|
274
|
-
*/
|
|
275
|
-
onAudioProcess?(srcFrame: VeLiveAudioFrame, dstFrame: VeLiveAudioFrame): number;
|
|
276
|
-
}
|
|
277
|
-
export declare class android_VeLiveAudioFrameFilter extends $p_a.VeLiveAudioFrameFilter {
|
|
278
|
-
protected _instance: VeLiveAudioFrameFilter;
|
|
279
|
-
constructor(_instance: VeLiveAudioFrameFilter);
|
|
280
|
-
onAudioProcess(arg_0: $p_a.VeLiveAudioFrame, arg_1: $p_a.VeLiveAudioFrame): number;
|
|
281
|
-
}
|
|
282
|
-
export declare class ios_VeLiveAudioFrameFilter extends $p_i.VeLiveAudioFrameFilter {
|
|
283
|
-
protected _instance: VeLiveAudioFrameFilter;
|
|
284
|
-
constructor(_instance: VeLiveAudioFrameFilter);
|
|
285
|
-
onAudioProcess(arg_0: $p_i.VeLiveAudioFrame, arg_1: $p_i.VeLiveAudioFrame): number;
|
|
286
118
|
}
|
|
287
119
|
|
|
288
|
-
/** {en}
|
|
289
|
-
* @detail callback
|
|
290
|
-
* @list overview
|
|
291
|
-
* @brief The observer for live pusher events, including errors, statuses, network quality, device information, and first frame rendering.
|
|
292
|
-
*/
|
|
293
120
|
export interface VeLivePusherObserver {
|
|
294
121
|
|
|
295
122
|
/** {en}
|
|
296
123
|
* @detail callback
|
|
297
|
-
* @group 回调
|
|
298
124
|
* @brief Occurs when a streaming error occurs.
|
|
299
125
|
* @param code The error code. See VeLivePusherErrorCode {@link #VeLivePusherErrorCode} for details.
|
|
300
126
|
* @param subCode The subcode.
|
|
301
127
|
* @param msg The error message.
|
|
302
128
|
* @order 1
|
|
129
|
+
*
|
|
303
130
|
*/
|
|
304
131
|
onError?(code: number, subCode: number, msg: string): void;
|
|
305
132
|
|
|
306
133
|
/** {en}
|
|
307
134
|
* @detail callback
|
|
308
|
-
* @group 回调
|
|
309
135
|
* @brief Occurs when the streaming status changes.
|
|
310
136
|
* @param status The updated streaming status. See VeLivePusherStatus {@link #VeLivePusherStatus} for details.
|
|
311
137
|
* @order 2
|
|
138
|
+
*
|
|
312
139
|
*/
|
|
313
140
|
onStatusChange?(status: VeLivePusherStatus): void;
|
|
314
141
|
|
|
315
142
|
/** {en}
|
|
316
143
|
* @detail callback
|
|
317
|
-
* @group 回调
|
|
318
144
|
* @brief Occurs when the live pusher sends the first video frame.
|
|
319
145
|
* @param type The type of the first frame. See VeLiveFirstFrameType {@link #VeLiveFirstFrameType} for details.
|
|
320
146
|
* @param timestampMs The timestamp, in milliseconds.
|
|
321
147
|
* @order 3
|
|
148
|
+
*
|
|
322
149
|
*/
|
|
323
150
|
onFirstVideoFrame?(type: VeLiveFirstFrameType, timestampMs: number): void;
|
|
324
151
|
|
|
325
152
|
/** {en}
|
|
326
153
|
* @detail callback
|
|
327
|
-
* @group 回调
|
|
328
154
|
* @brief Occurs when the live pusher sends the first audio frame.
|
|
329
155
|
* @param type The type of the first audio frame. See VeLiveFirstFrameType {@link #VeLiveFirstFrameType} for details.
|
|
330
156
|
* @param timestampMs The timestamp, in milliseconds.
|
|
331
157
|
* @order 4
|
|
158
|
+
*
|
|
332
159
|
*/
|
|
333
160
|
onFirstAudioFrame?(type: VeLiveFirstFrameType, timestampMs: number): void;
|
|
334
161
|
|
|
335
162
|
/** {en}
|
|
336
163
|
* @detail callback
|
|
337
|
-
* @group 回调
|
|
338
164
|
* @brief Occurs when the camera is turned on or turned off.
|
|
339
165
|
* @param open Whether the updated status of the camera is on. <br>
|
|
340
166
|
* - true: On;
|
|
341
167
|
* - false: Off.
|
|
342
168
|
* @order 5
|
|
169
|
+
*
|
|
343
170
|
*/
|
|
344
171
|
onCameraOpened?(open: boolean): void;
|
|
345
172
|
|
|
346
173
|
/** {en}
|
|
347
174
|
* @detail callback
|
|
348
|
-
* @group 回调
|
|
349
175
|
* @brief Occurs when the microphone is turned on or turned off.
|
|
350
176
|
* @param open Whether the updated status of the microphone is on. <br>
|
|
351
177
|
* - true: On;
|
|
352
178
|
* - false: Off.
|
|
353
179
|
* @order 6
|
|
180
|
+
*
|
|
354
181
|
*/
|
|
355
182
|
onMicrophoneOpened?(open: boolean): void;
|
|
356
183
|
|
|
357
184
|
/** {en}
|
|
358
185
|
* @platform android
|
|
359
186
|
* @detail callback
|
|
360
|
-
* @group 回调
|
|
361
187
|
* @brief Occurs when screen capture is turned on or turned off.
|
|
362
188
|
* @param open Whether the updated status of screen capture is on. <br>
|
|
363
189
|
* - true: On;
|
|
364
190
|
* - false: Off.
|
|
365
191
|
* @order 7
|
|
192
|
+
*
|
|
366
193
|
*/
|
|
367
|
-
android_onScreenRecording?(
|
|
194
|
+
android_onScreenRecording?(): void;
|
|
368
195
|
|
|
369
196
|
/** {en}
|
|
370
197
|
* @detail callback
|
|
371
|
-
* @group 回调
|
|
372
198
|
* @brief Occurs when the network quality changes.
|
|
373
199
|
* @param quality The updated network quality. See VeLiveNetworkQuality {@link #VeLiveNetworkQuality} for details.
|
|
374
200
|
* @order 8
|
|
201
|
+
*
|
|
375
202
|
*/
|
|
376
203
|
onNetworkQuality?(quality: VeLiveNetworkQuality): void;
|
|
377
204
|
|
|
378
205
|
/** {en}
|
|
379
206
|
* @detail callback
|
|
380
|
-
* @group 回调
|
|
381
207
|
* @brief Occurs when the audio volume level changes.
|
|
382
208
|
* @order 9
|
|
383
209
|
* @param level The updated volume level. See [VeLiveAudioPowerLevel](broadcast-sdk-for-android-type-definition\\#VeLiveAudioPowerLevel) for details.
|
|
@@ -389,154 +215,186 @@ export interface VeLivePusherObserver {
|
|
|
389
215
|
* - Decibel values greater than 30 and less than or equal to 60 correspond to the VeLiveAudioPowerLevelNormal level.
|
|
390
216
|
* - Decibel values greater than 60 and less than or equal to 85 correspond to the VeLiveAudioPowerLevelLoud level.
|
|
391
217
|
* - Decibel values greater than 85 correspond to the VeLiveAudioPowerLevelNoisy level.
|
|
218
|
+
*
|
|
392
219
|
*/
|
|
393
220
|
onAudioPowerQuality?(level: VeLiveAudioPowerLevel, value: number): void;
|
|
394
221
|
}
|
|
395
|
-
export declare class android_VeLivePusherObserver extends $p_a.VeLivePusherObserver {
|
|
396
|
-
protected _instance: VeLivePusherObserver;
|
|
397
|
-
constructor(_instance: VeLivePusherObserver);
|
|
398
|
-
onError(arg_0: $p_a.int, arg_1: $p_a.int, arg_2: string): void;
|
|
399
|
-
onStatusChange(arg_0: $p_a.VeLivePusherStatus): void;
|
|
400
|
-
onFirstVideoFrame(arg_0: $p_a.VeLiveFirstFrameType, arg_1: $p_a.long): void;
|
|
401
|
-
onFirstAudioFrame(arg_0: $p_a.VeLiveFirstFrameType, arg_1: $p_a.long): void;
|
|
402
|
-
onCameraOpened(arg_0: boolean): void;
|
|
403
|
-
onMicrophoneOpened(arg_0: boolean): void;
|
|
404
|
-
onScreenRecording(arg_0: boolean): void;
|
|
405
|
-
onNetworkQuality(arg_0: $p_a.VeLiveNetworkQuality): void;
|
|
406
|
-
onAudioPowerQuality(arg_0: $p_a.VeLiveAudioPowerLevel, arg_1: $p_a.float): void;
|
|
407
|
-
}
|
|
408
|
-
export declare class ios_VeLivePusherObserver extends $p_i.VeLivePusherObserver {
|
|
409
|
-
protected _instance: VeLivePusherObserver;
|
|
410
|
-
constructor(_instance: VeLivePusherObserver);
|
|
411
|
-
onError(arg_0: $p_i.int, arg_1: $p_i.int, arg_2: $p_i.NSString): void;
|
|
412
|
-
onStatusChange(arg_0: $p_i.VeLivePushStatus): void;
|
|
413
|
-
onFirstVideoFrame(arg_0: $p_i.VeLiveFirstFrameType, arg_1: $p_i.int64_t): void;
|
|
414
|
-
onFirstAudioFrame(arg_0: $p_i.VeLiveFirstFrameType, arg_1: $p_i.int64_t): void;
|
|
415
|
-
onCameraOpened(arg_0: $p_i.BOOL): void;
|
|
416
|
-
onMicrophoneOpened(arg_0: $p_i.BOOL): void;
|
|
417
|
-
onNetworkQuality(arg_0: $p_i.VeLiveNetworkQuality): void;
|
|
418
|
-
onAudioPowerQuality(arg_0: $p_i.VeLiveAudioPowerLevel, arg_1: $p_i.float): void;
|
|
419
|
-
}
|
|
420
222
|
|
|
421
|
-
/** {en}
|
|
422
|
-
* @detail callback
|
|
423
|
-
* @list overview
|
|
424
|
-
* @brief The observer that periodically reports streaming statistics.
|
|
425
|
-
*/
|
|
426
223
|
export interface VeLivePusherStatisticsObserver {
|
|
427
224
|
|
|
428
225
|
/** {en}
|
|
429
226
|
* @detail callback
|
|
430
|
-
* @group 回调
|
|
431
227
|
* @brief Occurs periodically to report streaming statistics. By default, the callback is triggered every 5 seconds.
|
|
432
228
|
* @order 10
|
|
433
229
|
* @param statistics The streaming statistics. See VeLivePusherStatistics for details.
|
|
230
|
+
*
|
|
434
231
|
*/
|
|
435
232
|
onStatistics?(statistics: VeLivePusherStatistics): void;
|
|
436
233
|
|
|
437
234
|
/** {en}
|
|
438
235
|
* @detail callback
|
|
439
|
-
* @group 回调
|
|
440
236
|
* @brief Occurs periodically to return log information.
|
|
441
237
|
* @param logInfo The log information.
|
|
442
238
|
* @order 11
|
|
239
|
+
*
|
|
443
240
|
*/
|
|
444
|
-
onLogMonitor?(logInfo:
|
|
445
|
-
}
|
|
446
|
-
export declare class android_VeLivePusherStatisticsObserver extends $p_a.VeLivePusherStatisticsObserver {
|
|
447
|
-
protected _instance: VeLivePusherStatisticsObserver;
|
|
448
|
-
constructor(_instance: VeLivePusherStatisticsObserver);
|
|
449
|
-
onStatistics(arg_0: $p_a.VeLivePusherStatistics): void;
|
|
450
|
-
onLogMonitor(arg_0: $p_a.JSONObject): void;
|
|
451
|
-
}
|
|
452
|
-
export declare class ios_VeLivePusherStatisticsObserver extends $p_i.VeLivePusherStatisticsObserver {
|
|
453
|
-
protected _instance: VeLivePusherStatisticsObserver;
|
|
454
|
-
constructor(_instance: VeLivePusherStatisticsObserver);
|
|
455
|
-
onStatistics(arg_0: $p_i.VeLivePusherStatistics): void;
|
|
456
|
-
onLogMonitor(arg_0: $p_i.NSDictionary): void;
|
|
457
|
-
}
|
|
458
|
-
export declare class VeLivePusherDef extends $p_a.VeLivePusherDef {
|
|
241
|
+
onLogMonitor?(logInfo: JSONObject): void;
|
|
459
242
|
}
|
|
460
243
|
|
|
461
|
-
/** {en}
|
|
462
|
-
* @detail callback
|
|
463
|
-
* @list overview
|
|
464
|
-
* @brief The observer for recording events.
|
|
465
|
-
*/
|
|
466
244
|
export interface VeLiveFileRecordingListener {
|
|
467
245
|
|
|
468
246
|
/** {en}
|
|
469
247
|
* @detail callback
|
|
470
|
-
* @group 回调
|
|
471
248
|
* @brief Occurs when recording starts.
|
|
472
249
|
* @order 12
|
|
250
|
+
*
|
|
473
251
|
*/
|
|
474
252
|
onFileRecordingStarted?(): void;
|
|
475
253
|
|
|
476
254
|
/** {en}
|
|
477
255
|
* @detail callback
|
|
478
|
-
* @group 回调
|
|
479
256
|
* @brief Occurs when recording stops.
|
|
480
257
|
* @order 13
|
|
258
|
+
*
|
|
481
259
|
*/
|
|
482
260
|
onFileRecordingStopped?(): void;
|
|
483
261
|
|
|
484
262
|
/** {en}
|
|
485
263
|
* @detail callback
|
|
486
|
-
* @group 回调
|
|
487
264
|
* @brief Occurs when an error occurs during recording.
|
|
488
265
|
* @param errorCode The error code. See VeLivePusherErrorCode {@link #VeLivePusherErrorCode} for details.
|
|
489
266
|
* @param message The error message.
|
|
490
267
|
* @order 14
|
|
268
|
+
*
|
|
491
269
|
*/
|
|
492
270
|
onFileRecordingError?(errorCode: number, message: string): void;
|
|
493
271
|
}
|
|
272
|
+
export declare class android_VeLiveVideoFrameFilter extends $p_a.VeLiveVideoFrameFilter {
|
|
273
|
+
protected _instance: VeLiveVideoFrameFilter;
|
|
274
|
+
constructor(_instance: VeLiveVideoFrameFilter);
|
|
275
|
+
}
|
|
276
|
+
export declare class ios_VeLiveVideoFrameFilter extends $p_i.VeLiveVideoFrameFilter {
|
|
277
|
+
protected _instance: VeLiveVideoFrameFilter;
|
|
278
|
+
constructor(_instance: VeLiveVideoFrameFilter);
|
|
279
|
+
}
|
|
280
|
+
export declare class android_VeLiveVideoFrameListener extends $p_a.VeLiveVideoFrameListener {
|
|
281
|
+
protected _instance: VeLiveVideoFrameListener;
|
|
282
|
+
constructor(_instance: VeLiveVideoFrameListener);
|
|
283
|
+
onCaptureVideoFrame(frame: $p_a.VeLiveVideoFrame): void;
|
|
284
|
+
onPreEncodeVideoFrame(frame: $p_a.VeLiveVideoFrame): void;
|
|
285
|
+
}
|
|
286
|
+
export declare class ios_VeLiveVideoFrameListener extends $p_i.VeLiveVideoFrameListener {
|
|
287
|
+
protected _instance: VeLiveVideoFrameListener;
|
|
288
|
+
constructor(_instance: VeLiveVideoFrameListener);
|
|
289
|
+
onCaptureVideoFrame(frame: $p_i.VeLiveVideoFrame): void;
|
|
290
|
+
onPreEncodeVideoFrame(frame: $p_i.VeLiveVideoFrame): void;
|
|
291
|
+
}
|
|
292
|
+
export declare class android_VeLiveMediaPlayerListener extends $p_a.VeLiveMediaPlayerListener {
|
|
293
|
+
protected _instance: VeLiveMediaPlayerListener;
|
|
294
|
+
constructor(_instance: VeLiveMediaPlayerListener);
|
|
295
|
+
onStart(info: $p_a.Bundle): void;
|
|
296
|
+
onProgress(timeMs: $p_a.long): void;
|
|
297
|
+
onStop(): void;
|
|
298
|
+
onError(code: $p_a.int, msg: string): void;
|
|
299
|
+
}
|
|
300
|
+
export declare class ios_VeLiveMediaPlayerListener extends $p_i.VeLiveMediaPlayerListener {
|
|
301
|
+
protected _instance: VeLiveMediaPlayerListener;
|
|
302
|
+
constructor(_instance: VeLiveMediaPlayerListener);
|
|
303
|
+
onStart(): void;
|
|
304
|
+
onProgress(timeMS: $p_i.long): void;
|
|
305
|
+
onStop(): void;
|
|
306
|
+
onError(error: $p_i.NSError): void;
|
|
307
|
+
}
|
|
308
|
+
export declare class android_VeLiveAudioFrameListener extends $p_a.VeLiveAudioFrameListener {
|
|
309
|
+
protected _instance: VeLiveAudioFrameListener;
|
|
310
|
+
constructor(_instance: VeLiveAudioFrameListener);
|
|
311
|
+
onCaptureAudioFrame(frame: $p_a.VeLiveAudioFrame): void;
|
|
312
|
+
onPreEncodeAudioFrame(frame: $p_a.VeLiveAudioFrame): void;
|
|
313
|
+
}
|
|
314
|
+
export declare class ios_VeLiveAudioFrameListener extends $p_i.VeLiveAudioFrameListener {
|
|
315
|
+
protected _instance: VeLiveAudioFrameListener;
|
|
316
|
+
constructor(_instance: VeLiveAudioFrameListener);
|
|
317
|
+
onCaptureAudioFrame(frame: $p_i.VeLiveAudioFrame): void;
|
|
318
|
+
onPreEncodeAudioFrame(frame: $p_i.VeLiveAudioFrame): void;
|
|
319
|
+
}
|
|
320
|
+
export declare class android_VeLiveMediaPlayerFrameListener extends $p_a.VeLiveMediaPlayerFrameListener {
|
|
321
|
+
protected _instance: VeLiveMediaPlayerFrameListener;
|
|
322
|
+
constructor(_instance: VeLiveMediaPlayerFrameListener);
|
|
323
|
+
onAudioFrame(frame: $p_a.VeLiveAudioFrame): void;
|
|
324
|
+
onVideoFrame(frame: $p_a.VeLiveVideoFrame): void;
|
|
325
|
+
}
|
|
326
|
+
export declare class ios_VeLiveMediaPlayerFrameListener extends $p_i.VeLiveMediaPlayerFrameListener {
|
|
327
|
+
protected _instance: VeLiveMediaPlayerFrameListener;
|
|
328
|
+
constructor(_instance: VeLiveMediaPlayerFrameListener);
|
|
329
|
+
onAudioFrame(audioFrame: $p_i.VeLiveAudioFrame): void;
|
|
330
|
+
onVideoFrame(videoFrame: $p_i.VeLiveVideoFrame): void;
|
|
331
|
+
}
|
|
332
|
+
export declare class android_VeLiveSnapshotListener extends $p_a.VeLiveSnapshotListener {
|
|
333
|
+
protected _instance: VeLiveSnapshotListener;
|
|
334
|
+
constructor(_instance: VeLiveSnapshotListener);
|
|
335
|
+
onSnapshotComplete(image: $p_a.Bitmap): void;
|
|
336
|
+
}
|
|
337
|
+
export declare class ios_VeLiveSnapshotListener extends $p_i.VeLiveSnapshotListener {
|
|
338
|
+
protected _instance: VeLiveSnapshotListener;
|
|
339
|
+
constructor(_instance: VeLiveSnapshotListener);
|
|
340
|
+
onSnapshotComplete(image: $p_i.UIImage): void;
|
|
341
|
+
}
|
|
342
|
+
export declare class android_VeLiveAudioFrameFilter extends $p_a.VeLiveAudioFrameFilter {
|
|
343
|
+
protected _instance: VeLiveAudioFrameFilter;
|
|
344
|
+
constructor(_instance: VeLiveAudioFrameFilter);
|
|
345
|
+
}
|
|
346
|
+
export declare class ios_VeLiveAudioFrameFilter extends $p_i.VeLiveAudioFrameFilter {
|
|
347
|
+
protected _instance: VeLiveAudioFrameFilter;
|
|
348
|
+
constructor(_instance: VeLiveAudioFrameFilter);
|
|
349
|
+
}
|
|
350
|
+
export declare class android_VeLivePusherObserver extends $p_a.VeLivePusherObserver {
|
|
351
|
+
protected _instance: VeLivePusherObserver;
|
|
352
|
+
constructor(_instance: VeLivePusherObserver);
|
|
353
|
+
onError(code: $p_a.int, subCode: $p_a.int, msg: string): void;
|
|
354
|
+
onStatusChange(status: $p_a.VeLivePusherStatus): void;
|
|
355
|
+
onFirstVideoFrame(type: $p_a.VeLiveFirstFrameType, timestampMs: $p_a.long): void;
|
|
356
|
+
onFirstAudioFrame(type: $p_a.VeLiveFirstFrameType, timestampMs: $p_a.long): void;
|
|
357
|
+
onCameraOpened(open: boolean): void;
|
|
358
|
+
onMicrophoneOpened(open: boolean): void;
|
|
359
|
+
onScreenRecording(open: boolean): void;
|
|
360
|
+
onNetworkQuality(quality: $p_a.VeLiveNetworkQuality): void;
|
|
361
|
+
onAudioPowerQuality(level: $p_a.VeLiveAudioPowerLevel, value: $p_a.float): void;
|
|
362
|
+
}
|
|
363
|
+
export declare class ios_VeLivePusherObserver extends $p_i.VeLivePusherObserver {
|
|
364
|
+
protected _instance: VeLivePusherObserver;
|
|
365
|
+
constructor(_instance: VeLivePusherObserver);
|
|
366
|
+
onError$subcode$message(code: $p_i.int, subcode: $p_i.int, msg: $p_i.NSString): void;
|
|
367
|
+
onStatusChange(status: $p_i.VeLivePushStatus): void;
|
|
368
|
+
onFirstVideoFrame$timestampMs(type: $p_i.VeLiveFirstFrameType, timestampMs: $p_i.int64_t): void;
|
|
369
|
+
onFirstAudioFrame$timestampMs(type: $p_i.VeLiveFirstFrameType, timestampMs: $p_i.int64_t): void;
|
|
370
|
+
onCameraOpened(open: $p_i.BOOL): void;
|
|
371
|
+
onMicrophoneOpened(open: $p_i.BOOL): void;
|
|
372
|
+
onNetworkQuality(quality: $p_i.VeLiveNetworkQuality): void;
|
|
373
|
+
onAudioPowerQuality$value(level: $p_i.VeLiveAudioPowerLevel, value: $p_i.float): void;
|
|
374
|
+
}
|
|
375
|
+
export declare class android_VeLivePusherStatisticsObserver extends $p_a.VeLivePusherStatisticsObserver {
|
|
376
|
+
protected _instance: VeLivePusherStatisticsObserver;
|
|
377
|
+
constructor(_instance: VeLivePusherStatisticsObserver);
|
|
378
|
+
onStatistics(statistics: $p_a.VeLivePusherStatistics): void;
|
|
379
|
+
onLogMonitor(logInfo: $p_a.JSONObject): void;
|
|
380
|
+
}
|
|
381
|
+
export declare class ios_VeLivePusherStatisticsObserver extends $p_i.VeLivePusherStatisticsObserver {
|
|
382
|
+
protected _instance: VeLivePusherStatisticsObserver;
|
|
383
|
+
constructor(_instance: VeLivePusherStatisticsObserver);
|
|
384
|
+
onStatistics(statistics: $p_i.VeLivePusherStatistics): void;
|
|
385
|
+
onLogMonitor(logInfo: $p_i.NSDictionary): void;
|
|
386
|
+
}
|
|
494
387
|
export declare class android_VeLiveFileRecordingListener extends $p_a.VeLiveFileRecordingListener {
|
|
495
388
|
protected _instance: VeLiveFileRecordingListener;
|
|
496
389
|
constructor(_instance: VeLiveFileRecordingListener);
|
|
497
390
|
onFileRecordingStarted(): void;
|
|
498
391
|
onFileRecordingStopped(): void;
|
|
499
|
-
onFileRecordingError(
|
|
392
|
+
onFileRecordingError(errorCode: $p_a.int, message: string): void;
|
|
500
393
|
}
|
|
501
394
|
export declare class ios_VeLiveFileRecordingListener extends $p_i.VeLiveFileRecordingListener {
|
|
502
395
|
protected _instance: VeLiveFileRecordingListener;
|
|
503
396
|
constructor(_instance: VeLiveFileRecordingListener);
|
|
504
397
|
onFileRecordingStarted(): void;
|
|
505
398
|
onFileRecordingStopped(): void;
|
|
506
|
-
onFileRecordingError(
|
|
507
|
-
}
|
|
508
|
-
|
|
509
|
-
/** {en}
|
|
510
|
-
* @platform android
|
|
511
|
-
* @detail callback
|
|
512
|
-
* @list overview
|
|
513
|
-
* @brief A video effects callback.
|
|
514
|
-
*/
|
|
515
|
-
export interface VeLiveVideoEffectHandleCallback {
|
|
516
|
-
|
|
517
|
-
/** {en}
|
|
518
|
-
* @platform android
|
|
519
|
-
* @detail callback
|
|
520
|
-
* @group 回调
|
|
521
|
-
* @brief Occurs when the setAdvancedFeature {@link #VeLiveVideoEffectManager #setAdvancedFeature} method is called. Please contact BytePlus technical support for assistance when using this callback method.
|
|
522
|
-
* @param handle The video effect object.
|
|
523
|
-
*/
|
|
524
|
-
android_onEffectHandle?(handle: Object): void;
|
|
525
|
-
}
|
|
526
|
-
export declare class android_VeLiveVideoEffectHandleCallback extends $p_a.VeLiveVideoEffectHandleCallback {
|
|
527
|
-
protected _instance: VeLiveVideoEffectHandleCallback;
|
|
528
|
-
constructor(_instance: VeLiveVideoEffectHandleCallback);
|
|
529
|
-
onEffectHandle(arg_0: object): void;
|
|
530
|
-
}
|
|
531
|
-
|
|
532
|
-
/** {en}
|
|
533
|
-
* @platform ios
|
|
534
|
-
* @list overview
|
|
535
|
-
* @detail callback
|
|
536
|
-
*/
|
|
537
|
-
export interface VeLiveScreenCaptureStatusObserver {
|
|
538
|
-
}
|
|
539
|
-
export declare class ios_VeLiveScreenCaptureStatusObserver extends $p_i.VeLiveScreenCaptureStatusObserver {
|
|
540
|
-
protected _instance: VeLiveScreenCaptureStatusObserver;
|
|
541
|
-
constructor(_instance: VeLiveScreenCaptureStatusObserver);
|
|
399
|
+
onFileRecordingError$message(errorCode: $p_i.int, msg: $p_i.NSString): void;
|
|
542
400
|
}
|