Microsoft DirectX 9.0 SDK Update (October 2004)

Framework.SetDevice Method

Language:

Note: This documentation is preliminary and is subject to change.

Sets an existing Microsoft® Direct3D® Device for use by the sample framework.

Definition

Visual Basic .NET Public Sub SetDevice( _
    ByVal device As Device _
)
C# public void SetDevice(
    Device device
);
Managed C++ public: void SetDevice(
    Device *device
);
JScript .NET public function SetDevice(
    device : Device
);

Parameters

device Microsoft.DirectX.Direct3D.Device. The Microsoft® Direct3D® Device the sample framework is to use.

Remarks

If the CreateWindow method has not already been called, it will call it with the default parameters. Instead of calling SetDevice, you can call CreateDevice method or CreateDeviceFromSettings method.

The application can call this method after a device has already been created to change the current device.


© 2004 Microsoft Corporation. All rights reserved. Terms of use.

Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center