Active Speaker Indication - Android
Active Speaker indication feature in VideoSDK let you know, which participant in a meeting is active speaker. This feature can be particularly useful in larger meetings or webinars, where there may be many participants and it can be difficult to tell who is speaking.
Whenever any participant speaks in meeting, onSpeakerChanged
event will trigger with the participant id of the active speaker.
For example, the meeting is running with Alice and Bob. Whenever any of them speaks, onSpeakerChanged
event will trigger and return the speaker participantId
.
Event
- Kotlin
- Java
private val meetingEventListener: MeetingEventListener = object : MeetingEventListener() {
override fun onSpeakerChanged(participantId: String?) {
Toast.makeText(this@MainActivity, "Active Speaker participantId" + participantId, Toast.LENGTH_SHORT).show();
super.onSpeakerChanged(participantId)
}
};
private final MeetingEventListener meetingEventListener = new MeetingEventListener() {
@Override
public void onSpeakerChanged(String participantId) {
Toast.makeText(MainActivity.this, "Active Speaker participantId" + participantId, Toast.LENGTH_SHORT).show();
super.onSpeakerChanged(participantId);
}
};
API Reference
The API references for all the methods and events utilised in this guide are provided below.
Got a Question? Ask us on discord