Class BridgeAudioSourceSettings
- Namespace
- VisioForge.Core.Types.X.Bridge
- Assembly
- VisioForge.Core.dll
Bridge audio source settings.
public class BridgeAudioSourceSettings : IVideoCaptureBaseAudioSourceSettings, IMediaBlockSettings, IAudioVolumeMuteInheritance
Implements
Inherited Members
Constructors
BridgeAudioSourceSettings(string, AudioInfoX)
Initializes a new instance of the VisioForge.Core.Types.X.Bridge.BridgeAudioSourceSettings class.
public BridgeAudioSourceSettings(string channel, AudioInfoX audioInfo)Parameters
channelstring-
The channel.
audioInfoAudioInfoX-
The audio information.
Properties
BufferTime
Gets or sets the size of audio buffer.
public TimeSpan BufferTime { get; set; }Property Value
Channel
Gets or sets the channel name to match bridge source and sink elements.
public string Channel { get; }Property Value
DisableAudioConversion
Gets or sets a value indicating whether to disable audio conversion.
public bool DisableAudioConversion { get; set; }Property Value
DoTimestamp
Gets or sets whether to apply current stream time to buffers.
public bool DoTimestamp { get; set; }Property Value
Info
Gets or sets the audio information.
public AudioInfoX Info { get; set; }Property Value
LatencyTime
Gets or sets the latency as reported by the source.
public TimeSpan LatencyTime { get; set; }Property Value
PeriodTime
Gets or sets the minimum amount of data to read in each iteration.
public TimeSpan PeriodTime { get; set; }Property Value
QueueSettings
Gets or sets optional settings for the queue after interaudiosrc.
Leave null to keep GStreamer queue defaults (non-leaky,
~200 buffers, ~10 MB, 1 s time bound — verified via
gst-inspect-1.0 queue) for backward compatibility.
public TeeQueueSettings QueueSettings { get; set; }Property Value
Remarks
Setting this to a value with VisioForge.Core.Types.X.Special.TeeQueueSettings.Leaky =
Downstream turns the queue into a sample-dropping leaky queue:
under backpressure the queue silently discards audio buffers instead
of blocking the producer. This is appropriate for live monitoring
paths (Decklink output, low-latency preview) where lost samples are
preferable to growing latency, but it MUST NOT be used on a recording
path — the muxer will see a discontinuous timeline and the resulting
file may have audio gaps, sync drift, or invalid stsd entries.
Interaction with VisioForge.Core.Types.X.Bridge.BridgeAudioSourceSettings.DisableAudioConversion:
DisableAudioConversion = false(default): the queue is always present betweeninteraudiosrcand the conversion chain; VisioForge.Core.Types.X.Bridge.BridgeAudioSourceSettings.QueueSettings overrides its defaults when non-null.DisableAudioConversion = truewith VisioForge.Core.Types.X.Bridge.BridgeAudioSourceSettings.QueueSettings= null: true zero-queue passthrough,interaudiosrc → capsfilter, lowest latency, no thread boundary or backpressure.DisableAudioConversion = truewith VisioForge.Core.Types.X.Bridge.BridgeAudioSourceSettings.QueueSettings!= null: a queue is inserted betweeninteraudiosrcand the capsfilter, so callers who want the conversion-skipping fast path AND a leaky/bounded queue (e.g. live Decklink output) can have both. The convert/resample stages stay disabled.
Methods
CreateBlock()
Creates the block.
public MediaBlock CreateBlock()Returns
- MediaBlock
-
MediaBlock.
Exceptions
GetMute()
Gets the mute.
public bool GetMute()Returns
- bool
-
trueif successful,falseotherwise.
GetVolume()
Gets the volume. Value should be in 0.0 - 1.0 range.
public double GetVolume()Returns
- double
-
System.Double.
IsSupported()
Determines whether this interface is supported.
public bool IsSupported()Returns
- bool
-
trueif this interface is supported; otherwise,false.
SetInterface(IAudioVolumeMute)
Sets the interface.
public void SetInterface(IAudioVolumeMute intf)Parameters
intfIAudioVolumeMute-
The interface.
SetMute(bool)
Sets the mute.
public void SetMute(bool mute)Parameters
mutebool-
if set to
truemute.
SetVolume(double)
Sets the volume. Value should be in 0.0 - 1.0 range.
public void SetVolume(double volume)Parameters
volumedouble-
The volume.