Microsoft DirectX 8.1 (Visual Basic)

D3DXSprite.OnLostDevice

Releases all references to video memory resources and deletes all stateblocks.

object.OnResetDevice()

Parameters

object
Object expression that resolves to a D3DXSprite object.

Error Codes

If the method fails, an error is raised and Err.Number can be set to D3DERR_INVALIDCALL.

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

Remarks

This method should be called whenever the device is lost. Before this object can be used again, the device must be reset and the ID3DXFont::OnResetDevice method called.

Requirements

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