DirectX SDK

Direct3DDevice7.BeginStateBlock

The Direct3DDevice7.BeginStateBlock method signals Direct3D to begin recording a device state block.

object.BeginStateBlock()

Parameters

object
Object expression that resolves to a Direct3DDevice7 object.

Error Codes

If the method fails, an error is raised and Err.Number may be set to one of the following error codes:

DDERR_INVALIDPARAMS
DDERR_OUTOFMEMORY

Remarks

Applications can ensure that all recorded states are valid by calling the Direct3DDevice7.ValidateDevice method prior to calling this method.

The following methods can be recorded in a state block (that is, after calling Direct3DDevice7.BeginStateBlock and before Direct3DDevice7.EndStateBlock):

The ordering of state changes in a state block is not guaranteed. If the same state is specified multiple times in a state set only the last value will be used.

See Also

Direct3DDevice7.EndStateBlock, Direct3DDevice7.CaptureStateBlock, Direct3DDevice7.CreateStateBlock, Direct3DDevice7.DeleteStateBlock, Direct3DDevice7.ApplyStateBlock, State Blocks