Skip to content

Latest commit

 

History

History
78 lines (61 loc) · 4.19 KB

nf-d3d9-idirect3ddevice9-endscene.md

File metadata and controls

78 lines (61 loc) · 4.19 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:d3d9.IDirect3DDevice9.EndScene
IDirect3DDevice9::EndScene (d3d9.h)
The IDirect3DDevice9::EndScene method (d3d9.h) ends a scene that was begun by calling IDirect3DDevice9::BeginScene.
5a0213d4-1bba-e7fc-0a90-704668833b85
EndScene
EndScene method [Direct3D 9]
EndScene method [Direct3D 9]
IDirect3DDevice9 interface
IDirect3DDevice9 interface [Direct3D 9]
EndScene method
IDirect3DDevice9.EndScene
IDirect3DDevice9::EndScene
d3d9helper/IDirect3DDevice9::EndScene
direct3d9.idirect3ddevice9__endscene
direct3d9\idirect3ddevice9__endscene.htm
direct3d9
VS|directx_sdk|~\idirect3ddevice9__endscene.htm
08/10/2022
5a0213d4-1bba-e7fc-0a90-704668833b85, EndScene, EndScene method [Direct3D 9], EndScene method [Direct3D 9],IDirect3DDevice9 interface, IDirect3DDevice9 interface [Direct3D 9],EndScene method, IDirect3DDevice9.EndScene, IDirect3DDevice9::EndScene, d3d9helper/IDirect3DDevice9::EndScene, direct3d9.idirect3ddevice9__endscene
d3d9.h
D3D9.h
Windows
D3D9.lib
Windows
19H1
IDirect3DDevice9::EndScene
d3d9/IDirect3DDevice9::EndScene
c++
APIRef
kbSyntax
COM
D3D9.lib
D3D9.dll
IDirect3DDevice9.EndScene

IDirect3DDevice9::EndScene

-description

Ends a scene that was begun by calling IDirect3DDevice9::BeginScene.

-returns

Type: HRESULT

If the method succeeds, the return value is D3D_OK. The method will fail with D3DERR_INVALIDCALL if IDirect3DDevice9::BeginScene is called while already in a IDirect3DDevice9::BeginScene/IDirect3DDevice9::EndScene pair. This happens only when IDirect3DDevice9::BeginScene is called twice without first calling IDirect3DDevice9::EndScene.

-remarks

When this method succeeds, the scene has been queued up for rendering by the driver. This is not a synchronous method, so the scene is not guaranteed to have completed rendering when this method returns.

Applications must call IDirect3DDevice9::BeginScene before performing any rendering and must call IDirect3DDevice9::EndScene when rendering is complete and before calling IDirect3DDevice9::BeginScene again.

If IDirect3DDevice9::BeginScene fails, the device was unable to begin the scene, and there is no need to call IDirect3DDevice9::EndScene. In fact, calls to

IDirect3DDevice9::EndScene will fail if the previous IDirect3DDevice9::BeginScene failed. This applies to any application that creates multiple swap chains.

There should be at most one IDirect3DDevice9::BeginScene/IDirect3DDevice9::EndScene pair between any successive calls to present (either IDirect3DDevice9::Present or IDirect3DSwapChain9::Present). IDirect3DDevice9::BeginScene should be called once before any rendering is performed, and IDirect3DDevice9::EndScene should be called once after all rendering for a frame has been submitted to the runtime. To enable maximal parallelism between the CPU and the graphics accelerator, it is advantageous to call IDirect3DDevice9::EndScene as far ahead of calling present as possible.

-see-also

IDirect3DDevice9