Blame include/freetype/ftbzip2.h

Packit cf904d
/***************************************************************************/
Packit cf904d
/*                                                                         */
Packit cf904d
/*  ftbzip2.h                                                              */
Packit cf904d
/*                                                                         */
Packit cf904d
/*    Bzip2-compressed stream support.                                     */
Packit cf904d
/*                                                                         */
Packit cf904d
/*  Copyright 2010-2017 by                                                 */
Packit cf904d
/*  Joel Klinghed.                                                         */
Packit cf904d
/*                                                                         */
Packit cf904d
/*  This file is part of the FreeType project, and may only be used,       */
Packit cf904d
/*  modified, and distributed under the terms of the FreeType project      */
Packit cf904d
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
Packit cf904d
/*  this file you indicate that you have read the license and              */
Packit cf904d
/*  understand and accept it fully.                                        */
Packit cf904d
/*                                                                         */
Packit cf904d
/***************************************************************************/
Packit cf904d
Packit cf904d
Packit cf904d
#ifndef FTBZIP2_H_
Packit cf904d
#define FTBZIP2_H_
Packit cf904d
Packit cf904d
#include <ft2build.h>
Packit cf904d
#include FT_FREETYPE_H
Packit cf904d
Packit cf904d
#ifdef FREETYPE_H
Packit cf904d
#error "freetype.h of FreeType 1 has been loaded!"
Packit cf904d
#error "Please fix the directory search order for header files"
Packit cf904d
#error "so that freetype.h of FreeType 2 is found first."
Packit cf904d
#endif
Packit cf904d
Packit cf904d
Packit cf904d
FT_BEGIN_HEADER
Packit cf904d
Packit cf904d
  /*************************************************************************/
Packit cf904d
  /*                                                                       */
Packit cf904d
  /* <Section>                                                             */
Packit cf904d
  /*    bzip2                                                              */
Packit cf904d
  /*                                                                       */
Packit cf904d
  /* <Title>                                                               */
Packit cf904d
  /*    BZIP2 Streams                                                      */
Packit cf904d
  /*                                                                       */
Packit cf904d
  /* <Abstract>                                                            */
Packit cf904d
  /*    Using bzip2-compressed font files.                                 */
Packit cf904d
  /*                                                                       */
Packit cf904d
  /* <Description>                                                         */
Packit cf904d
  /*    This section contains the declaration of Bzip2-specific functions. */
Packit cf904d
  /*                                                                       */
Packit cf904d
  /*************************************************************************/
Packit cf904d
Packit cf904d
Packit cf904d
 /************************************************************************
Packit cf904d
  *
Packit cf904d
  * @function:
Packit cf904d
  *   FT_Stream_OpenBzip2
Packit cf904d
  *
Packit cf904d
  * @description:
Packit cf904d
  *   Open a new stream to parse bzip2-compressed font files.  This is
Packit cf904d
  *   mainly used to support the compressed `*.pcf.bz2' fonts that come
Packit cf904d
  *   with XFree86.
Packit cf904d
  *
Packit cf904d
  * @input:
Packit cf904d
  *   stream ::
Packit cf904d
  *     The target embedding stream.
Packit cf904d
  *
Packit cf904d
  *   source ::
Packit cf904d
  *     The source stream.
Packit cf904d
  *
Packit cf904d
  * @return:
Packit cf904d
  *   FreeType error code.  0~means success.
Packit cf904d
  *
Packit cf904d
  * @note:
Packit cf904d
  *   The source stream must be opened _before_ calling this function.
Packit cf904d
  *
Packit cf904d
  *   Calling the internal function `FT_Stream_Close' on the new stream will
Packit cf904d
  *   *not* call `FT_Stream_Close' on the source stream.  None of the stream
Packit cf904d
  *   objects will be released to the heap.
Packit cf904d
  *
Packit cf904d
  *   The stream implementation is very basic and resets the decompression
Packit cf904d
  *   process each time seeking backwards is needed within the stream.
Packit cf904d
  *
Packit cf904d
  *   In certain builds of the library, bzip2 compression recognition is
Packit cf904d
  *   automatically handled when calling @FT_New_Face or @FT_Open_Face.
Packit cf904d
  *   This means that if no font driver is capable of handling the raw
Packit cf904d
  *   compressed file, the library will try to open a bzip2 compressed stream
Packit cf904d
  *   from it and re-open the face with it.
Packit cf904d
  *
Packit cf904d
  *   This function may return `FT_Err_Unimplemented_Feature' if your build
Packit cf904d
  *   of FreeType was not compiled with bzip2 support.
Packit cf904d
  */
Packit cf904d
  FT_EXPORT( FT_Error )
Packit cf904d
  FT_Stream_OpenBzip2( FT_Stream  stream,
Packit cf904d
                       FT_Stream  source );
Packit cf904d
Packit cf904d
  /* */
Packit cf904d
Packit cf904d
Packit cf904d
FT_END_HEADER
Packit cf904d
Packit cf904d
#endif /* FTBZIP2_H_ */
Packit cf904d
Packit cf904d
Packit cf904d
/* END */