Class NullAudioSource
An audio source that raises nothing.
Inheritance
Implements
Inherited Members
Namespace: FM.LiveSwitch
Assembly: FM.LiveSwitch.dll
Syntax
public class NullAudioSource : AudioSource, IAudioOutput, IMediaOutput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IOutput<IAudioOutput, IAudioInput, AudioFrame, AudioBuffer, AudioBufferCollection, AudioFormat>, IAudioElement, IMediaElement, IElement
Constructors
NullAudioSource(AudioFormat)
Initializes a new NullAudioSource.
Declaration
public NullAudioSource(AudioFormat outputFormat)
Parameters
Type | Name | Description |
---|---|---|
AudioFormat | outputFormat | The output format. |
Properties
CanChangeBitrate
Gets whether this source can change the output bitrate.
Declaration
protected override bool CanChangeBitrate { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Overrides
CanPauseBitrate
Gets whether this source can pause the output bitrate.
Declaration
protected override bool CanPauseBitrate { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Overrides
InputRtpStreamId
Gets or sets the input RTP stream identifier.
Declaration
public virtual string InputRtpStreamId { get; set; }
Property Value
Type | Description |
---|---|
System.String |
InputSynchronizationSource
Gets or sets the input synchronization source.
Declaration
public virtual long InputSynchronizationSource { get; set; }
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
Methods
DoDestroy()
Destroys this instance.
Declaration
protected override void DoDestroy()
Overrides
DoStart()
Starts the source.
Declaration
protected override Future<object> DoStart()
Returns
Type | Description |
---|---|
Future<System.Object> |
Overrides
DoStop()
Stops the source.
Declaration
protected override Future<object> DoStop()
Returns
Type | Description |
---|---|
Future<System.Object> |
Overrides
GenerateAndProcessPcmFrame()
Generates and processes a 20ms PCM frame.
Declaration
public virtual void GenerateAndProcessPcmFrame()
GenerateAndProcessPcmFrame(Int32)
Generates and processes a PCM frame.
Declaration
public virtual void GenerateAndProcessPcmFrame(int duration)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | duration | The duration. |
ProcessControlFrameResponse(MediaControlFrame)
Processes a control frame response by raising it.
Declaration
public virtual void ProcessControlFrameResponse(MediaControlFrame controlFrameResponse)
Parameters
Type | Name | Description |
---|---|---|
MediaControlFrame | controlFrameResponse | The control frame response. |
ProcessControlFrameResponses(MediaControlFrame[])
Processes control frame responses by raising them.
Declaration
public virtual void ProcessControlFrameResponses(MediaControlFrame[] controlFrameResponses)
Parameters
Type | Name | Description |
---|---|---|
MediaControlFrame[] | controlFrameResponses | The control frame responses. |
ProcessFrame(AudioFrame)
Processes a frame by raising it.
Declaration
public virtual void ProcessFrame(AudioFrame frame)
Parameters
Type | Name | Description |
---|---|---|
AudioFrame | frame | The frame. |
UpdateCanChangeBitrate(Boolean)
Sets whether this source can change the output bitrate.
Declaration
public void UpdateCanChangeBitrate(bool canChangeBitrate)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | canChangeBitrate | Whether this source can change the output bitrate. |
UpdateCanPauseBitrate(Boolean)
Sets whether this source can pause the output bitrate.
Declaration
public void UpdateCanPauseBitrate(bool canPauseBitrate)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | canPauseBitrate | Whether this source can pause the output bitrate. |
UpdateMaxOutputBitrate(Int32)
Sets the maximum allowed output bitrate, in kbps. A value of -1 indicates unset (no maximum).
Declaration
public virtual void UpdateMaxOutputBitrate(int maxOutputBitrate)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | maxOutputBitrate | The maximum allowed output bitrate, in kbps. |
UpdateMaxOutputEncoding(EncodingInfo)
Sets the maximum allowed output encoding. A value of null indicates unset (no maximum).
Declaration
public virtual void UpdateMaxOutputEncoding(EncodingInfo maxOutputEncoding)
Parameters
Type | Name | Description |
---|---|---|
EncodingInfo | maxOutputEncoding | The maximum allowed output encoding. |
UpdateMinOutputBitrate(Int32)
Sets the minimum allowed output bitrate, in kbps. A value of -1 indicates unset (no minimum).
Declaration
public virtual void UpdateMinOutputBitrate(int minOutputBitrate)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | minOutputBitrate | The minimum allowed output bitrate, in kbps. |
UpdateMinOutputEncoding(EncodingInfo)
Sets the minimum allowed output encoding. A value of null indicates unset (no minimum).
Declaration
public virtual void UpdateMinOutputEncoding(EncodingInfo minOutputEncoding)
Parameters
Type | Name | Description |
---|---|---|
EncodingInfo | minOutputEncoding | The minimum allowed output encoding. |
UpdateOutputSynchronizable(Boolean)
Sets whether output is synchronizable.
Declaration
public virtual void UpdateOutputSynchronizable(bool outputSynchronizable)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | outputSynchronizable | Whether output is synchronizable. |
UpdateSystemDelay(Int64)
Sets the system delay in ticks.
Declaration
public virtual void UpdateSystemDelay(long systemDelay)
Parameters
Type | Name | Description |
---|---|---|
System.Int64 | systemDelay | The system delay. |
UpdateTargetOutputBitrate(Int32)
Sets the target output bitrate, in kbps. A value of -1 indicates unset (no target).
Declaration
public virtual void UpdateTargetOutputBitrate(int targetOutputBitrate)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | targetOutputBitrate | The target output bitrate, in kbps. |
UpdateTargetOutputEncoding(EncodingInfo)
Sets the target output encoding. A value of null indicates unset (no target).
Declaration
public virtual void UpdateTargetOutputEncoding(EncodingInfo targetOutputEncoding)
Parameters
Type | Name | Description |
---|---|---|
EncodingInfo | targetOutputEncoding | The target output encoding. |