AdaptiveMediaSource 類別

定義

表示自適性串流內容的來源。

public ref class AdaptiveMediaSource sealed
public ref class AdaptiveMediaSource sealed : IClosable
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class AdaptiveMediaSource final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class AdaptiveMediaSource final : IClosable
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class AdaptiveMediaSource
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class AdaptiveMediaSource : System.IDisposable
Public NotInheritable Class AdaptiveMediaSource
Public NotInheritable Class AdaptiveMediaSource
Implements IDisposable
繼承
Object Platform::Object IInspectable AdaptiveMediaSource
屬性
實作

Windows 需求

裝置系列
Windows 10 (已於 10.0.10240.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v1.0 引進)

備註

呼叫其中一個 CreateFromStreamAsyncCreateFromUriAsync 方法來建立具有特定自適性串流資訊清單來源的 AdaptiveMediaSource 物件。

如需在應用程式中使用自適性串流的作法指引,請參閱 調適型串流

版本歷程記錄

Windows 版本 SDK 版本 新增值
1511 10586 AdvancedSettings
1703 15063 DesiredSeekableWindowSize
1703 15063 診斷
1703 15063 GetCorrelatedTimes
1703 15063 MaxSeekableWindowSize
1703 15063 MinLiveOffset

屬性

AdvancedSettings

取得調適型媒體來源的進階設定。

AudioOnlyPlayback

取得值,指出媒體來源所串流的內容是否只包含音訊。

AvailableBitrates

取得自適性串流資訊清單的可用自適性位元速率,該資訊清單是自適性串流物件的來源。

CurrentDownloadBitrate

取得值,指出媒體來源目前的下載位元速率。

CurrentPlaybackBitrate

取得值,指出媒體來源目前的播放位元速率。

DesiredLiveOffset

取得或設定已下載之已知媒體內容結尾的即時播放所需位移。

DesiredMaxBitrate

取得或設定媒體來源所需的最大位元速率。

DesiredMinBitrate

取得或設定媒體來源所需的最小位元速率。

DesiredSeekableWindowSize

取得或設定使用者可在串流媒體內搜尋的時間範圍最大大小。

Diagnostics

取得 物件,這個物件會提供當可取得自適性媒體來源的診斷資訊時所引發的事件。

InboundBitsPerSecond

取得值,指出 InboundBitsPerSecondWindow 屬性所指定時間範圍中的每秒輸入位統計資料。

InboundBitsPerSecondWindow

取得或設定 要計算 InboundBitsPerSecond 屬性的時間範圍。

InitialBitrate

取得並設定用於播放媒體來源的初始位元速率。

IsLive

取得值,這個值表示媒體來源是否為即時。

MaxSeekableWindowSize

取得使用者可以在串流媒體內搜尋的最大時間範圍。

MinLiveOffset

從已下載的已知媒體內容結尾取得即時播放的最小位移。

方法

Close()

關閉調適型媒體來源並釋放相關聯的資源。

CreateFromStreamAsync(IInputStream, Uri, String)

以非同步方式從提供的輸入資料流程建立 AdaptiveMediaSource 物件。

CreateFromStreamAsync(IInputStream, Uri, String, HttpClient)

以非同步方式從提供的輸入資料流程建立 AdaptiveMediaSource 物件。

CreateFromUriAsync(Uri)

以非同步方式從來源的統一資源識別項 (URI) 建立 AdaptiveMediaSource 物件。

CreateFromUriAsync(Uri, HttpClient)

以非同步方式從來源的統一資源識別項 (URI) 建立 AdaptiveMediaSource 物件。

Dispose()

執行與釋放 (Free)、釋放 (Release) 或重設 Unmanaged 資源相關聯之應用程式定義的工作。

GetCorrelatedTimes()

取得 物件,這個物件提供與簡報時鐘時間軸之資訊清單中時間戳記或日期/時間資訊之間的時間資訊相互關聯的計時資訊。

IsContentTypeSupported(String)

判斷是否支援來源的內容類型。

事件

DownloadBitrateChanged

發生于 CurrentDownloadBitrate 變更時。

DownloadCompleted

發生于資源下載作業完成時

DownloadFailed

發生于資源下載作業失敗時。

DownloadRequested

發生于要求資源下載作業時。

PlaybackBitrateChanged

發生于 CurrentPlaybackBitrate 變更時。

適用於

另請參閱