Click to Rate and Give Feedback
MSDN
MSDN Library
DirectX
SDK Documentation
DirectX Graphics
Direct3D 9
Reference
D3DX Reference
Interfaces
ID3DXFont

  Switch on low bandwidth view
ID3DXFont
Bb173961.XDK_CHM_BANNER_left(en-us,VS.85).jpgBb173961.XDK_CHM_BANNER_right(en-us,VS.85).jpg

ID3DXFont

The ID3DXFont interface encapsulates the textures and resources needed to render a specific font on a specific device.

ID3DXFont Members

MethodDescription
ID3DXFont::DrawTextDraws formatted text. This method supports ANSI and Unicode strings.
ID3DXFont::GetDCReturns a handle to a display device context (DC) that has the font set.
ID3DXFont::GetDescGets a description of the current font object. GetDescW and GetDescA are identical to this method, except that a pointer is returned to a D3DXFONT_DESCD3DXFONT_DESCW
ID3DXFont::GetDeviceRetrieves the Direct3D device associated with the font object.
ID3DXFont::GetGlyphDataReturns information about the placement and orientation of a glyph in a character cell.
ID3DXFont::GetTextMetricsRetrieves font characteristics that are identified in a TEXTMETRIC structure. This method supports ANSI and Unicode compiler settings.
ID3DXFont::OnLostDeviceUse this method to release all references to video memory resources and delete all stateblocks. This method should be called whenever a device is lost, or before resetting a device.
ID3DXFont::OnResetDeviceUse this method to re-acquire resources and save initial state.
ID3DXFont::PreloadCharactersLoads a series of characters into video memory to improve the efficiency of rendering to the device.
ID3DXFont::PreloadGlyphsLoads a series of glyphs into video memory to improve the efficiency of rendering to the device.
ID3DXFont::PreloadTextLoads formatted text into video memory to improve the efficiency of rendering to the device. This method supports ANSI and Unicode strings.

Remarks

The ID3DXFont interface is obtained by calling D3DXCreateFont or D3DXCreateFontIndirect.

The LPD3DXFONT type is defined as a pointer to the ID3DXFont interface.

typedef interface ID3DXFont ID3DXFont;
typedef interface ID3DXFont *LPD3DXFONT;

Requirements

Header: Declared in D3dx9core.h.

Library: Use D3dx9.lib.

© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker