⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pshints.h

📁 附上freetype2.1.10的源代码,这个和上面传的是一起的
💻 H
📖 第 1 页 / 共 3 页
字号:
  /*                                                                       */  /*    There are "2*count" elements in the "coords" aray.  Each even      */  /*    element is an absolute position in font units, each odd element is */  /*    a length in font units.                                            */  /*                                                                       */  /*    A length can be negative, in which case it must be either -20 or   */  /*    -21.  It will be interpreted as a "ghost" stem, according to the   */  /*    Type 1 specification.                                              */  /*                                                                       */  typedef void  (*T2_Hints_StemsFunc)( T2_Hints   hints,                         FT_UInt    dimension,                         FT_UInt    count,                         FT_Fixed*  coordinates );  /*************************************************************************/  /*                                                                       */  /* @functype:                                                            */  /*    T2_Hints_MaskFunc                                                  */  /*                                                                       */  /* @description:                                                         */  /*    A method of the @T2_Hints class used to set a given hintmask       */  /*    (this corresponds to the "hintmask" Type 2 operator).              */  /*                                                                       */  /* @input:                                                               */  /*    hints     :: A handle to the Type 2 hints recorder.                */  /*                                                                       */  /*    end_point :: The glyph index of the last point to which the        */  /*                 previously defined/activated hints apply.             */  /*                                                                       */  /*    bit_count :: The number of bits in the hint mask.                  */  /*                                                                       */  /*    bytes     :: An array of bytes modelling the hint mask.            */  /*                                                                       */  /* @note:                                                                */  /*    If the hintmask starts the charstring (before any glyph point      */  /*    definition), the value of "end_point" should be 0.                 */  /*                                                                       */  /*    "bit_count" is the number of meaningful bits in the "bytes" array; */  /*    it must be equal to the total number of hints defined so far       */  /*    (i.e. horizontal+verticals).                                       */  /*                                                                       */  /*    The "bytes" array can come directly from the Type 2 charstring and */  /*    respects the same format.                                          */  /*                                                                       */  typedef void  (*T2_Hints_MaskFunc)( T2_Hints        hints,                        FT_UInt         end_point,                        FT_UInt         bit_count,                        const FT_Byte*  bytes );  /*************************************************************************/  /*                                                                       */  /* @functype:                                                            */  /*    T2_Hints_CounterFunc                                               */  /*                                                                       */  /* @description:                                                         */  /*    A method of the @T2_Hints class used to set a given counter mask   */  /*    (this corresponds to the "hintmask" Type 2 operator).              */  /*                                                                       */  /* @input:                                                               */  /*    hints     :: A handle to the Type 2 hints recorder.                */  /*                                                                       */  /*    end_point :: A glyph index of the last point to which the          */  /*                 previously defined/active hints apply.                */  /*                                                                       */  /*    bit_count :: The number of bits in the hint mask.                  */  /*                                                                       */  /*    bytes     :: An array of bytes modelling the hint mask.            */  /*                                                                       */  /* @note:                                                                */  /*    If the hintmask starts the charstring (before any glyph point      */  /*    definition), the value of "end_point" should be 0.                 */  /*                                                                       */  /*    "bit_count" is the number of meaningful bits in the "bytes" array; */  /*    it must be equal to the total number of hints defined so far       */  /*    (i.e. horizontal+verticals).                                       */  /*                                                                       */  /*    The "bytes" array can come directly from the Type 2 charstring and */  /*    respects the same format.                                          */  /*                                                                       */  typedef void  (*T2_Hints_CounterFunc)( T2_Hints        hints,                           FT_UInt         bit_count,                           const FT_Byte*  bytes );  /*************************************************************************/  /*                                                                       */  /* @functype:                                                            */  /*    T2_Hints_CloseFunc                                                 */  /*                                                                       */  /* @description:                                                         */  /*    A method of the @T2_Hints class used to close a hint recording     */  /*    session.                                                           */  /*                                                                       */  /* @input:                                                               */  /*    hints     :: A handle to the Type 2 hints recorder.                */  /*                                                                       */  /*    end_point :: The index of the last point in the input glyph.       */  /*                                                                       */  /* @return:                                                              */  /*    FreeType error code.  0 means success.                             */  /*                                                                       */  /* @note:                                                                */  /*    The error code will be set to indicate that an error occured       */  /*    during the recording session.                                      */  /*                                                                       */  typedef FT_Error  (*T2_Hints_CloseFunc)( T2_Hints  hints,                         FT_UInt   end_point );  /*************************************************************************/  /*                                                                       */  /* @functype:                                                            */  /*    T2_Hints_ApplyFunc                                                 */  /*                                                                       */  /* @description:                                                         */  /*    A method of the @T2_Hints class used to apply hints to the         */  /*    corresponding glyph outline.  Must be called after the "close"     */  /*    method.                                                            */  /*                                                                       */  /* @input:                                                               */  /*    hints     :: A handle to the Type 2 hints recorder.                */  /*                                                                       */  /*    outline   :: A pointer to the target outline descriptor.           */  /*                                                                       */  /*    globals   :: The hinter globals for this font.                     */  /*                                                                       */  /*    hint_mode :: Hinting information.                                  */  /*                                                                       */  /* @return:                                                              */  /*   FreeType error code.  0 means success.                              */  /*                                                                       */  /* @note:                                                                */  /*    On input, all points within the outline are in font coordinates.   */  /*    On output, they are in 1/64th of pixels.                           */  /*                                                                       */  /*    The scaling transformation is taken from the "globals" object      */  /*    which must correspond to the same font than the glyph.             */  /*                                                                       */  typedef FT_Error  (*T2_Hints_ApplyFunc)( T2_Hints        hints,                         FT_Outline*     outline,                         PSH_Globals     globals,                         FT_Render_Mode  hint_mode );  /*************************************************************************/  /*                                                                       */  /* @struct:                                                              */  /*    T2_Hints_FuncsRec                                                  */  /*                                                                       */  /* @description:                                                         */  /*    The structure used to provide the API to @T2_Hints objects.        */  /*                                                                       */  /* @fields:                                                              */  /*    hints    :: A handle to the T2 hints recorder object.              */  /*                                                                       */  /*    open     :: The function to open a recording session.              */  /*                                                                       */  /*    close    :: The function to close a recording session.             */  /*                                                                       */  /*    stems    :: The function to set the dimension's stems table.       */  /*                                                                       */  /*    hintmask :: The function to set hint masks.                        */  /*                                                                       */  /*    counter  :: The function to set counter masks.                     */  /*                                                                       */  /*    apply    :: The function to apply the hints on the corresponding   */  /*                glyph outline.                                         */  /*                                                                       */  typedef struct  T2_Hints_FuncsRec_  {    T2_Hints              hints;    T2_Hints_OpenFunc     open;    T2_Hints_CloseFunc    close;    T2_Hints_StemsFunc    stems;    T2_Hints_MaskFunc     hintmask;    T2_Hints_CounterFunc  counter;    T2_Hints_ApplyFunc    apply;  } T2_Hints_FuncsRec;  /* */  typedef struct  PSHinter_Interface_  {    PSH_Globals_Funcs  (*get_globals_funcs)( FT_Module  module );    T1_Hints_Funcs     (*get_t1_funcs)     ( FT_Module  module );    T2_Hints_Funcs     (*get_t2_funcs)     ( FT_Module  module );  } PSHinter_Interface;  typedef PSHinter_Interface*  PSHinter_Service;FT_END_HEADER#endif /* __PSHINTS_H__ *//* END */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -