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

📄 ftimage.h

📁 qt-embedded-2.3.8.tar.gz源码
💻 H
📖 第 1 页 / 共 5 页
字号:
  /*                                                                       */  /* <Description>                                                         */  /*    A handle (pointer) to a raster object.  Each object can be used    */  /*    independently to convert an outline into a bitmap or pixmap.       */  /*                                                                       */  typedef struct FT_RasterRec_*  FT_Raster;  /*************************************************************************/  /*                                                                       */  /* <Struct>                                                              */  /*    FT_Span                                                            */  /*                                                                       */  /* <Description>                                                         */  /*    A structure used to model a single span of gray (or black) pixels  */  /*    when rendering a monochrome or anti-aliased bitmap.                */  /*                                                                       */  /* <Fields>                                                              */  /*    x        :: The span's horizontal start position.                  */  /*                                                                       */  /*    len      :: The span's length in pixels.                           */  /*                                                                       */  /*    coverage :: The span color/coverage, ranging from 0 (background)   */  /*                to 255 (foreground).  Only used for anti-aliased       */  /*                rendering.                                             */  /*                                                                       */  /* <Note>                                                                */  /*    This structure is used by the span drawing callback type named     */  /*    FT_Raster_Span_Func(), which takes the y-coordinate of the span as */  /*    a parameter.                                                       */  /*                                                                       */  /*    The coverage value is always between 0 and 255, even if the number */  /*    of gray levels have been set through FT_Set_Gray_Levels().         */  /*                                                                       */  typedef struct  FT_Span_  {    short          x;    unsigned short len;    unsigned char  coverage;  } FT_Span;  /*************************************************************************/  /*                                                                       */  /* <FuncType>                                                            */  /*    FT_Raster_Span_Func                                                */  /*                                                                       */  /* <Description>                                                         */  /*    A function used as a call-back by the anti-aliased renderer in     */  /*    order to let client applications draw themselves the gray pixel    */  /*    spans on each scan line.                                           */  /*                                                                       */  /* <Input>                                                               */  /*    y     :: The scanline's y-coordinate.                              */  /*                                                                       */  /*    count :: The number of spans to draw on this scanline.             */  /*                                                                       */  /*    spans :: A table of `count' spans to draw on the scanline.         */  /*                                                                       */  /*    user  :: User-supplied data that is passed to the callback.        */  /*                                                                       */  /* <Note>                                                                */  /*    This callback allows client applications to directly render the    */  /*    gray spans of the anti-aliased bitmap to any kind of surfaces.     */  /*                                                                       */  /*    This can be used to write anti-aliased outlines directly to a      */  /*    given background bitmap, and even perform translucency.            */  /*                                                                       */  /*    Note that the `count' field cannot be greater than a fixed value   */  /*    defined by the FT_MAX_GRAY_SPANS configuration macro in            */  /*    ftoption.h.  By default, this value is set to 32, which means that */  /*    if there are more than 32 spans on a given scanline, the callback  */  /*    will be called several times with the same `y' parameter in order  */  /*    to draw all callbacks.                                             */  /*                                                                       */  /*    Otherwise, the callback is only called once per scan-line, and     */  /*    only for those scanlines that do have `gray' pixels on them.       */  /*                                                                       */  typedef void  (*FT_Raster_Span_Func)( int       y,                                        int       count,                                        FT_Span*  spans,                                        void*     user );  /*************************************************************************/  /*                                                                       */  /* <FuncType>                                                            */  /*    FT_Raster_BitTest_Func                                             */  /*                                                                       */  /* <Description>                                                         */  /*    A function used as a call-back by the monochrome scan-converter    */  /*    to test whether a given target pixel is already set to the drawing */  /*    `color'.  These tests are crucial to implement drop-out control    */  /*    per-se the TrueType spec.                                          */  /*                                                                       */  /* <Input>                                                               */  /*    y     :: The pixel's y-coordinate.                                 */  /*                                                                       */  /*    x     :: The pixel's x-coordinate.                                 */  /*                                                                       */  /*    user  :: User-supplied data that is passed to the callback.        */  /*                                                                       */  /* <Return>                                                              */  /*   1 if the pixel is `set', 0 otherwise.                               */  /*                                                                       */  typedef int  (*FT_Raster_BitTest_Func)( int    y,                                          int    x,                                          void*  user );  /*************************************************************************/  /*                                                                       */  /* <FuncType>                                                            */  /*    FT_Raster_BitSet_Func                                              */  /*                                                                       */  /* <Description>                                                         */  /*    A function used as a call-back by the monochrome scan-converter    */  /*    to set an individual target pixel.  This is crucial to implement   */  /*    drop-out control according to the TrueType specification.          */  /*                                                                       */  /* <Input>                                                               */  /*    y     :: The pixel's y-coordinate.                                 */  /*                                                                       */  /*    x     :: The pixel's x-coordinate.                                 */  /*                                                                       */  /*    user  :: User-supplied data that is passed to the callback.        */  /*                                                                       */  /* <Return>                                                              */  /*    1 if the pixel is `set', 0 otherwise.                              */  /*                                                                       */  typedef void  (*FT_Raster_BitSet_Func)( int    y,                                          int    x,                                          void*  user );  /*************************************************************************/  /*                                                                       */  /* <Enum>                                                                */  /*    FT_Raster_Flag                                                     */  /*                                                                       */  /* <Description>                                                         */  /*    An enumeration to list the bit flags as used in the `flags' field  */  /*    of a FT_Raster_Params structure.                                   */  /*                                                                       */  /* <Fields>                                                              */  /*    ft_raster_flag_default :: This value is 0.                         */  /*                                                                       */  /*    ft_raster_flag_aa      :: Requests the rendering of an             */  /*                              anti-aliased glyph bitmap.  If unset, a  */  /*                              monchrome bitmap will be rendered.       */  /*                                                                       */  /*    ft_raster_flag_direct  :: Requests direct rendering over the       */  /*                              target bitmap.  Direct rendering uses    */  /*                              user-provided callbacks in order to      */  /*                              perform direct drawing or composition    */  /*                              over an existing bitmap.  If this bit is */  /*                              unset, the content of the target bitmap  */  /*                              *must be zeroed*!                        */  /*                                                                       */  typedef  enum  {    ft_raster_flag_default = 0,    ft_raster_flag_aa      = 1,    ft_raster_flag_direct  = 2  } FT_Raster_Flag;  /*************************************************************************/  /*                                                                       */  /* <Struct>                                                              */  /*    FT_Raster_Params                                                   */  /*                                                                       */  /* <Description>                                                         */  /*    A structure to hold the arguments used by a raster's render        */  /*    function.                                                          */  /*                                                                       */  /* <Fields>                                                              */  /*    target      :: The target bitmap.                                  */  /*                                                                       */  /*    source      :: A pointer to the source glyph image (e.g. an        */  /*                   FT_Outline).                                        */  /*                                                                       */  /*    flags       :: The rendering flags.                                */  /*                                                                       */  /*    gray_spans  :: The gray span drawing callback.                     */  /*                                                                       */  /*    black_spans :: The black span drawing callback.                    */  /*                                                                       */  /*    bit_test    :: The bit test callback.                              */  /*                                                                       */  /*    bit_set     :: The bit set callback.                               */  /*                                                                       */  /*    user        :: User-supplied data that is passed to each drawing   */  /*                   callback.                                           */  /*                                                                       */  /* <Note>                                                                */  /*    An anti-aliased glyph bitmap is drawn if the ft_raster_flag_aa bit */  /*    flag is set in the `flags' field, otherwise a monochrome bitmap    */  /*    will be generated.                                                 */

⌨️ 快捷键说明

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