Microsoft DirectX 8.1 (C++)

ID3DXRenderToSurface::BeginScene

Begins a scene.

HRESULT BeginScene(
  LPDIRECT3DSURFACE8 pSurface,
  CONST D3DVIEWPORT8* pViewport
);

Parameters

pSurface
[in] Pointer to an IDirect3DSurface8 interface, representing the render surface.
pViewport
[in] Pointer to a D3DVIEWPORT8 structure, describing the viewport for the scene.

Return Values

If the method succeeds, the return value is D3D_OK.

If the method fails, the return value can be one of the following values.

D3DERR_INVALIDCALL
D3DERR_OUTOFVIDEOMEMORY
D3DXERR_INVALIDDATA
E_OUTOFMEMORY

Requirements

  Header: Declared in D3dx8core.h.
  Import Library: Use D3dx8.lib.

See Also

ID3DXRenderToSurface::EndScene