Kotlin
Running the App
Now that your code is complete, you can run the app in the Android Studio emulator. This will create a simulated publisher video — since the emulator cannot access your webcam, the publisher video will display an animated graphic instead of your camera feed.
- Set
APP_ID,SESSION_ID, andTOKENinVonageVideoConfig.kt. - Build and run on a device (API 24+).
- Grant camera and microphone when prompted.
- After connecting to the session, the system screen capture dialog appears.
- Tap "Start now" to begin sharing your screen.
To add more publishers (which will display as subscribers in your emulator), either run the app a second time in a connected Android device or use the Vonage Video Playground to connect to the session in a supported web browser by following the steps below:
- Go to Vonage Video Playground (must be logged into your Account)
- Select the Join existing session tab
- Copy the session ID you used in your
MainActivity.ktfile and paste it in Session ID input field - Click Join Session
- On the next screen, click Connect, then click Publish Stream
- You can adjust the
Publisheroptions (not required), then click Continue to connect and begin publishing and subscribing
Simple Multiparty
Learn how to use the Vonage Android SDK for a multi-party call. The application publishes audio/video from a device and can connect to multiple subscribers.
Available on:
Steps
1
Introduction2
Getting Started3
Creating a new project4
Adding the Android SDK5
Setting up authentication6
Requesting permissions7
Connect publish and show yourself8
Multiparty subscribe to every remote stream9
Host SDK views in AndroidView10
Running the app11
Conclusion