godot/thirdparty/freetype/src/sfnt/sfwoff2.h

/****************************************************************************
 *
 * sfwoff2.h
 *
 *   WOFFF2 format management (specification).
 *
 * Copyright (C) 2019-2023 by
 * Nikhil Ramakrishnan, David Turner, Robert Wilhelm, and Werner Lemberg.
 *
 * This file is part of the FreeType project, and may only be used,
 * modified, and distributed under the terms of the FreeType project
 * license, LICENSE.TXT.  By continuing to use, modify, or distribute
 * this file you indicate that you have read the license and
 * understand and accept it fully.
 *
 */


#ifndef SFWOFF2_H_
#define SFWOFF2_H_


#include <freetype/internal/sfnt.h>
#include <freetype/internal/ftobjs.h>


FT_BEGIN_HEADER

#ifdef FT_CONFIG_OPTION_USE_BROTLI

  /* Leave the first byte open to store `flag_byte'. */
#define WOFF2_FLAGS_TRANSFORM

#define WOFF2_SFNT_HEADER_SIZE
#define WOFF2_SFNT_ENTRY_SIZE

  /* Suggested maximum size for output. */
#define WOFF2_DEFAULT_MAX_SIZE

  /* 98% of Google Fonts have no glyph above 5k bytes. */
#define WOFF2_DEFAULT_GLYPH_BUF

  /* Composite glyph flags.                                      */
  /* See `CompositeGlyph.java' in `sfntly' for full definitions. */
#define FLAG_ARG_1_AND_2_ARE_WORDS
#define FLAG_WE_HAVE_A_SCALE
#define FLAG_MORE_COMPONENTS
#define FLAG_WE_HAVE_AN_X_AND_Y_SCALE
#define FLAG_WE_HAVE_A_TWO_BY_TWO
#define FLAG_WE_HAVE_INSTRUCTIONS

  /* Simple glyph flags */
#define GLYF_ON_CURVE
#define GLYF_X_SHORT
#define GLYF_Y_SHORT
#define GLYF_REPEAT
#define GLYF_THIS_X_IS_SAME
#define GLYF_THIS_Y_IS_SAME
#define GLYF_OVERLAP_SIMPLE

  /* Other constants */
#define CONTOUR_OFFSET_END_POINT


  FT_LOCAL( FT_Error )
  woff2_open_font( FT_Stream  stream,
                   TT_Face    face,
                   FT_Int*    face_index,
                   FT_Long*   num_faces );

#endif /* FT_CONFIG_OPTION_USE_BROTLI */

FT_END_HEADER

#endif /* SFWOFF2_H_ */


/* END */