Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

AudioEncodingProperties.AudioEncodingProperties constructor

Applies to Windows and Windows Phone

Creates a new instance of the AudioEncodingProperties class.

Syntax


var audioEncodingProperties = new Windows.Media.MediaProperties.AudioEncodingProperties();

Parameters

This constructor has no parameters.

Examples

The following example shows how to create an instance of the AudioEncodingProperties class.


function getProperties() {
    var encodingProperties = new Windows.Media.MediaProperties.AudioEncodingProperties();
    var bit_rate = encodingProperties.bitrate;
    var sampleBits = encodingProperties.bitsPerSample;
    var count = encodingProperties.channelCount;
    var s_rate = encodingProperties.sampleRate;
    var audioSubType = encodingProperties.subtype;
    var audioType = encodingProperties.type;
    if (audioType === "Audio" && audioSubType === "MP3") {
        // The format is an MP3 audio stream.
    }
}


Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Media.MediaProperties
Windows::Media::MediaProperties [C++]

Metadata

Windows.winmd

See also

AudioEncodingProperties

 

 

Show:
© 2014 Microsoft. All rights reserved.