Microsoft DirectX 8.1 (C++) |
The Reserve method reserves or unreserves a device resource.
Syntax
HRESULT Reserve(
DWORD dwFlags,
PVOID pvReserved
);
Parameters
dwFlags
[in] Flag indicating whether to reserve or unreserve this device. For possible values, see Remarks.
pvReserved
[in] Must be NULL.
Return Values
Returns S_OK if the device was successfully reserved or unreserved, S_FALSE if the device is currently reserved and will continue to be held, or an HRESULT error code if the device can't be reserved.
Remarks
The allowable values for dwFlags are defined in the AMRESCTL_RESERVEFLAGS enumeration.
Important A resource can be reserved multiple times. The reserve count is incremented or decremented only if S_OK is returned. Each successful call (one that returns S_OK) to reserve a device must be matched by a call to unreserve it.
See Also