Package im.zego.zegoexpress.internal
Class ZegoAudioVADClientInternalImpl
- java.lang.Object
-
- im.zego.zegoexpress.ZegoAudioVADClient
-
- im.zego.zegoexpress.internal.ZegoAudioVADClientInternalImpl
-
public class ZegoAudioVADClientInternalImpl extends ZegoAudioVADClient
-
-
Constructor Summary
Constructors Constructor Description ZegoAudioVADClientInternalImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ZegoAudioVADClient
createAudioVADClient()
static void
destroyAudioVADClient(ZegoAudioVADClient client)
boolean
reset()
Reset audio vad client instance.ZegoAudioVADType
update(java.nio.ByteBuffer data, int dataLength, int sampleRate, int channels)
Check if an audio packet contains speech.
-
-
-
Method Detail
-
createAudioVADClient
public static ZegoAudioVADClient createAudioVADClient()
-
destroyAudioVADClient
public static void destroyAudioVADClient(ZegoAudioVADClient client)
-
update
public ZegoAudioVADType update(java.nio.ByteBuffer data, int dataLength, int sampleRate, int channels)
Description copied from class:ZegoAudioVADClient
Check if an audio packet contains speech. Available since: 2.21.0 Description: Check if an audio packet contains speech. When to call: It can be called after [createAudioVADClient]. Caution: ZegoAudioVADTypeSpeech will also be returned when the voice data is abnormal to ensure that the voice will not be missed.- Specified by:
update
in classZegoAudioVADClient
- Parameters:
data
- audio data.dataLength
- audio data length.sampleRate
- sampling rate.channels
- number of channels.- Returns:
- voice detection results.
-
reset
public boolean reset()
Description copied from class:ZegoAudioVADClient
Reset audio vad client instance. Available since: 2.21.0 Description: Reset audio vad client instance. When to call: It can be called after [createAudioVADClient].- Specified by:
reset
in classZegoAudioVADClient
- Returns:
- reset results.
-
-