Our new developer documentation is now available. Please check it out!
OdinMedia
public class OdinMedia : MonoBehaviour, IMedia
Wrapper class of Odin for Unity (require AudioSource)
This convenient class provides predefined helper functions to cover for a default usecases where the voice chat needs to work with AudioSource, AudioClip, AudioMixer, ...
Default Unity GameObject altering functions:- OdinMediaAdd OdinMuteAudioComponent to the current GameObject
Properties
Name | Description |
---|---|
Playback | Actual Unity audio output component |
OutSampleRate | |
OutChannels | Gets the current speaker mode. Default is 2 channel stereo. |
Parent | |
Id | |
MediaDecoder | Media reference |
AudioMixerGroup | Unity mixer |
SpatialBlend | Property of AudioSource |
RolloffMode | Property of AudioSource |
MinDistance | Property of AudioSource |
MaxDistance | Property of AudioSource |
Activity | Media activity state flag |
OnActiveStateChanged | Trigger on Activity changed |
AutoDestroyAudioSource | Flag for destroy Playback linked AudioSource |
AutoDestroyMediaStream | Flag for dispose of MediaDecoder |
Public Methods
Name | Description |
---|---|
GetPipeline | |
AddApm | |
AddVad | |
AddVolumeBoost | |
AddMute | |
AddEffect | |
SetDecoder | |
ReadOdinAudioData | |
GetFrameBufferSize | |
CheckResetFrameBuffer | |
SetAudioSourcePtich | |
SetAudioClipData |