IDirect3DDevice::NextViewport

HRESULT NextViewport(LPDIRECT3DVIEWPORT lpDirect3DViewport,

LPDIRECT3DVIEWPORT* lplpDirect3DViewport, DWORD dwFlags);

Enumerates the viewports associated with the device.

·Returns D3D_OK if successful, or an error otherwise, which may be one of the following values:

DDERR_INVALIDOBJECT

DDERR_INVALIDPARAMS

lpDirect3DViewport

Address of a viewport in the list of viewports associated with this Direct3DDevice object.

lplpDirect3DViewport

Address of the next viewport in the list of viewports associated with this Direct3DDevice object.

dwFlags

Flags specifying which viewport to retrieve from the list of viewports. The default setting is D3DNEXT_NEXT.

D3DNEXT_HEAD Retrieve the item at the beginning of the list.

D3DNEXT_NEXT Retrieve the next item in the list.

D3DNEXT_TAIL Retrieve the item at the end of the list.