Class AudioSynchronizer
An audio pipe for synchronizing playout with other streams.
Inheritance
System.Object
MediaPipe<IAudioOutput, IAudioOutputCollection, IAudioInput, IAudioInputCollection, AudioPipe, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>
AudioSynchronizer
Implements
Inherited Members
Namespace: FM.LiveSwitch
Assembly: FM.LiveSwitch.dll
Syntax
public class AudioSynchronizer : AudioPipe, IAudioInput, IMediaInput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IInput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IAudioOutput, IMediaOutput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IOutput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IAudioElement, IMediaElement, IElement, ISynchronizer
Constructors
AudioSynchronizer(AudioFormat)
Initializes a new instance of the AudioSynchronizer class.
Declaration
public AudioSynchronizer(AudioFormat format)
Parameters
Type | Name | Description |
---|---|---|
AudioFormat | format | The format. |
Properties
Active
Gets whether synchronization is active.
Declaration
public bool Active { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
HeadSystemTimestamp
Gets the system timestamp from the head of the queue.
Declaration
public long HeadSystemTimestamp { get; }
Property Value
Type | Description |
---|---|
System.Int64 |
Label
Gets a label that identifies this class.
Declaration
public override string Label { get; }
Property Value
Type | Description |
---|---|
System.String |
Overrides
FM.LiveSwitch.MediaPipe<FM.LiveSwitch.IAudioOutput, FM.LiveSwitch.IAudioOutputCollection, FM.LiveSwitch.IAudioInput, FM.LiveSwitch.IAudioInputCollection, FM.LiveSwitch.AudioPipe, FM.LiveSwitch.AudioFrame, FM.LiveSwitch.AudioBuffer, FM.LiveSwitch.AudioBufferCollection, FM.LiveSwitch.AudioFormat>.Label
Master
Gets whether this is the master.
Declaration
public bool Master { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
MasterSystemTimestamp
Gets or sets the master system timestamp.
Declaration
public long MasterSystemTimestamp { get; set; }
Property Value
Type | Description |
---|---|
System.Int64 |
MaxData
Gets or sets the maximum amount of data to allow in the queue, in bytes.
Declaration
public long MaxData { get; set; }
Property Value
Type | Description |
---|---|
System.Int64 |
MaxDelay
Gets or sets the maximum amount of delay to allow in the queue, in milliseconds.
Declaration
public int MaxDelay { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
QueueCount
Gets the number of pending frames.
Declaration
public int QueueCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Slaves
Gets the slaves.
Declaration
public ISynchronizer[] Slaves { get; }
Property Value
Type | Description |
---|---|
ISynchronizer[] |
Methods
Activate(Boolean, ISynchronizer[])
Activates synchronizing.
Declaration
public void Activate(bool master, ISynchronizer[] slaves)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | master | Whether this is a master. |
ISynchronizer[] | slaves | The slaves, if this is a master. |
DoDestroy()
Destroys this instance.
Declaration
protected override void DoDestroy()
Overrides
FM.LiveSwitch.MediaPipe<FM.LiveSwitch.IAudioOutput, FM.LiveSwitch.IAudioOutputCollection, FM.LiveSwitch.IAudioInput, FM.LiveSwitch.IAudioInputCollection, FM.LiveSwitch.AudioPipe, FM.LiveSwitch.AudioFrame, FM.LiveSwitch.AudioBuffer, FM.LiveSwitch.AudioBufferCollection, FM.LiveSwitch.AudioFormat>.DoDestroy()
DoProcessFrame(AudioFrame, AudioBuffer)
Processes a frame.
Declaration
protected override void DoProcessFrame(AudioFrame frame, AudioBuffer inputBuffer)
Parameters
Type | Name | Description |
---|---|---|
AudioFrame | frame | The frame. |
AudioBuffer | inputBuffer | The input buffer. |
Overrides
FM.LiveSwitch.MediaPipe<FM.LiveSwitch.IAudioOutput, FM.LiveSwitch.IAudioOutputCollection, FM.LiveSwitch.IAudioInput, FM.LiveSwitch.IAudioInputCollection, FM.LiveSwitch.AudioPipe, FM.LiveSwitch.AudioFrame, FM.LiveSwitch.AudioBuffer, FM.LiveSwitch.AudioBufferCollection, FM.LiveSwitch.AudioFormat>.DoProcessFrame(FM.LiveSwitch.AudioFrame, FM.LiveSwitch.AudioBuffer)