@tencent-rtc/mcp 1.2.7 → 1.2.9

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.
Files changed (32) hide show
  1. package/package.json +1 -1
  2. package/resource/doc/native_live/android/V2TXLiveCode_api_android.md +312 -0
  3. package/resource/doc/native_live/android/V2TXLiveDef_api_android.md +430 -0
  4. package/resource/doc/native_live/android/V2TXLivePlayerObserver_api_android.md +679 -0
  5. package/resource/doc/native_live/android/V2TXLivePlayer_api_android.md +671 -0
  6. package/resource/doc/native_live/android/V2TXLivePremier_api_android.md +271 -0
  7. package/resource/doc/native_live/android/V2TXLivePusherObserver_api_android.md +849 -0
  8. package/resource/doc/native_live/android/V2TXLivePusher_api_android.md +1046 -0
  9. package/resource/doc/native_live/flutter/V2TXLiveCode_api_flutter.md +460 -0
  10. package/resource/doc/native_live/flutter/V2TXLiveDef_api_flutter.md +558 -0
  11. package/resource/doc/native_live/flutter/V2TXLivePlayerObserver_api_flutter.md +865 -0
  12. package/resource/doc/native_live/flutter/V2TXLivePlayer_api_flutter.md +657 -0
  13. package/resource/doc/native_live/flutter/V2TXLivePremier_api_flutter.md +437 -0
  14. package/resource/doc/native_live/flutter/V2TXLivePusherObserver_api_flutter.md +335 -0
  15. package/resource/doc/native_live/flutter/V2TXLivePusher_api_flutter.md +748 -0
  16. package/resource/doc/native_live/iOS/V2TXLiveCode_api_iOS.md +327 -0
  17. package/resource/doc/native_live/iOS/V2TXLiveDef_api_iOS.md +507 -0
  18. package/resource/doc/native_live/iOS/V2TXLivePlayerObserver_api_iOS.md +507 -0
  19. package/resource/doc/native_live/iOS/V2TXLivePlayer_api_iOS.md +659 -0
  20. package/resource/doc/native_live/iOS/V2TXLivePremier_api_iOS.md +284 -0
  21. package/resource/doc/native_live/iOS/V2TXLivePusherObserver_api_iOS.md +814 -0
  22. package/resource/doc/native_live/iOS/V2TXLivePusher_api_iOS.md +1000 -0
  23. package/tools/common/get-faq.js +1 -1
  24. package/tools/common/get-faq.js.map +1 -1
  25. package/tools/definitions/get_native_live_api_def.js +23 -0
  26. package/tools/definitions/get_native_live_api_def.js.map +1 -0
  27. package/tools/index.js +4 -0
  28. package/tools/index.js.map +1 -1
  29. package/tools/native_live/get-native-live-api.js +31 -0
  30. package/tools/native_live/get-native-live-api.js.map +1 -0
  31. package/utils/report-cls-client.js +1 -1
  32. package/utils/report-es-client.js +1 -1
