Skip to content

Latest commit

 

History

History
87 lines (64 loc) · 4.02 KB

nf-winddi-drvsynchronize.md

File metadata and controls

87 lines (64 loc) · 4.02 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:winddi.DrvSynchronize
DrvSynchronize function (winddi.h)
The DrvSynchronize function informs the driver that GDI needs to access a device-managed surface. This function allows asynchronous drawing operations performed by a device's coprocessor to be coordinated with GDI accesses.
DrvSynchronize
DrvSynchronize function [Display Devices]
ddifncs_dadafaae-d13a-4a52-b179-a8b14a835a24.xml
display.drvsynchronize
winddi/DrvSynchronize
display\drvsynchronize.htm
display
ed9b7db3-1409-4aa6-9ee1-9ece53e747a6
12/05/2018
DrvSynchronize, DrvSynchronize function [Display Devices], ddifncs_dadafaae-d13a-4a52-b179-a8b14a835a24.xml, display.drvsynchronize, winddi/DrvSynchronize
winddi.h
Winddi.h
Desktop
Windows
19H1
DrvSynchronize
winddi/DrvSynchronize
c++
APIRef
kbSyntax
HeaderDef
winddi.h
DrvSynchronize

DrvSynchronize function

-description

The DrvSynchronize function informs the driver that GDI needs to access a device-managed surface. This function allows asynchronous drawing operations performed by a device's coprocessor to be coordinated with GDI accesses.

-parameters

-param dhpdev

Handle to the physical device's PDEV structure that identifies the device to be synchronized with GDI. This parameter is the device handle returned to GDI by DrvEnablePDEV.

-param prcl

Pointer to a RECTL structure. This parameter should be ignored by the driver.

-remarks

This function allows asynchronous drawing operations performed by a device's coprocessor to be coordinated with GDI accesses.

DrvSynchronize can be optionally implemented in display drivers. GDI calls this function only if it is hooked by EngAssociateSurface. GDI calls DrvSynchronize just before drawing directly onto the device surface. GDI will call DrvSynchronizeSurface instead of DrvSynchronize in drivers that implement both of these functions.

This function should return only when it is safe for GDI to access any device-managed surface. That is, DrvSynchronize should delay returning from the call until all asynchronous drawing operations have been completed by the device's coprocessor, thus indicating that it is safe for GDI to access any device-managed surface.

DrvSynchronize is intended to support devices that use a coprocessor for drawing. Such a device can treat some drawing operations as asynchronous, returning to GDI from the operation before the drawing is complete. If this is the case, it is possible that a subsequent drawing operation will be handled by GDI. In order for GDI to safely access device-managed surfaces, it must have a means of ensuring that any asynchronous rendering being done by the device's coprocessor is complete. By calling this function, GDI synchronizes access to a device-managed surface with the driver.

GDI will never call DrvSynchronize for device-managed surfaces. DrvSynchronize is not itself an output function.

-see-also

DrvEnablePDEV

DrvSynchronizeSurface

EngAssociateSurface