Browse Source

add doc & changelog

matrixbirds 5 years ago
parent
commit
64cc879b89
4 changed files with 119 additions and 130 deletions
  1. 1
    0
      .gitignore
  2. 1
    0
      .npmignore
  3. 50
    0
      CHANGELOG
  4. 67
    130
      README.md

+ 1
- 0
.gitignore View File

@@ -72,3 +72,4 @@ xcuserdata*
72 72
 .vscode
73 73
 samples/**/package-lock.json
74 74
 *.iml
75
+android/bin

+ 1
- 0
.npmignore View File

@@ -37,3 +37,4 @@ proguard-rules.pro
37 37
 .settings
38 38
 .vscode
39 39
 package-lock.json
40
+android/bin

+ 50
- 0
CHANGELOG View File

@@ -0,0 +1,50 @@
1
+## THE CHANGELOG
2
+
3
+#### 2.3.3-alpha
4
+- support agora video sdk 2.3.3
5
+- release 2.3.3-alpha.3
6
+- release 2.3.3-alpha.4 (remove deprecated native api)
7
+- release 2.3.3-alpha.5 (refactor event react api & refactor native wrapper)
8
+
9
+
10
+#### 1.1.2
11
+- add onVideoMute
12
+- add onAudioMute
13
+
14
+#### 1.1.1
15
+
16
+- add createDataStream
17
+- add sendStreamMessage
18
+- add onStreamMessage
19
+
20
+#### 1.0.9
21
+
22
+- update to agora sdk version 2.0.2
23
+
24
+- add setCameraAutoFocusFaceModeEnabled
25
+
26
+- add setDefaultAudioRouteToSpeakerphone
27
+
28
+- add setCameraTorchOn
29
+
30
+- fix bug: Android speaker's volume indication
31
+
32
+#### 1.0.8
33
+
34
+ - update to agora sdk version 1.12
35
+
36
+ - init wouldn't start video preview. Should manually use startPreview.
37
+
38
+ - init options add new boolean parameter `swapWidthAndHeight` to support swap width and height.
39
+
40
+ - add configPublisher
41
+
42
+ - add setLocalRenderMode
43
+
44
+ - add setRemoteRenderMode
45
+
46
+ - add enableAudioVolumeIndication
47
+
48
+ - add onAudioVolumeIndication
49
+
50
+ - add zOrderMediaOverlay for android platform, support media overlay

+ 67
- 130
README.md View File

