zenilib: zenilib/jni/external/freetype2/src/gxvalid/gxvmod.c File Reference

zenilib 0.5.3.0

- Main Page
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Macros | Functions | Variables
gxvmod.c File Reference
`#include <ft2build.h>`
`#include <FT_TRUETYPE_TABLES_H>`
`#include <FT_TRUETYPE_TAGS_H>`
`#include <FT_GX_VALIDATE_H>`
`#include <FT_INTERNAL_OBJECTS_H>`
`#include <FT_SERVICE_GX_VALIDATE_H>`
`#include "gxvmod.h"`
`#include "gxvalid.h"`
`#include "gxvcommn.h"`

Go to the source code of this file.

## Macros

#define | FT_COMPONENT trace_gxvmodule
#define | GXV_TABLE_DECL(_sfnt)
#define | GXV_TABLE_LOAD(_sfnt)
#define | GXV_TABLE_SET(_sfnt)
#define | GXV_TABLE_VALIDATE(_sfnt)

## Functions

static FT_Error | classic_kern_validate (FT_Face face, FT_UInt ckern_flags, FT_Bytes *ckern_table)
static FT_Error | gxv_load_table (FT_Face face, FT_Tag tag, FT_Byte *volatile *table, FT_ULong *table_len)
static FT_Error | gxv_validate (FT_Face face, FT_UInt gx_flags, FT_Bytes tables[FT_VALIDATE_GX_LENGTH], FT_UInt table_count)
static FT_Pointer | gxvalid_get_service (FT_Module module, const char *service_id)

## Variables

static const FT_Service_CKERNvalidateRec | ckernvalid_interface
FT_CALLBACK_TABLE_DEF const FT_Module_Class | gxv_module_class
static const FT_Service_GXvalidateRec | gxvalid_interface
static const FT_ServiceDescRec | gxvalid_services []

## Macro Definition Documentation

#define FT_COMPONENT trace_gxvmodule

Definition at line 47 of file gxvmod.c.

#define GXV_TABLE_DECL | ( |  | _sfnt | ) |

Value:
FT_Byte* volatile _sfnt = NULL; \
FT_ULong len_ ## _sfnt = 0
FT_ULong
unsigned long FT_ULong
Definition: fttypes.h:249
NULL
#define NULL
Definition: ftobjs.h:61
FT_Byte
unsigned char FT_Byte
Definition: fttypes.h:150

Definition at line 76 of file gxvmod.c.

Referenced by gxv_validate().

#define GXV_TABLE_LOAD | ( |  | _sfnt | ) |

