svmm.h

Go to the documentation of this file.
00001 /***************************************************************************/
00002 /*                                                                         */
00003 /*  svmm.h                                                                 */
00004 /*                                                                         */
00005 /*    The FreeType Multiple Masters and GX var services (specification).   */
00006 /*                                                                         */
00007 /*  Copyright 2003, 2004 by                                                */
00008 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
00009 /*                                                                         */
00010 /*  This file is part of the FreeType project, and may only be used,       */
00011 /*  modified, and distributed under the terms of the FreeType project      */
00012 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
00013 /*  this file you indicate that you have read the license and              */
00014 /*  understand and accept it fully.                                        */
00015 /*                                                                         */
00016 /***************************************************************************/
00017 
00018 
00019 #ifndef __SVMM_H__
00020 #define __SVMM_H__
00021 
00022 #include FT_INTERNAL_SERVICE_H
00023 
00024 
00025 FT_BEGIN_HEADER
00026 
00027 
00028   /*
00029    *  A service used to manage multiple-masters data in a given face.
00030    *
00031    *  See the related APIs in `ftmm.h' (FT_MULTIPLE_MASTERS_H).
00032    *
00033    */
00034 
00035 #define FT_SERVICE_ID_MULTI_MASTERS  "multi-masters"
00036 
00037 
00038   typedef FT_Error
00039   (*FT_Get_MM_Func)( FT_Face           face,
00040                      FT_Multi_Master*  master );
00041 
00042   typedef FT_Error
00043   (*FT_Get_MM_Var_Func)( FT_Face      face,
00044                          FT_MM_Var*  *master );
00045 
00046   typedef FT_Error
00047   (*FT_Set_MM_Design_Func)( FT_Face   face,
00048                             FT_UInt   num_coords,
00049                             FT_Long*  coords );
00050 
00051   typedef FT_Error
00052   (*FT_Set_Var_Design_Func)( FT_Face    face,
00053                              FT_UInt    num_coords,
00054                              FT_Fixed*  coords );
00055 
00056   typedef FT_Error
00057   (*FT_Set_MM_Blend_Func)( FT_Face   face,
00058                            FT_UInt   num_coords,
00059                            FT_Long*  coords );
00060 
00061 
00062   FT_DEFINE_SERVICE( MultiMasters )
00063   {
00064     FT_Get_MM_Func          get_mm;
00065     FT_Set_MM_Design_Func   set_mm_design;
00066     FT_Set_MM_Blend_Func    set_mm_blend;
00067     FT_Get_MM_Var_Func      get_mm_var;
00068     FT_Set_Var_Design_Func  set_var_design;
00069   };
00070 
00071 #ifndef FT_CONFIG_OPTION_PIC
00072 
00073 #define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_,   \
00074         set_mm_blend_, get_mm_var_, set_var_design_)                         \
00075   static const FT_Service_MultiMastersRec class_ =                           \
00076   {                                                                          \
00077     get_mm_, set_mm_design_, set_mm_blend_, get_mm_var_, set_var_design_     \
00078   };
00079 
00080 #else /* FT_CONFIG_OPTION_PIC */ 
00081 
00082 #define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_,   \
00083         set_mm_blend_, get_mm_var_, set_var_design_)                         \
00084   void                                                                       \
00085   FT_Init_Class_##class_( FT_Service_MultiMastersRec*  clazz )               \
00086   {                                                                          \
00087     clazz->get_mm = get_mm_;                                                 \
00088     clazz->set_mm_design = set_mm_design_;                                   \
00089     clazz->set_mm_blend = set_mm_blend_;                                     \
00090     clazz->get_mm_var = get_mm_var_;                                         \
00091     clazz->set_var_design = set_var_design_;                                 \
00092   } 
00093 
00094 #endif /* FT_CONFIG_OPTION_PIC */ 
00095 
00096   /* */
00097 
00098 
00099 FT_END_HEADER
00100 
00101 #endif /* __SVMM_H__ */
00102 
00103 
00104 /* END */

Generated on Tue Jul 5 14:13:40 2011 for ROOT_528-00b_version by  doxygen 1.5.1