IPersistMediaPropertyBag::Load method (strmif.h)
[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]
The Load
method loads properties from the media property bag into the filter.
Syntax
HRESULT Load(
[in] IMediaPropertyBag *pPropBag,
[in] IErrorLog *pErrorLog
);
Parameters
[in] pPropBag
Pointer to the IMediaPropertyBag interface of a media property bag created by the caller.
[in] pErrorLog
Reserved. Set the value to NULL.
Return value
Returns an HRESULT value. Possible values include the following:
Return code | Description |
---|---|
|
Success. |
|
NULL pointer argument. |
|
Access denied. |
|
Filter graph is not in a stopped state. |
Remarks
Call this method on the AVI Mux filter to write the properties into the AVI stream. Call the method when the filter is stopped, before you run the filter graph to author the file. When the graph runs, the filter writes the INFO chunks into the AVI header.
The following code example adds an IART (author name) INFO chunk to a file:
C++ |
---|
IPersistMediaPropertyBag *pPersist = NULL; IMediaPropertyBag *pBag = NULL; VARIANT val; |
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | strmif.h (include Dshow.h) |
Library | Strmiids.lib |