//CFTTFont2D - [2020-04-13 11:57:46]
#ifndef _CFTTFONT2D_H_
#define _CFTTFONT2D_H_

#include "CFTTTexture.h"
#include "CFTTMaterialManager.h"
#include "FontDef.h"

/*
001FDDC4 CFTTFont2D::CFTTFont2D(int,int,int,int,int,TLetter *,TGlyph *,CFTTTexture **,uint,bool,float,int,int,TKernPair const*)
001FE290 CFTTFont2D::~CFTTFont2D()
001FD924 CFTTFont2D::NewFont(int,char const*,int,int,CFTTFont2D**,CFTTTexLoadOptions const&)
001FE23C CFTTFont2D::FindChar(wchar_t)
001FE2EC CFTTFont2D::PrintString(TFTTString *,float,float,EFontWrapType,float,float,float,float,float,wchar_t const*)
001FE4F4 CFTTFont2D::PrepareString(TFTTString *,float,float,EFontWrapType,float,float,wchar_t const*)
001FE8D0 CFTTFont2D::CalcUOffset(TFTTString const*)
001FE9D4 CFTTFont2D::FindGlyph(wchar_t)
001FEA28 CFTTFont2D::CharIndex(wchar_t)
001FEA5E CFTTFont2D::IsLineBreakCandidate(wchar_t)
001FEA88 CFTTFont2D::AlignLine(TFTTString *,int,float,float)
001FEAE8 CFTTFont2D::GetGlyphEscapeChars(int &)
001FEAF0 CFTTFont2D::GetCustomGlyphChar(wchar_t const*)
001FEB2A CFTTFont2D::GetCharacterWidth(float,wchar_t)
001FEB6C CFTTFont2D::GetCharacterAdvance(float,wchar_t,wchar_t)
001FEBF4 CFTTFont2D::CalculateKerning(CFTTCharData2D const*,wchar_t)
001FEC7C CFTTFont2D::GetTextDimensions(TFTTString *,bool,EFontWrapType,float,wchar_t const*)

001FC770 FTTFont_Init
001FEC7C CFTTFont2D::GetTextDimensions(TFTTString *,bool,EFontWrapType,float,wchar_t const*)
pTFTTString_5A9818

0x3C
*/

class CFTTFont2D {
public:
  CFTTFont2D(int a1,
             int a2,
             int a3,
             int dTLetter4,
             int dTGlyph5,  //pGlyph7 count
             TLetter *pLetter6,
             TGlyph *pGlyph7,  //r12
             CFTTTexture **ppTexture8,
             uint a9,
             bool b10,
             float f11,
             int d12,
             int d13,
             TKernPair const *pKernPair14);  //001FDDC4

  ~CFTTFont2D();                                                                                                    //001FE290
  static int NewFont(int, char const *, int, int, CFTTFont2D **, CFTTTexLoadOptions const &);                       //001FD924
  int FindChar(wchar_t wc_r1_arg) const;                                                                            //001FE23C
  void PrintString(TFTTString *, float, float, EFontWrapType, float, float, float, float, float, wchar_t const *);  //001FE2EC
  void PrepareString(TFTTString *, float, float, EFontWrapType, float, float, wchar_t const *);                     //001FE4F4
  float CalcUOffset(TFTTString const *p_tfttstring_r1_arg) const;                                                   //001FE8D0
  int FindGlyph(wchar_t) const;                                                                                     //001FE9D4
  int CharIndex(wchar_t) const;                                                                                     //001FEA28
  bool IsLineBreakCandidate(wchar_t);                                                                               //001FEA5E
  void AlignLine(TFTTString *pStr1, int i2, float f3, float f4 = 0.0);                                              //001FEA88
  wchar_t **GetGlyphEscapeChars(int &);                                                                             //001FEAE8
  wchar_t GetCustomGlyphChar(wchar_t const *);                                                                      //001FEAF0
  float GetCharacterWidth(float, wchar_t);                                                                          //001FEB2A
  float GetCharacterAdvance(float, wchar_t, wchar_t);                                                               //001FEB6C
  float CalculateKerning(CFTTCharData2D const *, wchar_t) const;                                                    //001FEBF4
  TextDimensions GetTextDimensions(TFTTString *, bool, EFontWrapType, float, wchar_t const *);                      //001FEC7C

  wchar_t **field_0;  //wchar_t*指针数组地址
  int field_4;        //field_0的count
  uint field_8;       //p_cfttchardata2d_field_2C的count
  int field_C;        //index
  float field_10;
  float field_14;
  int field_18;
  int field_1C;
  bool field_20;
  bool field_21;
  bool field_22;
  bool field_23;  //type?
  int field_24;   //pp_cftttexture_field_28的count
  CFTTTexture **pp_cftttexture_field_28;
  CFTTCharData2D *p_cfttchardata2d_field_2C;  //=tglyph->field_14
  int field_30;
  TKernPair *p_tkernpair_field_34;
  float field_38;
};

#endif  //_CFTTFONT2D_H_