IDirect3DRMVisualArray

Applications use the methods of the IDirect3DRMVisualArray interface to organize groups of visual objects.

Visuals are objects that can be rendered in a scene. Visuals are visible only when they are added to a frame in that scene. An application can add a visual to a frame by using the IDirect3DRMFrame3::AddVisual method. The frame provides the visual with position and orientation for rendering.

Note: although there is a IDirect3DRMVisual COM interface, it has no Direct3D Retained Mode-specific methods.

The most common visual types are Direct3DRMMeshBuilder3 and Direct3DRMTexture objects.

The IDirect3DRMVisualArray interface supports the following methods:
GetElement
GetSize

The IDirect3DRMVisualArray interface, like all COM interfaces, inherits the IUnknown interface methods. The IUnknown interface supports the following three methods:
AddRef
QueryInterface
Release

The Direct3DRMVisualArray object is obtained by calling the IDirect3DRMFrame3::GetVisuals method.

IDirect3DRMVisualArray::GetElement

IDirect3DRMVisualArray

Retrieves a specified element in a Direct3DRMVisualArray object.

Syntax

HRESULT GetElement(
  DWORD index,
  LPDIRECT3DRMVISUAL *lplpD3DRMVisual
  );

Parameters

index
Element in the array.
lplpD3DRMVisual
Address that will be filled with a pointer to an IDirect3DRMVisual interface.

Return Value

Returns D3DRM_OK if successful, or an error otherwise. For a list of possible errors, see Direct3D Retained Mode Return Values.

IDirect3DRMVisualArray::GetSize

IDirect3DRMVisualArray

Retrieves the number of elements contained in a Direct3DRMVisualArray object.

Syntax

DWORD GetSize( );

Return Value

Returns the number of elements.


Top of Page Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.