IMFByteStreamHandler::CancelObjectCreation Method

Cancels the current request to create a media source.

Syntax

public:
HRESULT CancelObjectCreation(
         IUnknown *pIUnknownCancelCookie
)  

Parameters

pIUnknownCancelCookie
Type: IUnknown *

Pointer to the IUnknown interface that was returned in the ppIUnknownCancelCookie parameter of the IMFByteStreamHandler::BeginCreateObject method.

Return value

Type: HRESULT 

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return codes
Return code Description
S_OK The method succeeded.

Refer to Media Foundation return codes.

Remarks

You can use this method to cancel a previous call to BeginCreateObject. Because that method is asynchronous, however, it might be completed before the operation can be canceled. Therefore, your callback might still be invoked after you call this method.

Requirements

Header: Declared in mfidl.h.

Library: Use mfuuid.lib.