Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
MFCreateSinkWriterFromMediaSink
Collapse the table of content
Expand the table of content

MFCreateSinkWriterFromMediaSink function

Creates the sink writer from a media sink.

Syntax


HRESULT MFCreateSinkWriterFromMediaSink(
  _In_  IMFMediaSink  *pMediaSink,
  _In_  IMFAttributes *pAttributes,
  _Out_ IMFSinkWriter **ppSinkWriter
);

Parameters

pMediaSink [in]

Pointer to the IMFMediaSink interface of a media sink.

pAttributes [in]

Pointer to the IMFAttributes interface. You can use this parameter to configure the sink writer. For more information, see Sink Writer Attributes. This parameter can be NULL.

ppSinkWriter [out]

Receives a pointer to the IMFSinkWriter interface. The caller must release the interface.

Return value

If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

Call CoInitialize(Ex) and MFStartup before calling this function.

When you are done using the media sink, call the media sink's IMFMediaSink::Shutdown method. (The sink writer does not shut down the media sink.) Release the sink writer before calling Shutdown on the media sink.

This function is available on Windows Vista if Platform Update Supplement for Windows Vista is installed.

Windows Phone 8.1: This API is supported.

Requirements

Minimum supported client

Windows 7, Windows Vista and Platform Update Supplement for Windows Vista [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2008 R2 [desktop apps | Windows Store apps]

Header

Mfreadwrite.h

Library

Mfreadwrite.lib

DLL

Mfreadwrite.dll

See also

Media Foundation Functions

 

 

Community Additions

ADD
Show:
© 2015 Microsoft