Microsoft DirectX 8.1 (Visual Basic)

Direct3DDevice8.SetRenderState

Sets a single device render-state parameter.

object.SetRenderState( _ 
    State As CONST_D3DRENDERSTATETYPE, _ 
    Value As Long)

Parts

object
Object expression that resolves to a Direct3DDevice8 object.
State
Device state variable that is being modified. This parameter can be any member of the CONST_D3DRENDERSTATETYPE enumeration.
Value
New value for the device render state to be set. The meaning of this parameter is dependent on the value specified for State. For example, if State were D3DRS_SHADEMODE, the second parameter would be one member of the CONST_D3DSHADEMODE enumeration.

Error Codes

If the method fails, it sets Err.Number to an error code and raises an error. The error code is D3DERR_INVALIDCALL if one of the parameters is invalid.

For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.

See Also

Direct3DDevice8.GetRenderState, Direct3DDevice8.SetTransform