MediaSource.CreateFromStream(IRandomAccessStream, String) 方法

定义

从提供的 IRandomAccessStream 创建 MediaSource 的实例。

public:
 static MediaSource ^ CreateFromStream(IRandomAccessStream ^ stream, Platform::String ^ contentType);
 static MediaSource CreateFromStream(IRandomAccessStream const& stream, winrt::hstring const& contentType);
public static MediaSource CreateFromStream(IRandomAccessStream stream, string contentType);
function createFromStream(stream, contentType)
Public Shared Function CreateFromStream (stream As IRandomAccessStream, contentType As String) As MediaSource

参数

stream
IRandomAccessStream

从中创建 MediaSource 的流。

contentType
String

Platform::String

winrt::hstring

流的内容的 MIME 类型。

返回

新的媒体源。

适用于