D3DX10CreateFontIndirect function

Creates a font object.

Note

Instead of using this function, we recommend that you use DirectWrite and the DirectXTK library, SpriteFont class.

 

Syntax

HRESULT D3DX10CreateFontIndirect(
  _In_        ID3D10Device     *pDevice,
  _In_  const D3DX10_FONT_DESC *pDesc,
  _Out_       LPD3DX10FONT     *ppFont
);

Parameters

pDevice [in]

Type: ID3D10Device*

Pointer to an ID3D10Device Interface interface.

pDesc [in]

Type: const D3DX10_FONT_DESC*

Pointer to a D3DX10_FONT_DESC structure, describing the attributes of the font object to create. If Unicode is defined, the function call resolves to D3DXCreateFontIndirectW. Otherwise, the function call resolves to D3DXCreateFontIndirectA because ANSI strings are being used.

ppFont [out]

Type: LPD3DX10FONT*

Returns a pointer to an ID3DX10Font Interface.

Return value

Type: HRESULT

The return value is one of the values listed in Direct3D 10 Return Codes.

Requirements

Requirement Value
Header
D3DX10Core.h
Library
D3DX10.lib

See also

General Purpose Functions