AliVCSDK 6.17.0
阿里云音视频SDK,为视频开发者提供一站式接入服务
 
Loading...
Searching...
No Matches
com.alivc.live.pusher.AlivcLivePushAudioFrameListener Class Referenceabstract

Audio frame data listener. More...

Public Member Functions

boolean onCapturedAudioFrame (AlivcLivePushAudioFrame audioFrame)
 
boolean onProcessCapturedAudioFrame (AlivcLivePushAudioFrame audioFrame)
 
boolean onPublishAudioFrame (AlivcLivePushAudioFrame audioFrame)
 
boolean onPlaybackAudioFrame (AlivcLivePushAudioFrame audioFrame)
 
boolean onMixedAllAudioFrame (AlivcLivePushAudioFrame audioFrame)
 

Detailed Description

Audio frame data listener.

Author
keria
Date
2024/5/17
Attention
This API is only supported in the interactive mode currently
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 15 of file AlivcLivePushAudioFrameListener.java.

Member Function Documentation

◆ onCapturedAudioFrame()

boolean com.alivc.live.pusher.AlivcLivePushAudioFrameListener.onCapturedAudioFrame ( AlivcLivePushAudioFrame  audioFrame)

Audio capture frame data callback

Parameters
audioFrameAudio frame data
Returns
true->success, false->failed
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
enableAudioFrameObserver interface parameters: (true, AlivcLiveAudioSource.CAPTURED, AlivcLiveAudioFrameObserverConfig)
Corresponding to the audio source configuration: AlivcLiveAudioSource#CAPTURED
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 27 of file AlivcLivePushAudioFrameListener.java.

◆ onMixedAllAudioFrame()

boolean com.alivc.live.pusher.AlivcLivePushAudioFrameListener.onMixedAllAudioFrame ( AlivcLivePushAudioFrame  audioFrame)

Push streaming and playback audio frame data after mixing callback

Parameters
audioFrameAudio frame data
Returns
true->success, false->failed
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
enableAudioFrameObserver interface parameters: (true, AlivcLiveAudioSource.MIXED_ALL, AlivcLiveAudioFrameObserverConfig)
Corresponding to the audio source configuration: AlivcLiveAudioSource#MIXED_ALL
Control the com.alivc.live.annotations.AlivcLiveAudioFrameObserverUserDefinedInfoBitMask mode through AlivcLiveAudioFrameObserverConfig#userDefinedInfo
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 84 of file AlivcLivePushAudioFrameListener.java.

◆ onPlaybackAudioFrame()

boolean com.alivc.live.pusher.AlivcLivePushAudioFrameListener.onPlaybackAudioFrame ( AlivcLivePushAudioFrame  audioFrame)

Audio playback frame data callback

Parameters
audioFrameAudio frame data
Returns
true->success, false->failed
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
enableAudioFrameObserver interface parameters: (true, AlivcLiveAudioSource.PLAYBACK, AlivcLiveAudioFrameObserverConfig)
Corresponding to the audio source configuration: AlivcLiveAudioSource#PLAYBACK
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 69 of file AlivcLivePushAudioFrameListener.java.

◆ onProcessCapturedAudioFrame()

boolean com.alivc.live.pusher.AlivcLivePushAudioFrameListener.onProcessCapturedAudioFrame ( AlivcLivePushAudioFrame  audioFrame)

Raw data callback after audio 3A

Parameters
audioFrameAudio frame data
Returns
true->success, false->failed
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
enableAudioFrameObserver interface parameters: (true, AlivcLiveAudioSource.PROCESS_CAPTURED, AlivcLiveAudioFrameObserverConfig)
Corresponding to the audio source configuration: AlivcLiveAudioSource#PROCESS_CAPTURED
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 41 of file AlivcLivePushAudioFrameListener.java.

◆ onPublishAudioFrame()

boolean com.alivc.live.pusher.AlivcLivePushAudioFrameListener.onPublishAudioFrame ( AlivcLivePushAudioFrame  audioFrame)

Audio streaming frame data callback

Parameters
audioFrameAudio frame data
Returns
true->success, false->failed
Note
It is disabled by default, and needs to be enabled by calling AlivcLivePusher#enableAudioFrameObserver(boolean, AlivcLiveAudioSource, AlivcLiveAudioFrameObserverConfig)
enableAudioFrameObserver interface parameters: (true, AlivcLiveAudioSource.PUB, AlivcLiveAudioFrameObserverConfig)
Corresponding to the audio source configuration: AlivcLiveAudioSource#PUB
Attention
Please do not perform any time-consuming operations in this callback function, otherwise it may cause abnormal sound

Definition at line 55 of file AlivcLivePushAudioFrameListener.java.