AppDefinedAudioSource
Class that represents an app defined video source that can be used by the MLWebRTC API. More...
Inherits from:
AppDefinedSource,
Track
Detailed Description
public class AppDefinedAudioSource : AppDefinedSource
Details*
Class that represents a source used by the MLWebRTC API.
Public Methods
override MLResult DestroyLocal
Destroys the Track and its associated media source.
public virtual override MLResult DestroyLocal()
Returns: MLResult.Result will be MLResult.Code.Ok if destroying all handles was successful. MLResult.Result will be MLResult.Code.WebRTCResultInstanceNotCreated if MLWebRTC instance was not created. MLResult.Result will be MLResult.Code.WebRTCResultMismatchingHandle if an incorrect handle was sent.
Reimplements: DestroyLocal
MLResult InitializeLocal
Initializes the given AppDefinedVideoSource object.
public static MLResult InitializeLocal(
AppDefinedAudioSource appDefinedAudioSource
)
Parameters
Type | Name | Description |
---|---|---|
AppDefinedAudioSource | appDefinedAudioSource | The AppDefinedVideoSource object to initialize. |
result | The MLResult object of the inner platform call(s). |
Returns: An AppDefinedVideoSource object with the given handle.
MLResult PushData
public MLResult PushData(
short [] audioBuffer,
in MLAudioOutput.BufferFormat audioBufferFormat
)
Parameters
Type | Name | Description |
---|---|---|
short [] | audioBuffer | |
in MLAudioOutput.BufferFormat | audioBufferFormat | Buffer format settings for input and output streams. |
Protected Methods
AppDefinedAudioSource
protected AppDefinedAudioSource(
string trackId
)
Parameters
Type | Name | Description |
---|---|---|
string | trackId |