@@ -129,142 +129,79 @@ export interface LiveTranscoding {
129 129
 #### Events
130 130
 
131 131
 ```javascript
132
-RtcEngine.eventEmitter({
133
-  onFirstRemoteVideoDecoded: data => {},
134
-  onJoinChannelSuccess: data => {},
135
-  onUserOffline: data => {},
136
-  onUserJoined: data => {},
137
-  onError: data => {},
138
-  onWarning: data => {},
139
-  onLeaveChannel: data => {},
140
-  onAudioVolumeIndication: data => {},
141
-  onStreamMessage: ({uid, streamId, data}) => {},
142
-  onStreamMessageError: ({uid, streamId, error, missed, cached}) => {},
143
-})
132
+RtcEngine.on('eventName', (data) => {
133
+    console.log(data);
134
+});
144 135
 ```
145 136
 
146
-| Name                      | Description  |
147
-| ------------------------- | ------------ |
148
-| onWarning                 | warning |
149
-| onError                   | error |
150
-| onFirstRemoteVideoDecoded | when received first frame send from remote decoded stream |
151
-| onJoinChannelSuccess      | join channel success |
152
-| onReJoinChannelSuccess      | rejoin channel success |
153
-| onLeaveChannel            | quit channel |
154
-| onClientRoleChanged | when changed client role |
155
-| onUserJoined              | when user joined channel |
156
-| onUserOffline             | when user left channel |
157
-| onConnectionStateChanged | when connection state changed |
158
-| onConnectionInterrupted | when connection interrupted |
159
-| onConnectionLost | when connection lost |
160
-| onConnectionBanned | when connection banned |
161
-| onApiCallExecuted | capture api call executed |
162
-| onTokenPrivilegeWillExpire | when token will expire |
163
-| onRequestToken | when token expired |
164
-| onMicrophoneEnabled | when microphone enabled |
165
-| onAudioVolumeIndication | notice audio volume |
166
-| onActiveSpeaker | reports which user is the loudest speaker |
167
-| onFirstLocalAudioFrame | when the first local audio frame is sent |
168
-| onFirstRemoteAudioFrame | when the first remote audio frame is sent |
169
-| onVideoStopped | when video stopped |
170
-| onFirstLocalVideoFrame | when first local video frame is sent |
171
-| onFirstRemoteVideoDecoded | when first remote video is decoded |
172
-| onFirstRemoteVideoFrame | when first remote video frame is rendered |
173
-| onUserMuteAudio | when a remote user's audio stream is muted/unmuted |
174
-| onUserMuteVideo | when a remote user's video stream is muted/unmuted |
175
-| onUserEnableVideo | when a remote user enables/disables the video module |
176
-| onUserEnableLocalVideo | when a remote user enables/disables the local video capture function |
177
-| onVideoSizeChanged | when the video size or rotation information of a specified remote user changes |
178
-| onRemoteVideoStateChanged | when the remote video stream state changes |
179
-| onLocalPublishFallbackToAudioOnly | when the published media stream falls back to an audio-only stream due to poor network conditions or switches back to video stream after the network conditions improve |
180
-| onRemoteSubscribeFallbackToAudioOnly | when the subscribed media stream falls back to audio-only stream due to poor network conditions or switches back to video stream after the network conditions improve |
181
-| onAudioRouteChanged | when the local audio pkayout route changes |
182
-| onCameraReady | when the camera is turned on and ready to capture video |
183
-| onCameraFocusAreaChanged | when the camera focus area is changed |
184
-| onCameraExposureAreaChanged | The camera exposure area has changed |
185
-| onAudioQuality | Reports the statistics of the audio stream from each remote user/host |
186
-| onRtcStats | Reports the statistics of the RtcEngine once every two seconds |
187
-| onLastmileQuality | Reports the last mile network quality of the local user once every two seconds before the user joins the channel. Last mile refers to the connection between the local device and Agora's edge server. After the application calls the enableLastmileTest method, this callback reports once every two seconds the uplink and downlink last mile network conditions of the local user before the user joins the channel. |
188
-| onNetworkQuality | Reports the last mile network quality of each user in the channel once every two seconds. Last mile refers to the connection between the local device and Agora's edge server. This callback reports once every two seconds the uplink last mile network conditions of each user in the channel. If a channel includes multiple users, then this callback will be triggered as many times. |
189
-| onLocalVideoStats | Reports the statistics of the uploading local video streams. This callback is triggered once every two seconds for each individual user/host. If there are multiple users/hosts in the channel, this callback is triggered multiple times every 2 seconds. |
190
-| onRemoteVideoStats | Reports the statistics of the video stream from each remote user/host. The SDK triggers this callback once every two seconds for each remote user/host. If a channel includes multiple remote users, the SDK triggers this callback as many times. This callback reports statistics more closely linked to the real-user experience of the video transmission quality than the statistics that the onRemoteVideoTransportStats callback reports |
191
-| onRemoteAudioStats | Reports the statistics of the audio stream from each remote user/host |
192
-| onLocalVideoStat | Reports the statistics of the uploading local video streams |
193
-| onRemoteVideoStat | Reports the statistics of the video stream from each remote user/host.|
194
-| onRemoteAudioTransportStats | Reports the transport-layer statistics of each remote audio stream.This callback reports the transport-layer statistics, such as the packet loss rate and time delay, once every two seconds after the local user receives an audio packet from a remote user. |
195
-| onRemoteVideoTransportStats | Reports the transport-layer statistics of each remote video stream.This callback reports the transport-layer statistics, such as the packet loss rate and time delay, once every two seconds after the local user receives the video packet from a remote user. |
196
-| onAudioMixingFinished | when the audio mixing file playback finishes. |
197
-| onAudioEffectFinished | when the audio effect file playback finishes. |
198
-| onStreamPublished | when a CDN live stream is published. |
199
-| onStreamUnpublished | when CDN live streaming stops. |
200
-| onTranscodingUpdated | when the publisher's transcoding settings are updated. |
201
-| onStreamInjectedStatus | Reports the status of the injected online media stream. |
202
-| onStreamMessage | recevied stream message peer endpoint |
203
-| onStreamMessageError | recevied error message from peer endpoint stream message |
204
-| onMediaEngineLoadSuccess | when the media engine is loaded. |
205
-| onMediaEngineStartCallSuccess | when the media engine starts. |
206
-
207
-##### AgoraView 组件
137
+| Name                      | Description  | Platform |
138
+| ------------------------- | ------------ | ------- |
139
+| warning                 | warning | all |
140
+| error                   | error | all |
141
+| apiCallExecute | capture agora native api call executed| all |
142
+| joinChannelSuccess      | join channel success | all |
143
+| reJoinChannelSuccess      | rejoin channel success | all |
144
+| leaveChannel            | quit channel | all |
145
+| clientRoleChanged | when changed client role | all |
146
+| userJoined              | when user joined channel | all |
147
+| userOffline             | when user left channel | all |
148
+| connectionStateChanged | when connection state changed | all |
149
+| connectionLost | when connection lost | all |
150
+| tokenPrivilegeWillExpire | when token will expire | all |
151
+| requestToken | when token expired | all |
152
+| microphoneEnabled | when microphone enabled | all |
153
+| audioVolumeIndication | notice audio volume | all |
154
+| activeSpeaker | reports which user is the loudest speaker | all |
155
+| firstLocalAudioFrame | when the first local audio frame is sent | all |
156
+| firstRemoteAudioFrame | when the first remote audio frame is sent | all |
157
+| videoStopped | when video stopped | all |
158
+| firstLocalVideoFrame | when first local video frame is sent | all |
159
+| firstRemoteVideoDecoded | when first remote video is decoded | all |
160
+| firstRemoteVideoFrame | when first remote video frame is rendered | all |
161
+| userMuteAudio | when a remote user's audio stream is muted/unmuted | all |
162
+| userMuteVideo | when a remote user's video stream is muted/unmuted | all |
163
+| userEnableVideo | when a remote user enables/disables the video module | all |
164
+| userEnableLocalVideo | when a remote user enables/disables the local video capture function | all |
165
+| videoSizeChanged | when the video size or rotation information of a specified remote user changes | all|
166
+| remoteVideoStateChanged | when the remote video stream state changes | all |
167
+| localPublishFallbackToAudioOnly | Occurs when the published video stream falls back to an audio-only stream due to unreliable network conditions or switches back to the video when the network conditions improve. | all |
168
+| remoteSubscribeFallbackToAudioOnly | Occurs when the remote video stream falls back to an audio-only stream due to unreliable network conditions or switches back to the video after the network conditions improve. | all |
169
+| audioRouteChanged | when the local audio pkayout route changes | all |
170
+| cameraReady | when the camera is turned on and ready to capture video | all |
171
+| cameraFocusAreaChanged | when the camera focus area is changed | all |
172
+| cameraExposureAreaChanged | The camera exposure area has changed | all |
173
+| remoteAudioStats | Reports the statistics of the audio stream from each remote user/host. | all |
174
+| rtcStats | Reports the statistics of the RtcEngine once every two seconds | all |
175
+| lastmileQuality | Reports the last mile network quality of the local user once every two seconds before the user joins the channel. Last mile refers to the connection between the local device and Agora's edge server. After the application calls the enableLastmileTest method, this callback reports once every two seconds the uplink and downlink last mile network conditions of the local user before the user joins the channel. | all |
176
+| networkQuality | Reports the last mile network quality of each user in the channel once every two seconds. Last mile refers to the connection between the local device and Agora's edge server. This callback reports once every two seconds the uplink last mile network conditions of each user in the channel. If a channel includes multiple users, then this callback will be triggered as many times. | all |
177
+| localVideoStats | Reports the statistics of the uploading local video streams. This callback is triggered once every two seconds for each individual user/host. If there are multiple users/hosts in the channel, this callback is triggered multiple times every 2 seconds. | all |
178
+| remoteVideoStats | Reports the statistics of the video stream from each remote user/host. The SDK triggers this callback once every two seconds for each remote user/host. If a channel includes multiple remote users, the SDK triggers this callback as many times. This callback reports statistics more closely linked to the real-user experience of the video transmission quality than the statistics that the onRemoteVideoTransportStats callback reports | all |
179
+| audioTransportStatsOfUid | Reports the transport-layer statistics of each remote audio stream. | all |
180
+| videoTransportStatsOfUid | Reports the transport-layer statistics of each remote video stream. | all |
181
+| localAudioMixingFinish | Occurs when the audio mixing file playback finishes. | all |
182
+| remoteAudioMixingStart | Occurs when a remote user starts audio mixing. | ios |
183
+| remoteAudioMixingFinish | Occurs when a remote user finishes audio mixing. | ios |
184
+| audioEffectFinish | Occurs when the audio effect file playback finishes. | all |
185
+| streamPublished | Occurs when a CDN live stream is published. | all |
186
+| streamUnpublish | Occurs when CDN live streaming stops. This callback notifies the host that the CDN live stream is unpublished. | all |
187
+| transcodingUpdate | Occurs when the publisher's transcoding settings are updated. | all |
188
+| streamInjectedStatus | Reports the status of the injected online media stream. | all |
189
+| receiveStreamMessage | Occurs when the local user receives a remote data stream within five seconds. | all |
190
+| occurStreamMessageError | Occurs when the local user fails to receive a remote data stream. | all |
191
+| mediaEngineLoaded | Occurs when the media engine is loaded. | all |
192
+| mediaEngineStartCall | Occurs when the media engine starts. | all |
193
+
194
+##### AgoraView Component
208 195
 
209 196
 | Name           | Description          |
210 197
 | -------------- | -------------------- |
211
-| showLocalVideo | 是否显示本地视频(bool)       |
212
-| remoteUid      | 显示远程视频(number 传入uid) |
213
-| zOrderMediaOverlay (Android only)      | 多视频界面覆盖 设置为true优先在上层(bool) |
198
+| showLocalVideo | boolean: (true | false) enable/disable video view  | 
199
+| remoteUid      | uid for remote |
200
+| zOrderMediaOverlay (Android only)      | enable zorder to media overlay |
214 201
 
215 202
 
216
-## 运行示例
203
+## samples
217 204
 
218
-- 更新示例 React-Native为0.58
205
+- need react-native 0.58.+
219 206
 
220
-[Samples](./samples/README.md)
221
-
222
-
223
-## 更新信息
224
-#### 2.3.3-alpha
225
-- support agora video sdk 2.3.3
226
-- release 2.3.3-alpha.3
227
-- release 2.3.3-alpha.4 (remove deprecated native api)
228
-
229
-
230
-#### 1.1.2
231
-- 增加onVideoMute
232
-- 新增onAudioMute回调
233
-
234
-#### 1.1.1
235
-
236
-- 新增方法 创建数据流通道 createDataStream
237
-- 新增方法 发送数据流 sendStreamMessage
238
-- 新增监听数据流事件 onStreamMessage
239
-
240
-#### 1.0.9
241
-
242
-- 更新Agora SDK 为 2.0.2
243
-
244
-- 新增方法 是否开启人脸对焦功能 setCameraAutoFocusFaceModeEnabled
245
-
246
-- 新增方法 修改默认的语音路由 setDefaultAudioRouteToSpeakerphone
247
-
248
-- 新增方法 是否打开闪光灯 setCameraTorchOn
249
-
250
-- 修复 Android 说话者音量提示bug
251
-
252
-#### 1.0.8
253
-
254
- - 更新 Agora SDK 为 1.12
255
-
256
- - init 不再默认开启视频预览 根据自己需求和时机调用startPreview
257
-
258
- - init options 新增参数  是否交换宽和高 swapWidthAndHeight 默认false
259
-
260
- - 新增方法 配置旁路直播推流方法 configPublisher
261
-
262
- - 新增方法 设置本地视频显示模式 setLocalRenderMode
263
-
264
- - 新增方法 设置远端视频显示模式 setRemoteRenderMode
265
-
266
- - 新增方法 启用说话者音量提示 enableAudioVolumeIndication
267
-
268
- - 新增音量提示回调 onAudioVolumeIndication
269
-
270
- - Android AgoraView 新增zOrderMediaOverlay属性 解决多视频界面覆盖 设置为true优先在上层
207
+[Samples](./samples/README.md)