Value:
if ( ( FT_VALIDATE_ ## _sfnt ## _INDEX < table_count ) && \
( gx_flags & FT_VALIDATE_ ## _sfnt ) ) \
{ \
error = gxv_load_table( face, TTAG_ ## _sfnt, \
&_sfnt, &len_ ## _sfnt ); \
if ( error ) \
goto Exit; \
}
if
if(!yyg->yy_init)
Definition: glslang_lex.cpp:1037
error
FT_Error error
Definition: cffdrivr.c:407
face
GLenum face
Definition: gl2ext.h:1490
gxv_load_table
static FT_Error gxv_load_table(FT_Face face, FT_Tag tag, FT_Byte *volatile *table, FT_ULong *table_len)
Definition: gxvmod.c:51

Definition at line 80 of file gxvmod.c.

Referenced by gxv_validate().

#define GXV_TABLE_SET | ( |  | _sfnt | ) |

Value:
if ( FT_VALIDATE_ ## _sfnt ## _INDEX < table_count ) \
tables[FT_VALIDATE_ ## _sfnt ## _INDEX] = (FT_Bytes)_sfnt
FT_Bytes
const FT_Byte * FT_Bytes
Definition: fttypes.h:161

Definition at line 102 of file gxvmod.c.

Referenced by gxv_validate().

#define GXV_TABLE_VALIDATE | ( |  | _sfnt | ) |

Value:
if ( _sfnt ) \
{ \
ft_validator_init( &valid, _sfnt, _sfnt + len_ ## _sfnt, \
FT_VALIDATE_DEFAULT ); \
if ( ft_setjmp( valid.jump_buffer ) == 0 ) \
gxv_ ## _sfnt ## _validate( _sfnt, face, &valid ); \
error = valid.error; \
if ( error ) \
goto Exit; \
}
if
if(!yyg->yy_init)
Definition: glslang_lex.cpp:1037
error
FT_Error error
Definition: cffdrivr.c:407
face
GLenum face
Definition: gl2ext.h:1490
ft_setjmp
#define ft_setjmp(b)
Definition: ftstdlib.h:162
FT_VALIDATE_DEFAULT
Definition: ftvalid.h:72
ft_validator_init
ft_validator_init(FT_Validator valid, const FT_Byte *base, const FT_Byte *limit, FT_ValidationLevel level)
Definition: ftobjs.c:71

Definition at line 90 of file gxvmod.c.

Referenced by gxv_validate().

## Function Documentation

static FT_Error classic_kern_validate | ( | FT_Face | face,
|  | FT_UInt | ckern_flags,
|  | FT_Bytes * | ckern_table
| ) |  |

static

Definition at line 191 of file gxvmod.c.

References FT_ValidatorRec_::error, error, FT_FACE_MEMORY, FT_FREE, ft_setjmp, FT_VALIDATE_CKERN, FT_VALIDATE_DEFAULT, ft_validator_init(), gxv_kern_validate_classic(), gxv_load_table(), FT_ValidatorRec_::jump_buffer, NULL, and TTAG_kern.

static FT_Error gxv_load_table | ( | FT_Face | face,
|  | FT_Tag | tag,
|  | FT_Byte *volatile * | table,
|  | FT_ULong * | table_len
| ) |  |

static

Definition at line 51 of file gxvmod.c.

References error, FT_ALLOC, FT_FACE_MEMORY, FT_Load_Sfnt_Table(), and NULL.

Referenced by classic_kern_validate().

static FT_Error gxv_validate | ( | FT_Face | face,
|  | FT_UInt | gx_flags,
|  | FT_Bytes | tables[FT_VALIDATE_GX_LENGTH],
|  | FT_UInt | table_count
| ) |  |

static

Definition at line 108 of file gxvmod.c.

References error, FT_FACE_MEMORY, FT_FREE, GXV_TABLE_DECL, GXV_TABLE_LOAD, GXV_TABLE_SET, GXV_TABLE_VALIDATE, and i.

static FT_Pointer gxvalid_get_service | ( | FT_Module | module,
|  | const char * | service_id
| ) |  |

static

Definition at line 259 of file gxvmod.c.

References ft_service_list_lookup(), and FT_UNUSED.

## Variable Documentation

const FT_Service_CKERNvalidateRec ckernvalid_interface

static

Initial value:
=
{
classic_kern_validate
}
classic_kern_validate
static FT_Error classic_kern_validate(FT_Face face, FT_UInt ckern_flags, FT_Bytes *ckern_table)
Definition: gxvmod.c:191

Definition at line 243 of file gxvmod.c.

FT_CALLBACK_TABLE_DEF const FT_Module_Class gxv_module_class

Initial value:
=
{
0,
sizeof ( FT_ModuleRec ),
"gxvalid",
0x10000L,
0x20000L,
0,
(FT_Module_Constructor)0,
(FT_Module_Destructor) 0,
(FT_Module_Requester) gxvalid_get_service
}
gxvalid_get_service
static FT_Pointer gxvalid_get_service(FT_Module module, const char *service_id)
Definition: gxvmod.c:259
FT_Module_Requester
FT_Module_Interface(* FT_Module_Requester)(FT_Module module, const char *name)
Definition: ftmodapi.h:126
FT_ModuleRec
struct FT_ModuleRec_ FT_ModuleRec
FT_Module_Destructor
void(* FT_Module_Destructor)(FT_Module module)
Definition: ftmodapi.h:109
FT_Module_Constructor
FT_Error(* FT_Module_Constructor)(FT_Module module)
Definition: ftmodapi.h:94

Definition at line 269 of file gxvmod.c.

const FT_Service_GXvalidateRec gxvalid_interface

static

Initial value:
=
{
gxv_validate
}
gxv_validate
static FT_Error gxv_validate(FT_Face face, FT_UInt gx_flags, FT_Bytes tables[FT_VALIDATE_GX_LENGTH], FT_UInt table_count)
Definition: gxvmod.c:108

Definition at line 236 of file gxvmod.c.

const FT_ServiceDescRec gxvalid_services[]

static

Initial value:
=
{
{ FT_SERVICE_ID_GX_VALIDATE, &gxvalid_interface },
{ FT_SERVICE_ID_CLASSICKERN_VALIDATE, &ckernvalid_interface },
{ NULL, NULL }
}
NULL
#define NULL
Definition: ftobjs.h:61
ckernvalid_interface
static const FT_Service_CKERNvalidateRec ckernvalid_interface
Definition: gxvmod.c:243
FT_SERVICE_ID_CLASSICKERN_VALIDATE
#define FT_SERVICE_ID_CLASSICKERN_VALIDATE
Definition: svgxval.h:38
FT_SERVICE_ID_GX_VALIDATE
#define FT_SERVICE_ID_GX_VALIDATE
Definition: svgxval.h:37
gxvalid_interface
static const FT_Service_GXvalidateRec gxvalid_interface
Definition: gxvmod.c:236

Definition at line 250 of file gxvmod.c.