AudioGraphSettings AudioGraphSettings AudioGraphSettings AudioGraphSettings Class

Definition

Represents initialization settings for an audio graph. Set the properties of this object to your desired values and then call AudioGraph::CreateAsync to create a new audio graph instance with the specified settings.

public : sealed class AudioGraphSettings : IAudioGraphSettingspublic sealed class AudioGraphSettings : IAudioGraphSettingsPublic NotInheritable Class AudioGraphSettings Implements IAudioGraphSettings// You can use this class in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Constructors

AudioGraphSettings(AudioRenderCategory) AudioGraphSettings(AudioRenderCategory) AudioGraphSettings(AudioRenderCategory) AudioGraphSettings(AudioRenderCategory)

Initializes a new instance of the AudioGraphSettings class with initial settings values optimized for the specified AudioRenderCategory.

public : AudioGraphSettings(AudioRenderCategory audioRenderCategory)public AudioGraphSettings(AudioRenderCategory audioRenderCategory)Public Sub New(audioRenderCategory As AudioRenderCategory)// You can use this method in JavaScript.
Parameters
audioRenderCategory
AudioRenderCategory AudioRenderCategory AudioRenderCategory AudioRenderCategory

The AudioRenderCategory that determines the initial settings values.

Properties

AudioRenderCategory AudioRenderCategory AudioRenderCategory AudioRenderCategory

Gets or sets a value that indicates the audio render category setting for the audio graph.

public : AudioRenderCategory AudioRenderCategory { get; set; }public AudioRenderCategory AudioRenderCategory { get; set; }Public ReadWrite Property AudioRenderCategory As AudioRenderCategory// You can use this property in JavaScript.
Value
AudioRenderCategory AudioRenderCategory AudioRenderCategory AudioRenderCategory

A value that indicates the audio render category setting for an audio graph.

DesiredRenderDeviceAudioProcessing DesiredRenderDeviceAudioProcessing DesiredRenderDeviceAudioProcessing DesiredRenderDeviceAudioProcessing

Gets or sets a value that indicates the desired audio processing mode setting for the audio graph.

public : AudioProcessing DesiredRenderDeviceAudioProcessing { get; set; }public AudioProcessing DesiredRenderDeviceAudioProcessing { get; set; }Public ReadWrite Property DesiredRenderDeviceAudioProcessing As AudioProcessing// You can use this property in JavaScript.
Value
AudioProcessing AudioProcessing AudioProcessing AudioProcessing

A value that indicates the desired audio processing mode setting for the audio graph.

Remarks

Setting this property does not guarantee that the specified value will be used by the created audio graph. To determine the actual value used, check the AudioGraph.RenderDeviceAudioProcessing property of the audio graph after it has been created.

DesiredSamplesPerQuantum DesiredSamplesPerQuantum DesiredSamplesPerQuantum DesiredSamplesPerQuantum

Gets or sets the desired number of samples per quantum defined for the audio graph.

public : int DesiredSamplesPerQuantum { get; set; }public int DesiredSamplesPerQuantum { get; set; }Public ReadWrite Property DesiredSamplesPerQuantum As int// You can use this property in JavaScript.
Value
int int int int

The number of samples per quantum.

Remarks

Note that this property value is only valid if the QuantumSizeSelectionMode property is set to ClosestToDesired.

If the audio graph you created is intended to be used exclusively with files, it is strongly recommended that you set the QuantumSizeSelectionMode to SystemDefault.

Setting this property does not guarantee that the specified value will be used by the created audio graph. To determine the actual value used, check the AudioGraph.SamplesPerQuantum property of the audio graph after it has been created.

EncodingProperties EncodingProperties EncodingProperties EncodingProperties

Gets or sets the audio encoding properties setting for the audio graph.

public : AudioEncodingProperties EncodingProperties { get; set; }public AudioEncodingProperties EncodingProperties { get; set; }Public ReadWrite Property EncodingProperties As AudioEncodingProperties// You can use this property in JavaScript.
Value
AudioEncodingProperties AudioEncodingProperties AudioEncodingProperties AudioEncodingProperties

The audio encoding properties for the audio graph.

Remarks

Audio graphs always operate using 32-bit float encoding, regardless of the Subtype value in the specified AudioEncodingProperties.

PrimaryRenderDevice PrimaryRenderDevice PrimaryRenderDevice PrimaryRenderDevice

Gets or sets an object that represents the primary render device for the audio graph.

public : DeviceInformation PrimaryRenderDevice { get; set; }public DeviceInformation PrimaryRenderDevice { get; set; }Public ReadWrite Property PrimaryRenderDevice As DeviceInformation// You can use this property in JavaScript.
Value
DeviceInformation DeviceInformation DeviceInformation DeviceInformation

An object that represents the primary render device for the audio graph.

Remarks

If PrimaryRenderDevice is null, the default playback device will be used.

QuantumSizeSelectionMode QuantumSizeSelectionMode QuantumSizeSelectionMode QuantumSizeSelectionMode

Gets or sets the quantum size selection mode for the audio graph.

public : QuantumSizeSelectionMode QuantumSizeSelectionMode { get; set; }public QuantumSizeSelectionMode QuantumSizeSelectionMode { get; set; }Public ReadWrite Property QuantumSizeSelectionMode As QuantumSizeSelectionMode// You can use this property in JavaScript.
Value
QuantumSizeSelectionMode QuantumSizeSelectionMode QuantumSizeSelectionMode QuantumSizeSelectionMode

An enumeration value indicating the quantum size selection mode. If the audio graph is only to be used with files, it is strongly recommended to use the value SystemDefault.

Remarks

If the audio graph you created is intended to be used exclusively with files, it is strongly recommended that you set the QuantumSizeSelectionMode to SystemDefault.

Selecting QuantumSizeSelectionMode.LowestLatency can result in different quantum sizes across different devices or audio endpoints.