IDisplayPathInterop::CreateSourcePresentationHandle method (windows.devices.display.core.interop.h)
Creates an NT handle for controlling access to scanout on this path. A compositor application can choose to broker access to paths that it controls using these objects. Your application can call IDisplayDeviceInterop.OpenSharedHandle to create a DisplaySource object from this handle.
HRESULT CreateSourcePresentationHandle( HANDLE *pValue );
A pointer to a HANDLE that receives the newly created source presentation object.
This method returns S_OK if it succeeded, otherwise a failure code indicating why it failed. If it succeeded, then pValue will always point to the newly created handle.
Multiple processes can have handles of the same object, enabling use of the object for interprocess synchronization or sharing. These object-sharing mechanisms are available.
- A process can specify the object handle in a call to the DuplicateHandle function to create a duplicate handle that can be used by another process.
- A process can specify the name of the object in a call to the IDisplayDeviceInterop.OpenSharedHandle function.
Use the CloseHandle function to close the handle. The system closes the handle automatically when the process terminates. The object is destroyed when its last handle has been closed and its last interface reference has been released.
|Minimum supported client||Windows 10 Build 20348|
|Minimum supported server||Windows 10 Build 20348|