Skip to content

Latest commit

 

History

History
93 lines (72 loc) · 3.95 KB

nf-dxgi-idxgisurface1-releasedc.md

File metadata and controls

93 lines (72 loc) · 3.95 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:dxgi.IDXGISurface1.ReleaseDC
IDXGISurface1::ReleaseDC (dxgi.h)
Releases the GDI device context (DC) that is associated with the current surface and allows you to use Direct3D to render.
07f8f820-f0ad-bbd6-94a3-383d2e895e69
IDXGISurface1 interface [DXGI]
ReleaseDC method
IDXGISurface1.ReleaseDC
IDXGISurface1::ReleaseDC
ReleaseDC
ReleaseDC method [DXGI]
ReleaseDC method [DXGI]
IDXGISurface1 interface
direct3ddxgi.idxgisurface1_releasedc
dxgi/IDXGISurface1::ReleaseDC
direct3ddxgi\idxgisurface1_releasedc.htm
direct3ddxgi
2c3a0cf3-c970-4908-a960-ba261756bd5f
12/05/2018
07f8f820-f0ad-bbd6-94a3-383d2e895e69, IDXGISurface1 interface [DXGI],ReleaseDC method, IDXGISurface1.ReleaseDC, IDXGISurface1::ReleaseDC, ReleaseDC, ReleaseDC method [DXGI], ReleaseDC method [DXGI],IDXGISurface1 interface, direct3ddxgi.idxgisurface1_releasedc, dxgi/IDXGISurface1::ReleaseDC
dxgi.h
Windows
Windows 7 [desktop apps \| UWP apps]
Windows Server 2008 R2 [desktop apps \| UWP apps]
DXGI.lib
Windows
19H1
IDXGISurface1::ReleaseDC
dxgi/IDXGISurface1::ReleaseDC
c++
APIRef
kbSyntax
COM
DXGI.lib
DXGI.dll
IDXGISurface1.ReleaseDC

IDXGISurface1::ReleaseDC

-description

Releases the GDI device context (DC) that is associated with the current surface and allows you to use Direct3D to render.

-parameters

-param pDirtyRect [in, optional]

Type: RECT*

A pointer to a RECT structure that identifies the dirty region of the surface.
A dirty region is any part of the surface that you used for GDI rendering and that you want to preserve. This area is used as a performance hint to graphics subsystem in certain scenarios. Do not use this parameter to restrict rendering to the specified rectangular region. If you pass in NULL, ReleaseDC considers the whole surface as dirty. Otherwise, ReleaseDC uses the area specified by the RECT as a performance hint to indicate what areas have been manipulated by GDI rendering.

You can pass a pointer to an empty RECT structure (a rectangle with no position or area) if you didn't change any content.

-returns

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

-remarks

This method is not supported by DXGI 1.0, which shipped in Windows Vista and Windows Server 2008. DXGI 1.1 support is required, which is available on Windows 7, Windows Server 2008 R2, and as an update to Windows Vista with Service Pack 2 (SP2) (KB 971644) and Windows Server 2008 (KB 971512).

Use the ReleaseDC method to release the DC and indicate that your application finished all GDI rendering to this surface.
You must call the ReleaseDC method before you can use Direct3D to perform additional rendering.

Prior to resizing buffers you must release all outstanding DCs.

-see-also

DXGI Interfaces

IDXGISurface1