Microsoft DirectX 9.0


The NotifyAcquire method notifies the resource manager that an attempt to acquire a resource has completed.


HRESULT NotifyAcquire(
  LONG idResource,
  IResourceConsumer *pConsumer,



[in] Token for the registered resource.


[in] Pointer to the IResourceConsumer interface of the object requesting the resource.


[in] Value indicating the success of the acquisition; S_OK if the resource was acquired, or an error value if not.

Return Value

Returns an HRESULT value that depends on the implementation. HRESULT can be one of the following standard constants, or other values not listed.

Return code Description
E_FAIL Failure.
E_POINTER Null pointer argument.
E_INVALIDARG Invalid argument.
E_NOTIMPL Method isn't supported.
S_OK or NOERROR Success.


Use this method after an IResourceConsumer::AcquireResource method returns an S_FALSE value, indicating that the acquisition will be asynchronous (that is, handled by a callback mechanism). If the hr parameter is S_OK, the resource manager will assume that the resource is now held by the caller. If the hr parameter is anything other than S_OK, the resource manager will assume that the attempt to acquire the resource failed and will reassign the resource elsewhere.

See Also