Interface ClientAudioChannel
- All Known Subinterfaces:
ClientEntityAudioChannel, ClientLocationalAudioChannel, ClientStaticAudioChannel
public interface ClientAudioChannel
-
Method Summary
Modifier and TypeMethodDescriptiongetId()voidplay(short[] rawAudio) Plays this audio data on this audio channel.voidsetCategory(String category) Make sure you registered your category before using it.
-
Method Details
-
getId
UUID getId()- Returns:
- the ID of the channel
-
play
void play(short[] rawAudio) Plays this audio data on this audio channel.
Providing audio that's not 960 samples will be ignored. An empty array marks the end of a sound (e.g. flushes recordings).- Parameters:
rawAudio- the raw 16 bit PCM audio frame
-
getCategory
- Returns:
- the category ID of the audio channel
-
setCategory
Make sure you registered your category before using it. SeeVoicechatServerApi.registerVolumeCategory(VolumeCategory).- Parameters:
category- the category of the audio channel
-