Applications use the methods of the IDirect3DRMWrap interface to work with wrap objects. This section is a reference to the methods of this interface. For a conceptual overview, see Wraps.
The methods of the IDirect3DRMWrap interface can be organized into the following groups:
Initialization | Init |
Wrap | Apply |
ApplyRelative |
The IDirect3DRMWrap interface, like all Component Object Model (COM) interfaces, inherits the IUnknown interface methods. The IUnknown interface supports the following three methods:
AddRef |
QueryInterface |
Release |
In addition, the IDirect3DRMWrap interface inherits the following methods from the IDirect3DRMObject interface:
AddDestroyCallback |
Clone |
DeleteDestroyCallback |
GetAppData |
GetClassName |
GetName |
SetAppData |
SetName |
The Direct3DRMWrap object is obtained by using the IDirect3DRM3::CreateWrap method.
Applies a Direct3DRMWrap object to its destination object. The destination object is typically a face or a mesh.
Syntax
HRESULT Apply(
LPDIRECT3DRMOBJECT lpObject
);
Parameters
- lpObject
- Address of the destination object.
Return Value
Returns D3DRM_OK if successful, or an error otherwise. For a list of possible errors, see Direct3D Retained Mode Return Values.
See Also
Applies the wrap to the vertices of the object, first transforming each vertex by the frame's world transformation and the inverse world transformation of the wrap's reference frame.
Syntax
HRESULT ApplyRelative(
LPDIRECT3DRMFRAME frame,
LPDIRECT3DRMOBJECT mesh
);
Parameters
- frame
- Direct3DRMFrame object containing the object to wrap.
- mesh
- Direct3DRMWrap object to apply.
Return Value
Returns D3DRM_OK if successful, or an error otherwise. For a list of possible errors, see Direct3D Retained Mode Return Values.
See Also
Initializes a Direct3DRMWrap object.
Syntax
HRESULT Init(
D3DRMWRAPTYPE d3drmwt,
LPDIRECT3DRMFRAME lpd3drmfRef,
D3DVALUE ox,
D3DVALUE oy,
D3DVALUE oz,
D3DVALUE dx,
D3DVALUE dy,
D3DVALUE dz,
D3DVALUE ux,
D3DVALUE uy,
D3DVALUE uz,
D3DVALUE ou,
D3DVALUE ov,
D3DVALUE su,
D3DVALUE sv
);
Parameters
- d3drmwt
- One of the members of the D3DRMWRAPTYPE enumerated type.
- lpd3drmfRef
- Address of a Direct3DRMFrame object representing the reference frame for this Direct3DRMWrap object.
- ox, oy, and oz
- Origin of the wrap.
- dx, dy, and dz
- The z-axis of the wrap.
- ux, uy, and uz
- The y-axis of the wrap.
- ou and ov
- Origin of the texture.
- su and sv
- Scale factor of the texture.
Return Value
Returns D3DRM_OK if successful, or an error otherwise. For a list of possible errors, see Direct3D Retained Mode Return Values.
See Also
Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.