@@ -0,0 +1,460 @@
1
+ # Tencent Cloud Live Streaming SDK V2TXLiveCode Error Code Documentation
2
+
3
+ ## Overview
4
+
5
+ `V2TXLiveCode` defines error and warning codes for the Tencent Cloud Live Streaming (CSS) SDK on Flutter. This file organizes error codes and provides detailed descriptions for features such as stream publishing, playback, stream mixing, and recording.
6
+
7
+ **File Path**: `v2_tx_live_code.dart`
8
+ **Platform Support**: Flutter
9
+ **Total Error Codes**: 20 core error and warning codes
10
+
11
+ ## 📋 Table of Contents
12
+
13
+ ### 1. [Error Code Categories](#错误码分类)
14
+ ### 2. [General Error Codes](#通用错误码)
15
+ ### 3. [Network-Related Warning Codes](#网络相关警告码)
16
+ ### 4. [Camera-Related Warning Codes](#摄像头相关警告码)
17
+ ### 5. [Microphone-Related Warning Codes](#麦克风相关警告码)
18
+ ### 6. [Screen Sharing Warning Codes](#屏幕分享相关警告码)
19
+ ### 7. [Codec Warning Codes](#编解码相关警告码)
20
+
21
+ ## 1. Error Code Categories
22
+
23
+ ### 🎯 Error Code Statistics
24
+
25
+ | Category | Number of Codes | Main Functionality |
26
+ |-------------------------------|----------------|-------------------------------------------|
27
+ | General Error Codes | 9 | API calls, parameter validation, permission checks |
28
+ | Network-Related Warning Codes | 2 | Network status, playback stuttering monitoring |
29
+ | Camera-Related Warning Codes | 3 | Camera device status monitoring |
30
+ | Microphone-Related Warning Codes | 3 | Microphone device status monitoring |
31
+ | Screen Sharing Warning Codes | 3 | Screen sharing feature status monitoring |
32
+ | Codec Warning Codes | 2 | Audio/video codec status monitoring |
33
+
34
+ ### 🔧 Technical Highlights
35
+
36
+ - **Hierarchical Categorization**: Error codes are grouped by functional module.
37
+ - **Detailed Descriptions**: Each error code includes clear explanations and usage scenarios.
38
+ - **Platform Adaptation**: Error codes are tailored for the Flutter platform.
39
+ - **Debug-Friendly**: Each code provides actionable explanations and troubleshooting tips.
40
+
41
+ ## Type Definition
42
+
43
+ ```dart
44
+ typedef V2TXLiveCode = int;
45
+ ```
46
+
47
+ `V2TXLiveCode` is an alias for the `int` type, representing all error and warning codes.
48
+
49
+ ## Success Code
50
+
51
+ | Code | Value | Description |
52
+ |-------------------|-------|----------------------|
53
+ | `V2TXLIVE_OK` | 0 | Operation succeeded |
54
+
55
+ ## 2. General Error Codes
56
+
57
+ ### ✅ V2TXLIVE_OK - Operation Succeeded
58
+
59
+ ```dart
60
+ static const int V2TXLIVE_OK = 0;
61
+ ```
62
+
63
+ **Meaning**: No error occurred; the operation completed successfully.
64
+
65
+ **Typical Scenarios**:
66
+ - API call returns successfully.
67
+ - Operation completes as expected.
68
+ - Status check passes.
69
+
70
+ ### ❌ V2TXLIVE_ERROR_FAILED - General Error
71
+
72
+ ```dart
73
+ static const int V2TXLIVE_ERROR_FAILED = -1;
74
+ ```
75
+
76
+ **Meaning**: Unclassified general error.
77
+
78
+ **Possible Causes**:
79
+ - Internal processing exception.
80
+
81
+ ### ❌ V2TXLIVE_ERROR_INVALID_PARAMETER - Invalid Parameter
82
+
83
+ ```dart
84
+ static const int V2TXLIVE_ERROR_INVALID_PARAMETER = -2;
85
+ ```
86
+
87
+ **Meaning**: Invalid parameters were provided in the API call.
88
+
89
+ **Common Causes**:
90
+ - Incorrect stream publishing URL format.
91
+ - Unsupported parameter values.
92
+
93
+ ### ❌ V2TXLIVE_ERROR_REFUSED - API Call Refused
94
+
95
+ ```dart
96
+ static const int V2TXLIVE_ERROR_REFUSED = -3;
97
+ ```
98
+
99
+ **Meaning**: The API call was refused.
100
+
101
+ **Possible Causes**:
102
+ - Incorrect call timing.
103
+
104
+ ### ❌ V2TXLIVE_ERROR_NOT_SUPPORTED - API Not Supported
105
+
106
+ ```dart
107
+ static const int V2TXLIVE_ERROR_NOT_SUPPORTED = -4;
108
+ ```
109
+
110
+ **Meaning**: The API is not supported.
111
+
112
+ **Common Causes**:
113
+ - Feature unsupported on the current platform.
114
+ - SDK version is outdated.
115
+ - Hardware does not support the feature.
116
+
117
+ ### ❌ V2TXLIVE_ERROR_INVALID_LICENSE - Invalid License
118
+
119
+ ```dart
120
+ static const int V2TXLIVE_ERROR_INVALID_LICENSE = -5;
121
+ ```
122
+
123
+ **Meaning**: License is invalid; operation failed.
124
+
125
+ **Possible Causes**:
126
+ - License file not set.
127
+ - License expired.
128
+ - License does not match the package name.
129
+
130
+ ### ❌ V2TXLIVE_ERROR_REQUEST_TIMEOUT - Request Timeout
131
+
132
+ ```dart
133
+ static const int V2TXLIVE_ERROR_REQUEST_TIMEOUT = -6;
134
+ ```
135
+
136
+ **Meaning**: Server request timed out.
137
+
138
+ **Common Causes**:
139
+ - Unstable network connection.
140
+ - Slow server response.
141
+
142
+ ### ❌ V2TXLIVE_ERROR_SERVER_PROCESS_FAILED - Server Processing Failed
143
+
144
+ ```dart
145
+ static const int V2TXLIVE_ERROR_SERVER_PROCESS_FAILED = -7;
146
+ ```
147
+
148
+ **Meaning**: The server failed to process the request.
149
+
150
+ **Possible Causes**:
151
+ - Internal server error.
152
+ - Malformed request.
153
+ - Insufficient server resources.
154
+
155
+ ### ❌ V2TXLIVE_ERROR_DISCONNECTED - Connection Disconnected
156
+
157
+ ```dart
158
+ static const int V2TXLIVE_ERROR_DISCONNECTED = -8;
159
+ ```
160
+
161
+ **Meaning**: Network connection lost.
162
+
163
+ **Common Causes**:
164
+ - Network disconnected during stream publishing.
165
+ - Network disconnected during playback.
166
+
167
+ ### ❌ V2TXLIVE_ERROR_NO_AVAILABLE_HEVC_DECODERS - No Available HEVC Decoders
168
+
169
+ ```dart
170
+ static const int V2TXLIVE_ERROR_NO_AVAILABLE_HEVC_DECODERS = -2304;
171
+ ```
172
+
173
+ **Meaning**: No available HEVC decoder found.
174
+
175
+ **Possible Causes**:
176
+ - Device does not support HEVC Hardware Decoding.
177
+ - HEVC decoder initialization failed.
178
+ - System version is too low.
179
+
180
+ ## 3. Network-Related Warning Codes
181
+
182
+ ### ⚠️ V2TXLIVE_WARNING_NETWORK_BUSY - Poor Network Condition
183
+
184
+ ```dart
185
+ static const int V2TXLIVE_WARNING_NETWORK_BUSY = 1101;
186
+ ```
187
+
188
+ **Meaning**: Network is congested; upstream bandwidth is too low and upload data is blocked.
189
+
190
+ **Possible Causes**:
191
+ - Insufficient upstream bandwidth.
192
+ - Severe network jitter.
193
+ - Data packet transmission blocked.
194
+
195
+ **Troubleshooting Tips**:
196
+ - Check network connection status.
197
+ - Lower video bitrate or resolution.
198
+ - Switch to a more stable network.
199
+
200
+ ### ⚠️ V2TXLIVE_WARNING_VIDEO_BLOCK - Video Playback Stuttering
201
+
202
+ ```dart
203
+ static const int V2TXLIVE_WARNING_VIDEO_BLOCK = 2105;
204
+ ```
205
+
206
+ **Meaning**: Video playback is stuttering.
207
+
208
+ **Possible Causes**:
209
+ - Insufficient downstream bandwidth.
210
+ - Poor video decoder performance.
211
+ - Device CPU overload.
212
+
213
+ **Troubleshooting Tips**:
214
+ - Check network quality.
215
+ - Lower video resolution or frame rate.
216
+ - Optimize player decoding performance.
217
+
218
+ ## 4. Camera-Related Warning Codes
219
+
220
+ ### ⚠️ V2TXLIVE_WARNING_CAMERA_START_FAILED - Camera Start Failed
221
+
222
+ ```dart
223
+ static const int V2TXLIVE_WARNING_CAMERA_START_FAILED = -1301;
224
+ ```
225
+
226
+ **Meaning**: Camera failed to start.
227
+
228
+ **Possible Causes**:
229
+ - Camera hardware malfunction.
230
+ - Camera driver error.
231
+ - Insufficient system resources.
232
+
233
+ **Troubleshooting Tips**:
234
+ - Check camera hardware status.
235
+ - Restart the app or device.
236
+ - Verify system permissions.
237
+
238
+ ### ⚠️ V2TXLIVE_WARNING_CAMERA_OCCUPIED - Camera Occupied
239
+
240
+ ```dart
241
+ static const int V2TXLIVE_WARNING_CAMERA_OCCUPIED = -1316;
242
+ ```
243
+
244
+ **Meaning**: Camera is currently in use; try switching to another camera.
245
+
246
+ **Possible Causes**:
247
+ - Another app is using the camera.
248
+ - System camera app is active.
249
+ - Video call app is occupying the camera.
250
+
251
+ **Troubleshooting Tips**:
252
+ - Close other apps using the camera.
253
+ - Switch to a different available camera.
254
+ - Wait for camera resources to be released.
255
+
256
+ ### ⚠️ V2TXLIVE_WARNING_CAMERA_NO_PERMISSION - Camera Permission Not Granted
257
+
258
+ ```dart
259
+ static const int V2TXLIVE_WARNING_CAMERA_NO_PERMISSION = -1314;
260
+ ```
261
+
262
+ **Meaning**: Camera access not authorized, typically on mobile devices due to denied permission.
263
+
264
+ **Possible Causes**:
265
+ - User denied camera permission.
266
+ - App did not request camera permission.
267
+ - Permission revoked by system or user.
268
+
269
+ **Troubleshooting Tips**:
270
+ - Check and request camera permission.
271
+ - Guide users to enable camera permissions.
272
+ - Provide instructions for requesting permissions.
273
+
274
+ ## 5. Microphone-Related Warning Codes
275
+
276
+ ### ⚠️ V2TXLIVE_WARNING_MICROPHONE_START_FAILED - Microphone Start Failed
277
+
278
+ ```dart
279
+ static const int V2TXLIVE_WARNING_MICROPHONE_START_FAILED = -1302;
280
+ ```
281
+
282
+ **Meaning**: Microphone failed to start.
283
+
284
+ **Possible Causes**:
285
+ - Microphone hardware malfunction.
286
+ - Audio driver error.
287
+ - System audio service failure.
288
+
289
+ **Troubleshooting Tips**:
290
+ - Check microphone hardware status.
291
+ - Restart audio service or device.
292
+ - Verify audio permissions.
293
+
294
+ ### ⚠️ V2TXLIVE_WARNING_MICROPHONE_OCCUPIED - Microphone Occupied
295
+
296
+ ```dart
297
+ static const int V2TXLIVE_WARNING_MICROPHONE_OCCUPIED = -1319;
298
+ ```
299
+
300
+ **Meaning**: Microphone is currently in use, for example, starting the microphone fails during an active phone call.
301
+
302
+ **Possible Causes**:
303
+ - Ongoing phone call.
304
+ - Another app is using the microphone.
305
+ - Voice assistant is active.
306
+
307
+ **Troubleshooting Tips**:
308
+ - End the current call or voice app.
309
+ - Wait for microphone resources to be released.
310
+ - Switch to another audio input device.
311
+
312
+ ### ⚠️ V2TXLIVE_WARNING_MICROPHONE_NO_PERMISSION - Microphone Permission Not Granted
313
+
314
+ ```dart
315
+ static const int V2TXLIVE_WARNING_MICROPHONE_NO_PERMISSION = -1317;
316
+ ```
317
+
318
+ **Meaning**: Microphone access not authorized, typically on mobile devices due to denied permission.
319
+
320
+ **Possible Causes**:
321
+ - User denied microphone permission.
322
+ - App did not request microphone permission.
323
+ - Permission revoked by system or user.
324
+
325
+ **Troubleshooting Tips**:
326
+ - Check and request microphone permission.
327
+ - Guide users to enable microphone permissions.
328
+ - Provide instructions for requesting permissions.
329
+
330
+ ## 6. Screen Sharing Warning Codes
331
+
332
+ ### ⚠️ V2TXLIVE_WARNING_SCREEN_CAPTURE_NOT_SUPPORTED - Screen Sharing Not Supported by System
333
+
334
+ ```dart
335
+ static const int V2TXLIVE_WARNING_SCREEN_CAPTURE_NOT_SUPPORTED = -1309;
336
+ ```
337
+
338
+ **Meaning**: The current system does not support screen sharing.
339
+
340
+ **Possible Causes**:
341
+ - Operating system version is too low.
342
+ - Device hardware does not support screen sharing.
343
+ - Platform restrictions (e.g., certain mobile devices).
344
+
345
+ **Troubleshooting Tips**:
346
+ - Check system version requirements.
347
+ - Confirm device supports screen recording.
348
+ - Consider alternative sharing methods.
349
+
350
+ ### ⚠️ V2TXLIVE_WARNING_SCREEN_CAPTURE_START_FAILED - Screen Recording Start Failed
351
+
352
+ ```dart
353
+ static const int V2TXLIVE_WARNING_SCREEN_CAPTURE_START_FAILED = -1308;
354
+ ```
355
+
356
+ **Meaning**: Failed to start screen recording; on mobile devices, this may be due to denied permission.
357
+
358
+ **Possible Causes**:
359
+ - User denied screen recording permission.
360
+ - System security policy restrictions.
361
+ - Another app is using screen recording.
362
+
363
+ **Troubleshooting Tips**:
364
+ - Check and request screen recording permission.
365
+ - Guide users to enable screen recording permissions.
366
+ - Close other screen recording apps.
367
+
368
+ ### ⚠️ V2TXLIVE_WARNING_SCREEN_CAPTURE_INTERRUPTED - Screen Recording Interrupted
369
+
370
+ ```dart
371
+ static const int V2TXLIVE_WARNING_SCREEN_CAPTURE_INTERRUPTED = -7001;
372
+ ```
373
+
374
+ **Meaning**: Screen recording was interrupted by the system.
375
+
376
+ **Possible Causes**:
377
+ - System dialog or notification appeared.
378
+ - User switched to another app.
379
+ - System resources are low and recording was forcibly stopped.
380
+
381
+ **Troubleshooting Tips**:
382
+ - Restart screen recording.
383
+ - Avoid other operations during recording.
384
+ - Check system resource usage.
385
+
386
+ ## 7. Codec Warning Codes
387
+
388
+ ### ⚠️ V2TXLIVE_WARNING_ENCODER_START_FAILED - Video Encoder Start Failed
389
+
390
+ ```dart
391
+ static const int V2TXLIVE_WARNING_ENCODER_START_FAILED = -1303;
392
+ ```
393
+
394
+ **Meaning**: Failed to start the video encoder.
395
+
396
+ **Possible Causes**:
397
+ - Insufficient encoder hardware resources.
398
+ - Incorrect encoder parameter settings.
399
+ - System codec error.
400
+
401
+ **Troubleshooting Tips**:
402
+ - Check encoder parameter settings.
403
+ - Lower video resolution or bitrate.
404
+ - Restart encoder or app.
405
+
406
+ ### ⚠️ V2TXLIVE_WARNING_DECODER_START_FAILED - Video Decoder Start Failed
407
+
408
+ ```dart
409
+ static const int V2TXLIVE_WARNING_DECODER_START_FAILED = -1304;
410
+ ```
411
+
412
+ **Meaning**: Failed to start the video decoder.
413
+
414
+ **Possible Causes**:
415
+ - Insufficient decoder hardware resources.
416
+ - Unsupported video format.
417
+ - System decoder error.
418
+
419
+ **Troubleshooting Tips**:
420
+ - Check video format compatibility.
421
+ - Lower video resolution or frame rate.
422
+ - Restart decoder or app.
423
+
424
+ ### ⚠️ V2TXLIVE_WARNING_CURRENT_ENCODE_TYPE_CHANGED - Encoder Type Changed
425
+
426
+ ```dart
427
+ static const int V2TXLIVE_WARNING_CURRENT_ENCODE_TYPE_CHANGED = 1104;
428
+ ```
429
+
430
+ **Meaning**: The encoder type has changed. You can get the current encoding format from the codec_type field in the extended information of the onWarning callback.
431
+
432
+ **Possible Causes**:
433
+ - Encoder automatically switches (e.g., hardware encoding to software encoding).
434
+ - Encoding parameters are dynamically adjusted.
435
+ - System resource changes trigger encoder switch.
436
+
437
+ **Troubleshooting Tips**:
438
+ - Listen for encoder change events and update encoding strategy promptly.
439
+ - Adjust video quality settings based on encoder type.
440
+ - Log encoder changes for performance analysis.
441
+
442
+ ### ⚠️ V2TXLIVE_WARNING_CURRENT_DECODE_TYPE_CHANGED - Decoder Type Changed
443
+
444
+ ```dart
445
+ static const int V2TXLIVE_WARNING_CURRENT_DECODE_TYPE_CHANGED = 2008;
446
+ ```
447
+
448
+ **Meaning**: The decoder type has changed. You can get the current decoding format from the codec_type field in the extended information of the onWarning callback.
449
+
450
+ **Possible Causes**:
451
+ - Decoder automatically switches (e.g., hardware decoding to software decoding).
452
+ - Video format changes trigger decoder switch.
453
+ - System resource changes trigger decoder switch.
454
+
455
+ **Troubleshooting Tips**:
456
+ - Listen for decoder change events and update decoding strategy promptly.
457
+ - Optimize playback performance based on decoder type.
458
+ - Log decoder changes for performance analysis.
459
+
460
+ **Note**: The Flutter platform supports extended information for this error code. You can get detailed codec type information via the callback parameters.