public class AgoraAudioVad
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private long |
cptr
Native pointer for the VAD instance.
|
| Constructor and Description |
|---|
AgoraAudioVad()
Constructs a VAD instance and loads native resources.
|
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Destroy the VAD module
|
int |
initialize(AgoraAudioVadConfig config)
Initialize the VAD module
|
private void |
nativeDestroy(long cptr)
Releases native VAD resources.
|
private long |
nativeInitialize(AgoraAudioVadConfig config)
Initializes the native VAD instance.
|
private VadProcessResult |
nativeProcessPcmFrame(byte[] frame)
Processes a PCM frame through the native VAD.
|
VadProcessResult |
processPcmFrame(byte[] frame)
Process the PCM frame
|
public AgoraAudioVad()
public int initialize(AgoraAudioVadConfig config)
config - the configuration of the VAD modulepublic VadProcessResult processPcmFrame(byte[] frame)
frame - the PCM framepublic void destroy()
private void nativeDestroy(long cptr)
cptr - Native pointerprivate long nativeInitialize(AgoraAudioVadConfig config)
config - VAD configurationprivate VadProcessResult nativeProcessPcmFrame(byte[] frame)
frame - PCM data