Package com.ms.com.directX Previous
Previous
Microsoft Packages
Microsoft Packages
Index
Index
Next
Next

Class d3d

Applications use the methods of the d3d class to create Direct3D objects and set up the environment.

public class d3d implements Id3d
{
  public void InternalSetObject(IUnknown lpdd);
  public IUnknown InternalGetObject();
  public void Initialize(_GUID id);
  public void EnumDevices(Id3dEnumDevicesCallback fn, IUnknown p);
  public d3dLight CreateLight(IUnknown p);
  public d3dMaterial CreateMaterial(IUnknown p);
  public d3dViewport CreateViewport(IUnknown p);
  public void FindDevice(d3dFindDeviceSearch ds, d3dFindDeviceResult val);
  public void FindDeviceForColorModel(int cm, GuidData g);
  public int SystemBpp();
}

The methods can be organized into the following groups:
Creation CreateLight
CreateMaterial
CreateViewport
Enumeration EnumDevices
Initialization FindDeviceForColorModel
FindDevice
Initialize
SystemBpp

CreateLight

public d3dLight CreateLight(IUnknown p);

Allocates a Direct3DLight object. This object can then be associated with a viewport by using the AddLight method.

Return Value:

Returns the d3dLight object if successful; null otherwise.

ParameterDescription
p Reserved; must be null.


CreateMaterial

public d3dMaterial CreateMaterial(IUnknown p);

Allocates a Direct3DMaterial object.

Return Value:

Returns the d3dMaterial object if successful; null otherwise.

ParameterDescription
p Reserved; must be null.


CreateViewport

public d3dViewport CreateViewport(IUnknown p);

Creates a Direct3DViewport object. The viewport is associated with a Direct3DDevice object by using the AddViewport method.

Return Value:

Returns the d3dViewport object if successful; null otherwise.

ParameterDescription
p Reserved; must be null.


EnumDevices

public void EnumDevices(Id3dEnumDevicesCallback fn, IUnknown p);

Enumerates all Direct3D device drivers installed on the system.

Return Value:

No return value.

ParameterDescription
fn Interface containing callback function that the enumeration procedure will call every time a match is found.
p Application-defined data passed to the callback function.


FindDevice

public void FindDevice(d3dFindDeviceSearch ds, d3dFindDeviceResult val);

Searches for and returns information about devices that match the given description.

Return Value:

No return value.

ParameterDescription
ds The d3dFindDeviceSearch object that contains a description of the device(s) to search for.
val The d3dFindDeviceResult object that receives the results of the search.


FindDeviceForColorModel

public void FindDeviceForColorModel(int cm, GuidData g);

Finds a device with specified color model characteristics and retrieves a description of it.

Return Value:

No return value.

ParameterDescription
cm One value of D3DCOLOR_ type, specifying the color model to locate.
g Receives the globally unique identifier for the device that supports the given color model.


Initialize

public void Initialize(_GUID id);

Initializes the d3d object.

Return Value:

No return value.

ParameterDescription
id A universally unique identifier (UUID).


SystemBpp

public int SystemBpp();

Returns the system bits-per-pixel value.

Return Value:

Returns bits-per-pixel.



Top© 1996 Microsoft Corporation. All rights reserved.