5/29/2023 0 Comments Android studio sdk 23In /app/java/com.example./MainActivity, replace onCreate with the following code: In order to send video and audio streams to Agora, you need to ensure that the local user gives permission to access the camera and microphone on the local device.Ĭheck that the app has the correct permissions and initiate Agora Engine The local user joins and leaves a channel using the same Agora Engine instance. In this implementation, you initiate and destroy Agora Engine when the app opens and closes. In /app/java/com.example./MainActivity, add leaveChannel after joinChannel: When a user clicks Leave, use leaveChannel to exit the channel. When your app is running, the user can leave or join a channel using the buttons available in the UI. Leave the channel when user ends the call In /app/java/com.example./MainActivity, add the following code after setupLocalVideo: This method securely connects the local user to a channel using the authentication token. When the local user clicks the Join button, call joinChannel. In order to follow this procedure you must have: Join a channel: Call methods to create and join a channel apps that pass the same channel name join the same channel. In a test or production environment, your app retrieves tokens from a server in your security infrastructure.
0 Comments
Leave a Reply. |