MF_SOURCE_READER_DISCONNECT_MEDIASOURCE_ON_SHUTDOWN attribute
Specifies whether the Source Reader shuts down the media source.
Data type
UINT32
Get/set
To get this attribute, call IMFAttributes::GetUINT32.
To set this attribute, call IMFAttributes::SetUINT32.
Remarks
This attribute applies only when the application creates the source reader from an existing media source object, either by calling MFCreateSourceReaderFromMediaSource or by calling IMFReadWriteClassFactory::CreateInstanceFromObject.
By default, when the application releases the source reader, the source reader shuts down the media source by calling IMFMediaSource::Shutdown on the media source. At that point, the application can no longer use the media source.
However, if the MF_SOURCE_READER_DISCONNECT_MEDIASOURCE_ON_SHUTDOWN attribute is TRUE, the source reader does not shut down the media source. That means the application can still use the media source after the application releases the source reader. It also means the application is responsible for calling IMFMediaSource::Shutdown on the media source.
If the application creates the source reader from a URL or from a byte stream, the source reader always shuts down the media source. The MF_SOURCE_READER_DISCONNECT_MEDIASOURCE_ON_SHUTDOWN attribute is ignored in this case.
Requirements
Requirement | Value |
---|---|
Minimum supported client |
Windows 7 [desktop apps | UWP apps] |
Minimum supported server |
Windows Server 2008 R2 [desktop apps | UWP apps] |
Header |
|
See also