Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
DCompositionCreateSurfaceHandle function (dcomp.h)
Creates a new composition surface object that can be bound to a Microsoft DirectX swap chain or swap buffer and associated with a visual.
Syntax
HRESULT DCompositionCreateSurfaceHandle(
[in] DWORD desiredAccess,
[in, optional] SECURITY_ATTRIBUTES *securityAttributes,
[out] HANDLE *surfaceHandle
);
Parameters
[in] desiredAccess
Type: DWORD
The requested access to the composition surface object. It can be one of the following values:
| Value | Meaning |
|---|---|
|
No access. |
|
Read access. For internal use only. |
|
Write access. For internal use only. |
|
Read/write access. Always specify this flag except when duplicating a surface in another process, in which case set desiredAccess to 0. |
[in, optional] securityAttributes
Type: SECURITY_ATTRIBUTES*
Contains the security descriptor for the composition surface object, and specifies whether the handle of the composition surface object is inheritable when a child process is created. If this parameter is NULL, the composition surface object is created with default security attributes that grant read and write access to the current process, but do not enable child processes to inherit the handle.
[out] surfaceHandle
Type: HANDLE*
The handle of the new composition surface object. This parameter must not be NULL.
Return value
Type: HRESULT
If the function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code. See DirectComposition Error Codes for a list of error codes.
Requirements
| Requirement | Value |
|---|---|
| Minimum supported client | Windows 8 [desktop apps only] |
| Minimum supported server | Windows Server 2012 [desktop apps only] |
| Target Platform | Windows |
| Header | dcomp.h |
| Library | Dcomp.lib |
| DLL | Dcomp.dll |
Feedback
Was this page helpful?
