Ignore:
Timestamp:
07/17/13 04:14:38 (12 years ago)
Author:
epyon
Message:
  • freetype2 - using new function loading method
  • gl - using new function loading method
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/freetype2.cc

    r109 r167  
    1111#include "nv/library.hh"
    1212
    13 FT_Error (NV_FREETYPE_APIENTRY *FT_Init_FreeType) (  FT_Library  *alibrary  ) = nullptr;
    14 FT_Error (NV_FREETYPE_APIENTRY *FT_Done_FreeType) (  FT_Library  library  ) = nullptr;
    15 FT_Error (NV_FREETYPE_APIENTRY *FT_New_Face) (  FT_Library library, const char*  filepathname, FT_Long face_index, FT_Face *aface  ) = nullptr;
    16 FT_Error (NV_FREETYPE_APIENTRY *FT_New_Memory_Face) (  FT_Library library, const FT_Byte*  file_base, FT_Long file_size, FT_Long face_index, FT_Face *aface  ) = nullptr;
    17 FT_Error (NV_FREETYPE_APIENTRY *FT_Open_Face) (  FT_Library library, const FT_Open_Args*  args, FT_Long face_index, FT_Face *aface  ) = nullptr;
    18 FT_Error (NV_FREETYPE_APIENTRY *FT_Attach_File) (  FT_Face face, const char*  filepathname  ) = nullptr;
    19 FT_Error (NV_FREETYPE_APIENTRY *FT_Attach_Stream) (  FT_Face face, FT_Open_Args* parameters  ) = nullptr;
    20 FT_Error (NV_FREETYPE_APIENTRY *FT_Reference_Face) (  FT_Face  face  ) = nullptr;
    21 FT_Error (NV_FREETYPE_APIENTRY *FT_Done_Face) (  FT_Face  face  ) = nullptr;
    22 FT_Error (NV_FREETYPE_APIENTRY *FT_Select_Size) (  FT_Face face, FT_Int strike_index  ) = nullptr;
    23 FT_Error (NV_FREETYPE_APIENTRY *FT_Request_Size) (  FT_Face face, FT_Size_Request req  ) = nullptr;
    24 FT_Error (NV_FREETYPE_APIENTRY *FT_Set_Char_Size) (  FT_Face face, FT_F26Dot6 char_width, FT_F26Dot6 char_height, FT_UInt horz_resolution, FT_UInt vert_resolution  ) = nullptr;
    25 FT_Error (NV_FREETYPE_APIENTRY *FT_Set_Pixel_Sizes) (  FT_Face face, FT_UInt pixel_width, FT_UInt pixel_height  ) = nullptr;
    26 FT_Error (NV_FREETYPE_APIENTRY *FT_Load_Glyph) (  FT_Face face, FT_UInt glyph_index, FT_Int32 load_flags  ) = nullptr;
    27 FT_Error (NV_FREETYPE_APIENTRY *FT_Load_Char) (  FT_Face face, FT_ULong char_code, FT_Int32 load_flags  ) = nullptr;
    28 void (NV_FREETYPE_APIENTRY *FT_Set_Transform) (  FT_Face face, FT_Matrix* matrix, FT_Vector* delta  ) = nullptr;
    29 FT_Error (NV_FREETYPE_APIENTRY *FT_Render_Glyph) (  FT_GlyphSlot slot, FT_Render_Mode render_mode  ) = nullptr;
    30 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Kerning) (  FT_Face face, FT_UInt left_glyph, FT_UInt right_glyph, FT_UInt kern_mode, FT_Vector *akerning  ) = nullptr;
    31 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Track_Kerning) (  FT_Face face, FT_Fixed point_size, FT_Int degree, FT_Fixed* akerning  ) = nullptr;
    32 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Glyph_Name) (  FT_Face face, FT_UInt glyph_index, FT_Pointer buffer, FT_UInt buffer_max  ) = nullptr;
    33 const char* (NV_FREETYPE_APIENTRY *FT_Get_Postscript_Name) (  FT_Face face  ) = nullptr;
    34 FT_Error (NV_FREETYPE_APIENTRY *FT_Select_Charmap) (  FT_Face face, FT_Encoding  encoding  ) = nullptr;
    35 FT_Error (NV_FREETYPE_APIENTRY *FT_Set_Charmap) (  FT_Face face, FT_CharMap charmap  ) = nullptr;
    36 FT_Int (NV_FREETYPE_APIENTRY *FT_Get_Charmap_Index) (  FT_CharMap charmap  ) = nullptr;
    37 FT_UInt (NV_FREETYPE_APIENTRY *FT_Get_Char_Index) (  FT_Face face, FT_ULong charcode  ) = nullptr;
    38 FT_ULong (NV_FREETYPE_APIENTRY *FT_Get_First_Char) (  FT_Face face, FT_UInt *agindex  ) = nullptr;
    39 FT_ULong (NV_FREETYPE_APIENTRY *FT_Get_Next_Char) (  FT_Face face, FT_ULong char_code, FT_UInt *agindex  ) = nullptr;
    40 FT_UInt (NV_FREETYPE_APIENTRY *FT_Get_Name_Index) (  FT_Face face, FT_String* glyph_name  ) = nullptr;
    41 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_SubGlyph_Info) (  FT_GlyphSlot glyph, FT_UInt sub_index, FT_Int *p_index, FT_UInt *p_flags, FT_Int *p_arg1, FT_Int *p_arg2, FT_Matrix *p_transform  ) = nullptr;
    42 FT_UShort (NV_FREETYPE_APIENTRY *FT_Get_FSType_Flags) (  FT_Face  face  ) = nullptr;
    43 FT_UInt (NV_FREETYPE_APIENTRY *FT_Face_GetCharVariantIndex) (  FT_Face face, FT_ULong charcode, FT_ULong variantSelector  ) = nullptr;
    44 FT_Int (NV_FREETYPE_APIENTRY *FT_Face_GetCharVariantIsDefault) (  FT_Face face, FT_ULong charcode, FT_ULong variantSelector  ) = nullptr;
    45 FT_UInt32* (NV_FREETYPE_APIENTRY *FT_Face_GetVariantSelectors) (  FT_Face face  ) = nullptr;
    46 FT_UInt32* (NV_FREETYPE_APIENTRY *FT_Face_GetVariantsOfChar) (  FT_Face face, FT_ULong charcode  ) = nullptr;
    47 FT_UInt32* (NV_FREETYPE_APIENTRY *FT_Face_GetCharsOfVariant) (  FT_Face face, FT_ULong variantSelector  ) = nullptr;
    48 FT_Long (NV_FREETYPE_APIENTRY *FT_MulFix) (  FT_Long  a, FT_Long  b  ) = nullptr;
    49 FT_Long (NV_FREETYPE_APIENTRY *FT_DivFix) (  FT_Long  a, FT_Long  b  ) = nullptr;
    50 FT_Fixed (NV_FREETYPE_APIENTRY *FT_RoundFix) (  FT_Fixed  a  ) = nullptr;
    51 FT_Fixed (NV_FREETYPE_APIENTRY *FT_CeilFix) (  FT_Fixed  a  ) = nullptr;
    52 FT_Fixed (NV_FREETYPE_APIENTRY *FT_FloorFix) (  FT_Fixed  a  ) = nullptr;
    53 void (NV_FREETYPE_APIENTRY *FT_Vector_Transform) (  FT_Vector* vec, const FT_Matrix*  matrix  ) = nullptr;
    54 void (NV_FREETYPE_APIENTRY *FT_Library_Version) (  FT_Library library, FT_Int *amajor, FT_Int *aminor, FT_Int *apatch  ) = nullptr;
    55 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Glyph) (  FT_GlyphSlot slot, FT_Glyph *aglyph  ) = nullptr;
    56 FT_Error (NV_FREETYPE_APIENTRY *FT_Glyph_Copy) (  FT_Glyph source, FT_Glyph *target  ) = nullptr;
    57 FT_Error (NV_FREETYPE_APIENTRY *FT_Glyph_Transform) (  FT_Glyph glyph, FT_Matrix* matrix, FT_Vector* delta  ) = nullptr;
    58 void (NV_FREETYPE_APIENTRY *FT_Glyph_Get_CBox) (  FT_Glyph glyph, FT_UInt bbox_mode, FT_BBox  *acbox  ) = nullptr;
    59 FT_Error (NV_FREETYPE_APIENTRY *FT_Glyph_To_Bitmap) (  FT_Glyph* the_glyph, FT_Render_Mode render_mode, FT_Vector* origin, FT_Bool destroy  ) = nullptr;
    60 void (NV_FREETYPE_APIENTRY *FT_Done_Glyph) (  FT_Glyph  glyph  ) = nullptr;
    61 void (NV_FREETYPE_APIENTRY *FT_Matrix_Multiply) (  const FT_Matrix*  a, FT_Matrix*        b  ) = nullptr;
    62 FT_Error (NV_FREETYPE_APIENTRY *FT_Matrix_Invert) (  FT_Matrix*  matrix  ) = nullptr;
    63 FT_Renderer (NV_FREETYPE_APIENTRY *FT_Get_Renderer) (  FT_Library library, FT_Glyph_Format format  ) = nullptr;
    64 FT_Error (NV_FREETYPE_APIENTRY *FT_Set_Renderer) (  FT_Library library, FT_Renderer renderer, FT_UInt num_params, FT_Parameter* parameters  ) = nullptr;
    65 FT_Error (NV_FREETYPE_APIENTRY *FT_Add_Module) (  FT_Library library, const FT_Module_Class*  clazz  ) = nullptr;
    66 FT_Module (NV_FREETYPE_APIENTRY *FT_Get_Module) (  FT_Library library, const char*  module_name  ) = nullptr;
    67 FT_Error (NV_FREETYPE_APIENTRY *FT_Remove_Module) (  FT_Library  library, FT_Module   module  ) = nullptr;
    68 FT_Error (NV_FREETYPE_APIENTRY *FT_Reference_Library) (  FT_Library  library  ) = nullptr;
    69 FT_Error (NV_FREETYPE_APIENTRY *FT_New_Library) (  FT_Memory memory, FT_Library  *alibrary  ) = nullptr;
    70 FT_Error (NV_FREETYPE_APIENTRY *FT_Done_Library) (  FT_Library  library  ) = nullptr;
    71 void (NV_FREETYPE_APIENTRY *FT_Set_Debug_Hook) (  FT_Library library, FT_UInt hook_index, FT_DebugHook_Func  debug_hook  ) = nullptr;
    72 void (NV_FREETYPE_APIENTRY *FT_Add_Default_Modules) (  FT_Library  library  ) = nullptr;
    73 FT_TrueTypeEngineType (NV_FREETYPE_APIENTRY *FT_Get_TrueType_Engine_Type) (  FT_Library  library  ) = nullptr;
    74 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Advance) (  FT_Face face, FT_UInt gindex, FT_Int32 load_flags, FT_Fixed *padvance  ) = nullptr;
    75 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Advances) (  FT_Face face, FT_UInt start, FT_UInt count, FT_Int32 load_flags, FT_Fixed *padvances  ) = nullptr;
    76 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Decompose) (  FT_Outline* outline, const FT_Outline_Funcs*  func_interface, void* user  ) = nullptr;
    77 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_New) (  FT_Library library, FT_UInt numPoints, FT_Int numContours, FT_Outline  *anoutline  ) = nullptr;
    78 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_New_Internal) (  FT_Memory memory, FT_UInt numPoints, FT_Int numContours, FT_Outline  *anoutline  ) = nullptr;
    79 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Done) (  FT_Library library, FT_Outline*  outline  ) = nullptr;
    80 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Done_Internal) (  FT_Memory memory, FT_Outline* outline  ) = nullptr;
    81 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Check) (  FT_Outline*  outline  ) = nullptr;
    82 void (NV_FREETYPE_APIENTRY *FT_Outline_Get_CBox) (  const FT_Outline* outline, FT_BBox *acbox  ) = nullptr;
    83 void (NV_FREETYPE_APIENTRY *FT_Outline_Translate) (  const FT_Outline* outline, FT_Pos xOffset, FT_Pos yOffset  ) = nullptr;
    84 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Copy) (  const FT_Outline* source, FT_Outline *target  ) = nullptr;
    85 void (NV_FREETYPE_APIENTRY *FT_Outline_Transform) (  const FT_Outline* outline, const FT_Matrix* matrix  ) = nullptr;
    86 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Embolden) (  FT_Outline* outline, FT_Pos strength  ) = nullptr;
    87 void (NV_FREETYPE_APIENTRY *FT_Outline_Reverse) (  FT_Outline*  outline  ) = nullptr;
    88 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Get_Bitmap) (  FT_Library library, FT_Outline* outline, const FT_Bitmap *abitmap  ) = nullptr;
    89 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Render) (  FT_Library library, FT_Outline* outline, FT_Raster_Params* params  ) = nullptr;
    90 FT_Orientation (NV_FREETYPE_APIENTRY *FT_Outline_Get_Orientation) (  FT_Outline*  outline  ) = nullptr;
    91 FT_Error (NV_FREETYPE_APIENTRY *FT_Outline_Get_BBox) (  FT_Outline* outline, FT_BBox *abbox  ) = nullptr;
    92 void (NV_FREETYPE_APIENTRY *FT_Bitmap_New) (  FT_Bitmap  *abitmap  ) = nullptr;
    93 FT_Error (NV_FREETYPE_APIENTRY *FT_Bitmap_Copy) (  FT_Library library, const FT_Bitmap *source, FT_Bitmap *target  ) = nullptr;
    94 FT_Error (NV_FREETYPE_APIENTRY *FT_Bitmap_Embolden) (  FT_Library library, FT_Bitmap* bitmap, FT_Pos xStrength, FT_Pos yStrength  ) = nullptr;
    95 FT_Error (NV_FREETYPE_APIENTRY *FT_Bitmap_Convert) (  FT_Library library, const FT_Bitmap *source, FT_Bitmap *target, FT_Int alignment  ) = nullptr;
    96 FT_Error (NV_FREETYPE_APIENTRY *FT_GlyphSlot_Own_Bitmap) (  FT_GlyphSlot  slot  ) = nullptr;
    97 FT_Error (NV_FREETYPE_APIENTRY *FT_Bitmap_Done) (  FT_Library library, FT_Bitmap *bitmap  ) = nullptr;
    98 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_BDF_Charset_ID) (  FT_Face face, const char* *acharset_encoding, const char* *acharset_registry  ) = nullptr;
    99 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_BDF_Property) (  FT_Face face, const char* prop_name, BDF_PropertyRec *aproperty  ) = nullptr;
    100 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_CID_Registry_Ordering_Supplement) (  FT_Face face, const char* *registry, const char* *ordering, FT_Int *supplement  ) = nullptr;
    101 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_CID_Is_Internally_CID_Keyed) (  FT_Face face, FT_Bool *is_cid  ) = nullptr;
    102 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_CID_From_Glyph_Index) (  FT_Face face, FT_UInt glyph_index, FT_UInt *cid  ) = nullptr;
    103 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_PFR_Metrics) (  FT_Face face, FT_UInt *aoutline_resolution, FT_UInt   *ametrics_resolution, FT_Fixed  *ametrics_x_scale, FT_Fixed  *ametrics_y_scale  ) = nullptr;
    104 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_PFR_Kerning) (  FT_Face face, FT_UInt left, FT_UInt right, FT_Vector  *avector  ) = nullptr;
    105 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_PFR_Advance) (  FT_Face face, FT_UInt gindex, FT_Pos *aadvance  ) = nullptr;
    106 FT_Int (NV_FREETYPE_APIENTRY *FT_Get_Gasp) (  FT_Face face, FT_UInt ppem  ) = nullptr;
    107 FT_Error (NV_FREETYPE_APIENTRY *FT_New_Size) (  FT_Face face, FT_Size* size  ) = nullptr;
    108 FT_Error (NV_FREETYPE_APIENTRY *FT_Done_Size) (  FT_Size size  ) = nullptr;
    109 FT_Error (NV_FREETYPE_APIENTRY *FT_Activate_Size) (  FT_Size  size  ) = nullptr;
    110 FT_UInt (NV_FREETYPE_APIENTRY *FT_Get_Sfnt_Name_Count) (  FT_Face  face  ) = nullptr;
    111 FT_Error (NV_FREETYPE_APIENTRY *FT_Get_Sfnt_Name) (  FT_Face face, FT_UInt idx, FT_SfntName  *aname  ) = nullptr;
    112 
    113 FT_StrokerBorder (NV_FREETYPE_APIENTRY *FT_Outline_GetInsideBorder) (  FT_Outline* outline  ) = nullptr;
    114 FT_StrokerBorder (NV_FREETYPE_APIENTRY *FT_Outline_GetOutsideBorder) (  FT_Outline* outline  ) = nullptr;
    115 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_New) (  FT_Library library, FT_Stroker *astroker  ) = nullptr;
    116 void (NV_FREETYPE_APIENTRY *FT_Stroker_Set) (  FT_Stroker stroker, FT_Fixed radius, FT_Stroker_LineCap line_cap, FT_Stroker_LineJoin line_join, FT_Fixed miter_limit  ) = nullptr;
    117 void (NV_FREETYPE_APIENTRY *FT_Stroker_Rewind) (  FT_Stroker stroker  ) = nullptr;
    118 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_ParseOutline) (  FT_Stroker stroker, FT_Outline* outline, FT_Bool opened  ) = nullptr;
    119 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_BeginSubPath) (  FT_Stroker stroker, FT_Vector* to, FT_Bool open  ) = nullptr;
    120 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_EndSubPath) (  FT_Stroker stroker  ) = nullptr;
    121 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_LineTo) (  FT_Stroker stroker, FT_Vector* to  ) = nullptr;
    122 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_ConicTo) (  FT_Stroker stroker, FT_Vector* control, FT_Vector* to  ) = nullptr;
    123 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_CubicTo) (  FT_Stroker stroker, FT_Vector* control1, FT_Vector* control2, FT_Vector* to  ) = nullptr;
    124 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_GetBorderCounts) (  FT_Stroker stroker, FT_StrokerBorder border, FT_UInt *anum_points, FT_UInt *anum_contours  ) = nullptr;
    125 void (NV_FREETYPE_APIENTRY *FT_Stroker_ExportBorder) (  FT_Stroker stroker, FT_StrokerBorder border, FT_Outline* outline  ) = nullptr;
    126 FT_Error (NV_FREETYPE_APIENTRY *FT_Stroker_GetCounts) (  FT_Stroker stroker, FT_UInt *anum_points, FT_UInt *anum_contours  ) = nullptr;
    127 void (NV_FREETYPE_APIENTRY *FT_Stroker_Export) (  FT_Stroker stroker, FT_Outline* outline  ) = nullptr;
    128 void (NV_FREETYPE_APIENTRY *FT_Stroker_Done) (  FT_Stroker stroker  ) = nullptr;
    129 FT_Error (NV_FREETYPE_APIENTRY *FT_Glyph_Stroke) (  FT_Glyph *pglyph, FT_Stroker stroker, FT_Bool destroy  ) = nullptr;
    130 FT_Error (NV_FREETYPE_APIENTRY *FT_Glyph_StrokeBorder) (  FT_Glyph *pglyph, FT_Stroker stroker, FT_Bool inside, FT_Bool destroy  ) = nullptr;
    131 
    132 FT_Fixed (NV_FREETYPE_APIENTRY *FT_Sin) (  FT_Angle angle  ) = nullptr;
    133 FT_Fixed (NV_FREETYPE_APIENTRY *FT_Cos) (  FT_Angle angle  ) = nullptr;
    134 FT_Fixed (NV_FREETYPE_APIENTRY *FT_Tan) (  FT_Angle angle  ) = nullptr;
    135 FT_Angle (NV_FREETYPE_APIENTRY *FT_Atan2) (  FT_Fixed x, FT_Fixed  y  ) = nullptr;
    136 FT_Angle (NV_FREETYPE_APIENTRY *FT_Angle_Diff) (  FT_Angle angle1, FT_Angle  angle2  ) = nullptr;
    137 void (NV_FREETYPE_APIENTRY *FT_Vector_Unit) (  FT_Vector* vec, FT_Angle angle  ) = nullptr;
    138 void (NV_FREETYPE_APIENTRY *FT_Vector_Rotate) (  FT_Vector* vec, FT_Angle angle  ) = nullptr;
    139 FT_Fixed (NV_FREETYPE_APIENTRY *FT_Vector_Length) (  FT_Vector* vec  ) = nullptr;
    140 void (NV_FREETYPE_APIENTRY *FT_Vector_Polarize) (  FT_Vector* vec, FT_Fixed *length, FT_Angle *angle  ) = nullptr;
    141 void (NV_FREETYPE_APIENTRY *FT_Vector_From_Polar) (  FT_Vector* vec, FT_Fixed length, FT_Angle angle  ) = nullptr;
    142 
    143 FT_Error (NV_FREETYPE_APIENTRY *FT_Library_SetLcdFilter) ( FT_Library library, FT_LcdFilter  filter ) = nullptr;
    144 FT_Error (NV_FREETYPE_APIENTRY *FT_Library_SetLcdFilterWeights) ( FT_Library library, unsigned char *weights ) = nullptr;
    145 
     13#define NV_FREETYPE_FUN( rtype, fname, fparams ) rtype (*fname) fparams = nullptr;
     14#include <nv/lib/detail/freetype2_functions.inc>
     15#undef NV_FREETYPE_FUN
    14616
    14717bool nv::load_freetype_library( const char* path )
    14818{
    149 #       define NV_FREETYPE_LOAD( symbol ) *(void **) (&symbol) = freetype_library.get(#symbol);
    15019        static nv::library freetype_library;
    15120        if ( freetype_library.is_open() ) return true;
    15221        freetype_library.open( path );
    15322
    154         NV_FREETYPE_LOAD( FT_Init_FreeType );
    155         NV_FREETYPE_LOAD( FT_Done_FreeType );
    156         NV_FREETYPE_LOAD( FT_New_Face );
    157         NV_FREETYPE_LOAD( FT_New_Memory_Face );
    158         NV_FREETYPE_LOAD( FT_Open_Face );
    159         NV_FREETYPE_LOAD( FT_Attach_File );
    160         NV_FREETYPE_LOAD( FT_Attach_Stream );
    161         NV_FREETYPE_LOAD( FT_Reference_Face );
    162         NV_FREETYPE_LOAD( FT_Done_Face );
    163         NV_FREETYPE_LOAD( FT_Select_Size );
    164         NV_FREETYPE_LOAD( FT_Request_Size );
    165         NV_FREETYPE_LOAD( FT_Set_Char_Size );
    166         NV_FREETYPE_LOAD( FT_Set_Pixel_Sizes );
    167         NV_FREETYPE_LOAD( FT_Load_Glyph );
    168         NV_FREETYPE_LOAD( FT_Load_Char );
    169         NV_FREETYPE_LOAD( FT_Set_Transform );
    170         NV_FREETYPE_LOAD( FT_Render_Glyph );
    171         NV_FREETYPE_LOAD( FT_Get_Kerning );
    172         NV_FREETYPE_LOAD( FT_Get_Track_Kerning );
    173         NV_FREETYPE_LOAD( FT_Get_Glyph_Name );
    174         NV_FREETYPE_LOAD( FT_Get_Postscript_Name );
    175         NV_FREETYPE_LOAD( FT_Select_Charmap );
    176         NV_FREETYPE_LOAD( FT_Set_Charmap );
    177         NV_FREETYPE_LOAD( FT_Get_Charmap_Index );
    178         NV_FREETYPE_LOAD( FT_Get_Char_Index );
    179         NV_FREETYPE_LOAD( FT_Get_First_Char );
    180         NV_FREETYPE_LOAD( FT_Get_Next_Char );
    181         NV_FREETYPE_LOAD( FT_Get_Name_Index );
    182         NV_FREETYPE_LOAD( FT_Get_SubGlyph_Info );
    183         NV_FREETYPE_LOAD( FT_Get_FSType_Flags );
    184         NV_FREETYPE_LOAD( FT_Face_GetCharVariantIndex );
    185         NV_FREETYPE_LOAD( FT_Face_GetCharVariantIsDefault );
    186         NV_FREETYPE_LOAD( FT_Face_GetVariantSelectors );
    187         NV_FREETYPE_LOAD( FT_Face_GetVariantsOfChar );
    188         NV_FREETYPE_LOAD( FT_Face_GetCharsOfVariant );
    189         NV_FREETYPE_LOAD( FT_MulFix );
    190         NV_FREETYPE_LOAD( FT_DivFix );
    191         NV_FREETYPE_LOAD( FT_RoundFix );
    192         NV_FREETYPE_LOAD( FT_CeilFix );
    193         NV_FREETYPE_LOAD( FT_FloorFix );
    194         NV_FREETYPE_LOAD( FT_Vector_Transform );
    195         NV_FREETYPE_LOAD( FT_Library_Version );
    196         NV_FREETYPE_LOAD( FT_Get_Glyph );
    197         NV_FREETYPE_LOAD( FT_Glyph_Copy );
    198         NV_FREETYPE_LOAD( FT_Glyph_Transform );
    199         NV_FREETYPE_LOAD( FT_Glyph_Get_CBox );
    200         NV_FREETYPE_LOAD( FT_Glyph_To_Bitmap );
    201         NV_FREETYPE_LOAD( FT_Done_Glyph );
    202         NV_FREETYPE_LOAD( FT_Matrix_Multiply );
    203         NV_FREETYPE_LOAD( FT_Matrix_Invert );
    204         NV_FREETYPE_LOAD( FT_Get_Renderer );
    205         NV_FREETYPE_LOAD( FT_Set_Renderer );
    206         NV_FREETYPE_LOAD( FT_Add_Module );
    207         NV_FREETYPE_LOAD( FT_Get_Module );
    208         NV_FREETYPE_LOAD( FT_Remove_Module );
    209         NV_FREETYPE_LOAD( FT_Reference_Library );
    210         NV_FREETYPE_LOAD( FT_New_Library );
    211         NV_FREETYPE_LOAD( FT_Done_Library );
    212         NV_FREETYPE_LOAD( FT_Set_Debug_Hook );
    213         NV_FREETYPE_LOAD( FT_Add_Default_Modules );
    214         NV_FREETYPE_LOAD( FT_Get_TrueType_Engine_Type );
    215         NV_FREETYPE_LOAD( FT_Get_Advance );
    216         NV_FREETYPE_LOAD( FT_Get_Advances );
    217         NV_FREETYPE_LOAD( FT_Outline_Decompose );
    218         NV_FREETYPE_LOAD( FT_Outline_New );
    219         NV_FREETYPE_LOAD( FT_Outline_New_Internal );
    220         NV_FREETYPE_LOAD( FT_Outline_Done );
    221         NV_FREETYPE_LOAD( FT_Outline_Done_Internal );
    222         NV_FREETYPE_LOAD( FT_Outline_Check );
    223         NV_FREETYPE_LOAD( FT_Outline_Get_CBox );
    224         NV_FREETYPE_LOAD( FT_Outline_Translate );
    225         NV_FREETYPE_LOAD( FT_Outline_Copy );
    226         NV_FREETYPE_LOAD( FT_Outline_Transform );
    227         NV_FREETYPE_LOAD( FT_Outline_Embolden );
    228         NV_FREETYPE_LOAD( FT_Outline_Reverse );
    229         NV_FREETYPE_LOAD( FT_Outline_Get_Bitmap );
    230         NV_FREETYPE_LOAD( FT_Outline_Render );
    231         NV_FREETYPE_LOAD( FT_Outline_Get_Orientation );
    232         NV_FREETYPE_LOAD( FT_Outline_Get_BBox );
    233         NV_FREETYPE_LOAD( FT_Bitmap_New );
    234         NV_FREETYPE_LOAD( FT_Bitmap_Copy );
    235         NV_FREETYPE_LOAD( FT_Bitmap_Embolden );
    236         NV_FREETYPE_LOAD( FT_Bitmap_Convert );
    237         NV_FREETYPE_LOAD( FT_GlyphSlot_Own_Bitmap );
    238         NV_FREETYPE_LOAD( FT_Bitmap_Done );
    239         NV_FREETYPE_LOAD( FT_Get_BDF_Charset_ID );
    240         NV_FREETYPE_LOAD( FT_Get_BDF_Property );
    241         NV_FREETYPE_LOAD( FT_Get_CID_Registry_Ordering_Supplement );
    242         NV_FREETYPE_LOAD( FT_Get_CID_Is_Internally_CID_Keyed );
    243         NV_FREETYPE_LOAD( FT_Get_CID_From_Glyph_Index );
    244         NV_FREETYPE_LOAD( FT_Get_PFR_Metrics );
    245         NV_FREETYPE_LOAD( FT_Get_PFR_Kerning );
    246         NV_FREETYPE_LOAD( FT_Get_PFR_Advance );
    247         NV_FREETYPE_LOAD( FT_Get_Gasp );
    248         NV_FREETYPE_LOAD( FT_New_Size );
    249         NV_FREETYPE_LOAD( FT_Done_Size );
    250         NV_FREETYPE_LOAD( FT_Activate_Size );
    251         NV_FREETYPE_LOAD( FT_Get_Sfnt_Name_Count );
    252         NV_FREETYPE_LOAD( FT_Get_Sfnt_Name );
    253 
    254         NV_FREETYPE_LOAD( FT_Outline_GetInsideBorder );
    255         NV_FREETYPE_LOAD( FT_Outline_GetOutsideBorder );
    256         NV_FREETYPE_LOAD( FT_Stroker_New );
    257         NV_FREETYPE_LOAD( FT_Stroker_Set );
    258         NV_FREETYPE_LOAD( FT_Stroker_Rewind );
    259         NV_FREETYPE_LOAD( FT_Stroker_ParseOutline );
    260         NV_FREETYPE_LOAD( FT_Stroker_BeginSubPath );
    261         NV_FREETYPE_LOAD( FT_Stroker_EndSubPath );
    262         NV_FREETYPE_LOAD( FT_Stroker_LineTo );
    263         NV_FREETYPE_LOAD( FT_Stroker_ConicTo );
    264         NV_FREETYPE_LOAD( FT_Stroker_CubicTo );
    265         NV_FREETYPE_LOAD( FT_Stroker_GetBorderCounts );
    266         NV_FREETYPE_LOAD( FT_Stroker_ExportBorder );
    267         NV_FREETYPE_LOAD( FT_Stroker_GetCounts );
    268         NV_FREETYPE_LOAD( FT_Stroker_Export );
    269         NV_FREETYPE_LOAD( FT_Stroker_Done );
    270         NV_FREETYPE_LOAD( FT_Glyph_Stroke );
    271         NV_FREETYPE_LOAD( FT_Glyph_StrokeBorder );
    272 
    273         NV_FREETYPE_LOAD( FT_Sin );
    274         NV_FREETYPE_LOAD( FT_Cos );
    275         NV_FREETYPE_LOAD( FT_Tan );
    276         NV_FREETYPE_LOAD( FT_Atan2 );
    277         NV_FREETYPE_LOAD( FT_Angle_Diff );
    278         NV_FREETYPE_LOAD( FT_Vector_Unit );
    279         NV_FREETYPE_LOAD( FT_Vector_Rotate );
    280         NV_FREETYPE_LOAD( FT_Vector_Length );
    281         NV_FREETYPE_LOAD( FT_Vector_Polarize );
    282         NV_FREETYPE_LOAD( FT_Vector_From_Polar );
    283         NV_FREETYPE_LOAD( FT_Library_SetLcdFilter );
    284         NV_FREETYPE_LOAD( FT_Library_SetLcdFilterWeights );
    285 
    286 #       undef NV_FREETYPE_LOAD
     23#       define NV_FREETYPE_FUN( rtype, fname, fparams ) *(void **) (&fname) = freetype_library.get(#fname);
     24#       include <nv/lib/detail/freetype2_functions.inc>
     25#       undef NV_FREETYPE_FUN
    28726        return true;
    28827}
Note: See TracChangeset for help on using the changeset viewer.