🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1336 lines
30 KiB

  1. <!doctype html>
  2. <html lang="en" class="no-js">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width,initial-scale=1">
  6. <meta name="description" content="API Reference Documentation for FreeType-2.11.0">
  7. <meta name="author" content="FreeType Contributors">
  8. <link rel="icon" href="images/favico.ico">
  9. <meta name="generator" content="mkdocs-1.2.1, mkdocs-material-7.1.9">
  10. <title>GZIP Streams - FreeType-2.11.0 API Reference</title>
  11. <link rel="stylesheet" href="assets/stylesheets/main.ca7ac06f.min.css">
  12. <link rel="stylesheet" href="assets/stylesheets/palette.f1a3b89f.min.css">
  13. <meta name="theme-color" content="#4cae4f">
  14. <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  15. <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Noto+Serif:300,400,400i,700%7CRoboto+Mono&display=fallback">
  16. <style>:root{--md-text-font-family:"Noto Serif";--md-code-font-family:"Roboto Mono"}</style>
  17. <link rel="stylesheet" href="stylesheets/extra.css">
  18. </head>
  19. <body dir="ltr" data-md-color-scheme="" data-md-color-primary="green" data-md-color-accent="green">
  20. <script>function __prefix(e){return new URL(".",location).pathname+"."+e}function __get(e,t=localStorage){return JSON.parse(t.getItem(__prefix(e)))}</script>
  21. <input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
  22. <input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
  23. <label class="md-overlay" for="__drawer"></label>
  24. <div data-md-component="skip">
  25. <a href="#gzip-streams" class="md-skip">
  26. Skip to content
  27. </a>
  28. </div>
  29. <div data-md-component="announce">
  30. </div>
  31. <header class="md-header" data-md-component="header">
  32. <nav class="md-header__inner md-grid" aria-label="Header">
  33. <a href="index.html" title="FreeType-2.11.0 API Reference" class="md-header__button md-logo" aria-label="FreeType-2.11.0 API Reference" data-md-component="logo">
  34. <img src="images/favico.ico" alt="logo">
  35. </a>
  36. <label class="md-header__button md-icon" for="__drawer">
  37. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M3 6h18v2H3V6m0 5h18v2H3v-2m0 5h18v2H3v-2z"/></svg>
  38. </label>
  39. <div class="md-header__title" data-md-component="header-title">
  40. <div class="md-header__ellipsis">
  41. <div class="md-header__topic">
  42. <span class="md-ellipsis">
  43. FreeType-2.11.0 API Reference
  44. </span>
  45. </div>
  46. <div class="md-header__topic" data-md-component="header-topic">
  47. <span class="md-ellipsis">
  48. GZIP Streams
  49. </span>
  50. </div>
  51. </div>
  52. </div>
  53. <label class="md-header__button md-icon" for="__search">
  54. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9.5 3A6.5 6.5 0 0 1 16 9.5c0 1.61-.59 3.09-1.56 4.23l.27.27h.79l5 5-1.5 1.5-5-5v-.79l-.27-.27A6.516 6.516 0 0 1 9.5 16 6.5 6.5 0 0 1 3 9.5 6.5 6.5 0 0 1 9.5 3m0 2C7 5 5 7 5 9.5S7 14 9.5 14 14 12 14 9.5 12 5 9.5 5z"/></svg>
  55. </label>
  56. <div class="md-search" data-md-component="search" role="dialog">
  57. <label class="md-search__overlay" for="__search"></label>
  58. <div class="md-search__inner" role="search">
  59. <form class="md-search__form" name="search">
  60. <input type="text" class="md-search__input" name="query" aria-label="Search" placeholder="Search" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="search-query" data-md-state="active" required>
  61. <label class="md-search__icon md-icon" for="__search">
  62. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9.5 3A6.5 6.5 0 0 1 16 9.5c0 1.61-.59 3.09-1.56 4.23l.27.27h.79l5 5-1.5 1.5-5-5v-.79l-.27-.27A6.516 6.516 0 0 1 9.5 16 6.5 6.5 0 0 1 3 9.5 6.5 6.5 0 0 1 9.5 3m0 2C7 5 5 7 5 9.5S7 14 9.5 14 14 12 14 9.5 12 5 9.5 5z"/></svg>
  63. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11h12z"/></svg>
  64. </label>
  65. <button type="reset" class="md-search__icon md-icon" aria-label="Clear" tabindex="-1">
  66. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"/></svg>
  67. </button>
  68. </form>
  69. <div class="md-search__output">
  70. <div class="md-search__scrollwrap" data-md-scrollfix>
  71. <div class="md-search-result" data-md-component="search-result">
  72. <div class="md-search-result__meta">
  73. Initializing search
  74. </div>
  75. <ol class="md-search-result__list"></ol>
  76. </div>
  77. </div>
  78. </div>
  79. </div>
  80. </div>
  81. </nav>
  82. </header>
  83. <div class="md-container" data-md-component="container">
  84. <main class="md-main" data-md-component="main">
  85. <div class="md-main__inner md-grid">
  86. <div class="md-sidebar md-sidebar--primary" data-md-component="sidebar" data-md-type="navigation" >
  87. <div class="md-sidebar__scrollwrap">
  88. <div class="md-sidebar__inner">
  89. <nav class="md-nav md-nav--primary" aria-label="Navigation" data-md-level="0">
  90. <label class="md-nav__title" for="__drawer">
  91. <a href="index.html" title="FreeType-2.11.0 API Reference" class="md-nav__button md-logo" aria-label="FreeType-2.11.0 API Reference" data-md-component="logo">
  92. <img src="images/favico.ico" alt="logo">
  93. </a>
  94. FreeType-2.11.0 API Reference
  95. </label>
  96. <ul class="md-nav__list" data-md-scrollfix>
  97. <li class="md-nav__item">
  98. <a href="index.html" class="md-nav__link">
  99. TOC
  100. </a>
  101. </li>
  102. <li class="md-nav__item">
  103. <a href="ft2-index.html" class="md-nav__link">
  104. Index
  105. </a>
  106. </li>
  107. <li class="md-nav__item md-nav__item--nested">
  108. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_3" type="checkbox" id="__nav_3" >
  109. <label class="md-nav__link" for="__nav_3">
  110. General Remarks
  111. <span class="md-nav__icon md-icon"></span>
  112. </label>
  113. <nav class="md-nav" aria-label="General Remarks" data-md-level="1">
  114. <label class="md-nav__title" for="__nav_3">
  115. <span class="md-nav__icon md-icon"></span>
  116. General Remarks
  117. </label>
  118. <ul class="md-nav__list" data-md-scrollfix>
  119. <li class="md-nav__item">
  120. <a href="ft2-preamble.html" class="md-nav__link">
  121. Preamble
  122. </a>
  123. </li>
  124. <li class="md-nav__item">
  125. <a href="ft2-header_inclusion.html" class="md-nav__link">
  126. FreeType's header inclusion scheme
  127. </a>
  128. </li>
  129. <li class="md-nav__item">
  130. <a href="ft2-user_allocation.html" class="md-nav__link">
  131. User allocation
  132. </a>
  133. </li>
  134. </ul>
  135. </nav>
  136. </li>
  137. <li class="md-nav__item md-nav__item--nested">
  138. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_4" type="checkbox" id="__nav_4" >
  139. <label class="md-nav__link" for="__nav_4">
  140. Core API
  141. <span class="md-nav__icon md-icon"></span>
  142. </label>
  143. <nav class="md-nav" aria-label="Core API" data-md-level="1">
  144. <label class="md-nav__title" for="__nav_4">
  145. <span class="md-nav__icon md-icon"></span>
  146. Core API
  147. </label>
  148. <ul class="md-nav__list" data-md-scrollfix>
  149. <li class="md-nav__item">
  150. <a href="ft2-version.html" class="md-nav__link">
  151. FreeType Version
  152. </a>
  153. </li>
  154. <li class="md-nav__item">
  155. <a href="ft2-basic_types.html" class="md-nav__link">
  156. Basic Data Types
  157. </a>
  158. </li>
  159. <li class="md-nav__item">
  160. <a href="ft2-base_interface.html" class="md-nav__link">
  161. Base Interface
  162. </a>
  163. </li>
  164. <li class="md-nav__item">
  165. <a href="ft2-glyph_variants.html" class="md-nav__link">
  166. Unicode Variation Sequences
  167. </a>
  168. </li>
  169. <li class="md-nav__item">
  170. <a href="ft2-color_management.html" class="md-nav__link">
  171. Glyph Color Management
  172. </a>
  173. </li>
  174. <li class="md-nav__item">
  175. <a href="ft2-layer_management.html" class="md-nav__link">
  176. Glyph Layer Management
  177. </a>
  178. </li>
  179. <li class="md-nav__item">
  180. <a href="ft2-glyph_management.html" class="md-nav__link">
  181. Glyph Management
  182. </a>
  183. </li>
  184. <li class="md-nav__item">
  185. <a href="ft2-mac_specific.html" class="md-nav__link">
  186. Mac Specific Interface
  187. </a>
  188. </li>
  189. <li class="md-nav__item">
  190. <a href="ft2-sizes_management.html" class="md-nav__link">
  191. Size Management
  192. </a>
  193. </li>
  194. <li class="md-nav__item">
  195. <a href="ft2-header_file_macros.html" class="md-nav__link">
  196. Header File Macros
  197. </a>
  198. </li>
  199. </ul>
  200. </nav>
  201. </li>
  202. <li class="md-nav__item md-nav__item--nested">
  203. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_5" type="checkbox" id="__nav_5" >
  204. <label class="md-nav__link" for="__nav_5">
  205. Format-Specific API
  206. <span class="md-nav__icon md-icon"></span>
  207. </label>
  208. <nav class="md-nav" aria-label="Format-Specific API" data-md-level="1">
  209. <label class="md-nav__title" for="__nav_5">
  210. <span class="md-nav__icon md-icon"></span>
  211. Format-Specific API
  212. </label>
  213. <ul class="md-nav__list" data-md-scrollfix>
  214. <li class="md-nav__item">
  215. <a href="ft2-multiple_masters.html" class="md-nav__link">
  216. Multiple Masters
  217. </a>
  218. </li>
  219. <li class="md-nav__item">
  220. <a href="ft2-truetype_tables.html" class="md-nav__link">
  221. TrueType Tables
  222. </a>
  223. </li>
  224. <li class="md-nav__item">
  225. <a href="ft2-type1_tables.html" class="md-nav__link">
  226. Type 1 Tables
  227. </a>
  228. </li>
  229. <li class="md-nav__item">
  230. <a href="ft2-sfnt_names.html" class="md-nav__link">
  231. SFNT Names
  232. </a>
  233. </li>
  234. <li class="md-nav__item">
  235. <a href="ft2-bdf_fonts.html" class="md-nav__link">
  236. BDF and PCF Files
  237. </a>
  238. </li>
  239. <li class="md-nav__item">
  240. <a href="ft2-cid_fonts.html" class="md-nav__link">
  241. CID Fonts
  242. </a>
  243. </li>
  244. <li class="md-nav__item">
  245. <a href="ft2-pfr_fonts.html" class="md-nav__link">
  246. PFR Fonts
  247. </a>
  248. </li>
  249. <li class="md-nav__item">
  250. <a href="ft2-winfnt_fonts.html" class="md-nav__link">
  251. Window FNT Files
  252. </a>
  253. </li>
  254. <li class="md-nav__item">
  255. <a href="ft2-font_formats.html" class="md-nav__link">
  256. Font Formats
  257. </a>
  258. </li>
  259. <li class="md-nav__item">
  260. <a href="ft2-gasp_table.html" class="md-nav__link">
  261. Gasp Table
  262. </a>
  263. </li>
  264. </ul>
  265. </nav>
  266. </li>
  267. <li class="md-nav__item md-nav__item--nested">
  268. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_6" type="checkbox" id="__nav_6" >
  269. <label class="md-nav__link" for="__nav_6">
  270. Controlling FreeType Modules
  271. <span class="md-nav__icon md-icon"></span>
  272. </label>
  273. <nav class="md-nav" aria-label="Controlling FreeType Modules" data-md-level="1">
  274. <label class="md-nav__title" for="__nav_6">
  275. <span class="md-nav__icon md-icon"></span>
  276. Controlling FreeType Modules
  277. </label>
  278. <ul class="md-nav__list" data-md-scrollfix>
  279. <li class="md-nav__item">
  280. <a href="ft2-auto_hinter.html" class="md-nav__link">
  281. The auto-hinter
  282. </a>
  283. </li>
  284. <li class="md-nav__item">
  285. <a href="ft2-cff_driver.html" class="md-nav__link">
  286. The CFF driver
  287. </a>
  288. </li>
  289. <li class="md-nav__item">
  290. <a href="ft2-t1_cid_driver.html" class="md-nav__link">
  291. The Type 1 and CID drivers
  292. </a>
  293. </li>
  294. <li class="md-nav__item">
  295. <a href="ft2-tt_driver.html" class="md-nav__link">
  296. The TrueType driver
  297. </a>
  298. </li>
  299. <li class="md-nav__item">
  300. <a href="ft2-pcf_driver.html" class="md-nav__link">
  301. The PCF driver
  302. </a>
  303. </li>
  304. <li class="md-nav__item">
  305. <a href="ft2-properties.html" class="md-nav__link">
  306. Driver properties
  307. </a>
  308. </li>
  309. <li class="md-nav__item">
  310. <a href="ft2-parameter_tags.html" class="md-nav__link">
  311. Parameter Tags
  312. </a>
  313. </li>
  314. <li class="md-nav__item">
  315. <a href="ft2-lcd_rendering.html" class="md-nav__link">
  316. Subpixel Rendering
  317. </a>
  318. </li>
  319. </ul>
  320. </nav>
  321. </li>
  322. <li class="md-nav__item md-nav__item--nested">
  323. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_7" type="checkbox" id="__nav_7" >
  324. <label class="md-nav__link" for="__nav_7">
  325. Cache Sub-System
  326. <span class="md-nav__icon md-icon"></span>
  327. </label>
  328. <nav class="md-nav" aria-label="Cache Sub-System" data-md-level="1">
  329. <label class="md-nav__title" for="__nav_7">
  330. <span class="md-nav__icon md-icon"></span>
  331. Cache Sub-System
  332. </label>
  333. <ul class="md-nav__list" data-md-scrollfix>
  334. <li class="md-nav__item">
  335. <a href="ft2-cache_subsystem.html" class="md-nav__link">
  336. Cache Sub-System
  337. </a>
  338. </li>
  339. </ul>
  340. </nav>
  341. </li>
  342. <li class="md-nav__item md-nav__item--active md-nav__item--nested">
  343. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_8" type="checkbox" id="__nav_8" checked>
  344. <label class="md-nav__link" for="__nav_8">
  345. Support API
  346. <span class="md-nav__icon md-icon"></span>
  347. </label>
  348. <nav class="md-nav" aria-label="Support API" data-md-level="1">
  349. <label class="md-nav__title" for="__nav_8">
  350. <span class="md-nav__icon md-icon"></span>
  351. Support API
  352. </label>
  353. <ul class="md-nav__list" data-md-scrollfix>
  354. <li class="md-nav__item">
  355. <a href="ft2-computations.html" class="md-nav__link">
  356. Computations
  357. </a>
  358. </li>
  359. <li class="md-nav__item">
  360. <a href="ft2-list_processing.html" class="md-nav__link">
  361. List Processing
  362. </a>
  363. </li>
  364. <li class="md-nav__item">
  365. <a href="ft2-outline_processing.html" class="md-nav__link">
  366. Outline Processing
  367. </a>
  368. </li>
  369. <li class="md-nav__item">
  370. <a href="ft2-quick_advance.html" class="md-nav__link">
  371. Quick retrieval of advance values
  372. </a>
  373. </li>
  374. <li class="md-nav__item">
  375. <a href="ft2-bitmap_handling.html" class="md-nav__link">
  376. Bitmap Handling
  377. </a>
  378. </li>
  379. <li class="md-nav__item">
  380. <a href="ft2-raster.html" class="md-nav__link">
  381. Scanline Converter
  382. </a>
  383. </li>
  384. <li class="md-nav__item">
  385. <a href="ft2-glyph_stroker.html" class="md-nav__link">
  386. Glyph Stroker
  387. </a>
  388. </li>
  389. <li class="md-nav__item">
  390. <a href="ft2-system_interface.html" class="md-nav__link">
  391. System Interface
  392. </a>
  393. </li>
  394. <li class="md-nav__item">
  395. <a href="ft2-module_management.html" class="md-nav__link">
  396. Module Management
  397. </a>
  398. </li>
  399. <li class="md-nav__item md-nav__item--active">
  400. <input class="md-nav__toggle md-toggle" data-md-toggle="toc" type="checkbox" id="__toc">
  401. <label class="md-nav__link md-nav__link--active" for="__toc">
  402. GZIP Streams
  403. <span class="md-nav__icon md-icon"></span>
  404. </label>
  405. <a href="ft2-gzip.html" class="md-nav__link md-nav__link--active">
  406. GZIP Streams
  407. </a>
  408. <nav class="md-nav md-nav--secondary" aria-label="Table of contents">
  409. <label class="md-nav__title" for="__toc">
  410. <span class="md-nav__icon md-icon"></span>
  411. Table of contents
  412. </label>
  413. <ul class="md-nav__list" data-md-component="toc" data-md-scrollfix>
  414. <li class="md-nav__item">
  415. <a href="#synopsis" class="md-nav__link">
  416. Synopsis
  417. </a>
  418. </li>
  419. <li class="md-nav__item">
  420. <a href="#ft_stream_opengzip" class="md-nav__link">
  421. FT_Stream_OpenGzip
  422. </a>
  423. </li>
  424. <li class="md-nav__item">
  425. <a href="#ft_gzip_uncompress" class="md-nav__link">
  426. FT_Gzip_Uncompress
  427. </a>
  428. </li>
  429. </ul>
  430. </nav>
  431. </li>
  432. <li class="md-nav__item">
  433. <a href="ft2-lzw.html" class="md-nav__link">
  434. LZW Streams
  435. </a>
  436. </li>
  437. <li class="md-nav__item">
  438. <a href="ft2-bzip2.html" class="md-nav__link">
  439. BZIP2 Streams
  440. </a>
  441. </li>
  442. <li class="md-nav__item">
  443. <a href="ft2-debugging_apis.html" class="md-nav__link">
  444. External Debugging APIs
  445. </a>
  446. </li>
  447. </ul>
  448. </nav>
  449. </li>
  450. <li class="md-nav__item md-nav__item--nested">
  451. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_9" type="checkbox" id="__nav_9" >
  452. <label class="md-nav__link" for="__nav_9">
  453. Error Codes
  454. <span class="md-nav__icon md-icon"></span>
  455. </label>
  456. <nav class="md-nav" aria-label="Error Codes" data-md-level="1">
  457. <label class="md-nav__title" for="__nav_9">
  458. <span class="md-nav__icon md-icon"></span>
  459. Error Codes
  460. </label>
  461. <ul class="md-nav__list" data-md-scrollfix>
  462. <li class="md-nav__item">
  463. <a href="ft2-error_enumerations.html" class="md-nav__link">
  464. Error Enumerations
  465. </a>
  466. </li>
  467. <li class="md-nav__item">
  468. <a href="ft2-error_code_values.html" class="md-nav__link">
  469. Error Code Values
  470. </a>
  471. </li>
  472. </ul>
  473. </nav>
  474. </li>
  475. <li class="md-nav__item md-nav__item--nested">
  476. <input class="md-nav__toggle md-toggle" data-md-toggle="__nav_10" type="checkbox" id="__nav_10" >
  477. <label class="md-nav__link" for="__nav_10">
  478. Miscellaneous
  479. <span class="md-nav__icon md-icon"></span>
  480. </label>
  481. <nav class="md-nav" aria-label="Miscellaneous" data-md-level="1">
  482. <label class="md-nav__title" for="__nav_10">
  483. <span class="md-nav__icon md-icon"></span>
  484. Miscellaneous
  485. </label>
  486. <ul class="md-nav__list" data-md-scrollfix>
  487. <li class="md-nav__item">
  488. <a href="ft2-gx_validation.html" class="md-nav__link">
  489. TrueTypeGX/AAT Validation
  490. </a>
  491. </li>
  492. <li class="md-nav__item">
  493. <a href="ft2-incremental.html" class="md-nav__link">
  494. Incremental Loading
  495. </a>
  496. </li>
  497. <li class="md-nav__item">
  498. <a href="ft2-truetype_engine.html" class="md-nav__link">
  499. The TrueType Engine
  500. </a>
  501. </li>
  502. <li class="md-nav__item">
  503. <a href="ft2-ot_validation.html" class="md-nav__link">
  504. OpenType Validation
  505. </a>
  506. </li>
  507. </ul>
  508. </nav>
  509. </li>
  510. </ul>
  511. </nav>
  512. </div>
  513. </div>
  514. </div>
  515. <div class="md-sidebar md-sidebar--secondary" data-md-component="sidebar" data-md-type="toc" >
  516. <div class="md-sidebar__scrollwrap">
  517. <div class="md-sidebar__inner">
  518. <nav class="md-nav md-nav--secondary" aria-label="Table of contents">
  519. <label class="md-nav__title" for="__toc">
  520. <span class="md-nav__icon md-icon"></span>
  521. Table of contents
  522. </label>
  523. <ul class="md-nav__list" data-md-component="toc" data-md-scrollfix>
  524. <li class="md-nav__item">
  525. <a href="#synopsis" class="md-nav__link">
  526. Synopsis
  527. </a>
  528. </li>
  529. <li class="md-nav__item">
  530. <a href="#ft_stream_opengzip" class="md-nav__link">
  531. FT_Stream_OpenGzip
  532. </a>
  533. </li>
  534. <li class="md-nav__item">
  535. <a href="#ft_gzip_uncompress" class="md-nav__link">
  536. FT_Gzip_Uncompress
  537. </a>
  538. </li>
  539. </ul>
  540. </nav>
  541. </div>
  542. </div>
  543. </div>
  544. <div class="md-content" data-md-component="content">
  545. <article class="md-content__inner md-typeset">
  546. <p><a href="https://www.freetype.org">FreeType</a> &raquo; <a href="../">Docs</a> &raquo; <a href="index.html#support-api">Support API</a> &raquo; GZIP Streams</p>
  547. <hr />
  548. <h1 id="gzip-streams">GZIP Streams<a class="headerlink" href="#gzip-streams" title="Permanent link">&para;</a></h1>
  549. <h2 id="synopsis">Synopsis<a class="headerlink" href="#synopsis" title="Permanent link">&para;</a></h2>
  550. <p>In certain builds of the library, gzip compression recognition is automatically handled when calling <code><a href="ft2-base_interface.html#ft_new_face">FT_New_Face</a></code> or <code><a href="ft2-base_interface.html#ft_open_face">FT_Open_Face</a></code>. This means that if no font driver is capable of handling the raw compressed file, the library will try to open a gzipped stream from it and re-open the face with it.</p>
  551. <p>The stream implementation is very basic and resets the decompression process each time seeking backwards is needed within the stream, which significantly undermines the performance.</p>
  552. <p>This section contains the declaration of Gzip-specific functions.</p>
  553. <h2 id="ft_stream_opengzip">FT_Stream_OpenGzip<a class="headerlink" href="#ft_stream_opengzip" title="Permanent link">&para;</a></h2>
  554. <p>Defined in FT_GZIP_H (freetype/ftgzip.h).</p>
  555. <div class = "codehilite"><pre><code> FT_EXPORT( <a href="ft2-basic_types.html#ft_error">FT_Error</a> )
  556. <b>FT_Stream_OpenGzip</b>( <a href="ft2-system_interface.html#ft_stream">FT_Stream</a> stream,
  557. <a href="ft2-system_interface.html#ft_stream">FT_Stream</a> source );
  558. </code></pre></div>
  559. <p>Open a new stream to parse gzip-compressed font files. This is mainly used to support the compressed <code>*.pcf.gz</code> fonts that come with XFree86.</p>
  560. <h4>input</h4>
  561. <table class="fields">
  562. <tr><td class="val" id="stream">stream</td><td class="desc">
  563. <p>The target embedding stream.</p>
  564. </td></tr>
  565. <tr><td class="val" id="source">source</td><td class="desc">
  566. <p>The source stream.</p>
  567. </td></tr>
  568. </table>
  569. <h4>return</h4>
  570. <p>FreeType error code. 0&nbsp;means success.</p>
  571. <h4>note</h4>
  572. <p>The source stream must be opened <em>before</em> calling this function.</p>
  573. <p>Calling the internal function <code>FT_Stream_Close</code> on the new stream will <strong>not</strong> call <code>FT_Stream_Close</code> on the source stream. None of the stream objects will be released to the heap.</p>
  574. <p>This function may return <code>FT_Err_Unimplemented_Feature</code> if your build of FreeType was not compiled with zlib support.</p>
  575. <hr>
  576. <h2 id="ft_gzip_uncompress">FT_Gzip_Uncompress<a class="headerlink" href="#ft_gzip_uncompress" title="Permanent link">&para;</a></h2>
  577. <p>Defined in FT_GZIP_H (freetype/ftgzip.h).</p>
  578. <div class = "codehilite"><pre><code> FT_EXPORT( <a href="ft2-basic_types.html#ft_error">FT_Error</a> )
  579. <b>FT_Gzip_Uncompress</b>( <a href="ft2-system_interface.html#ft_memory">FT_Memory</a> memory,
  580. <a href="ft2-basic_types.html#ft_byte">FT_Byte</a>* output,
  581. <a href="ft2-basic_types.html#ft_ulong">FT_ULong</a>* output_len,
  582. <span class="keyword">const</span> <a href="ft2-basic_types.html#ft_byte">FT_Byte</a>* input,
  583. <a href="ft2-basic_types.html#ft_ulong">FT_ULong</a> input_len );
  584. </code></pre></div>
  585. <p>Decompress a zipped input buffer into an output buffer. This function is modeled after zlib's <code>uncompress</code> function.</p>
  586. <h4>input</h4>
  587. <table class="fields">
  588. <tr><td class="val" id="memory">memory</td><td class="desc">
  589. <p>A FreeType memory handle.</p>
  590. </td></tr>
  591. <tr><td class="val" id="input">input</td><td class="desc">
  592. <p>The input buffer.</p>
  593. </td></tr>
  594. <tr><td class="val" id="input_len">input_len</td><td class="desc">
  595. <p>The length of the input buffer.</p>
  596. </td></tr>
  597. </table>
  598. <h4>output</h4>
  599. <table class="fields">
  600. <tr><td class="val" id="output">output</td><td class="desc">
  601. <p>The output buffer.</p>
  602. </td></tr>
  603. </table>
  604. <h4>inout</h4>
  605. <table class="fields">
  606. <tr><td class="val" id="output_len">output_len</td><td class="desc">
  607. <p>Before calling the function, this is the total size of the output buffer, which must be large enough to hold the entire uncompressed data (so the size of the uncompressed data must be known in advance). After calling the function, <code>output_len</code> is the size of the used data in <code>output</code>.</p>
  608. </td></tr>
  609. </table>
  610. <h4>return</h4>
  611. <p>FreeType error code. 0&nbsp;means success.</p>
  612. <h4>note</h4>
  613. <p>This function may return <code>FT_Err_Unimplemented_Feature</code> if your build of FreeType was not compiled with zlib support.</p>
  614. <h4>since</h4>
  615. <p>2.5.1</p>
  616. <hr>
  617. </article>
  618. </div>
  619. </div>
  620. </main>
  621. <footer class="md-footer">
  622. <nav class="md-footer__inner md-grid" aria-label="Footer">
  623. <a href="ft2-module_management.html" class="md-footer__link md-footer__link--prev" aria-label="Previous: Module Management" rel="prev">
  624. <div class="md-footer__button md-icon">
  625. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11h12z"/></svg>
  626. </div>
  627. <div class="md-footer__title">
  628. <div class="md-ellipsis">
  629. <span class="md-footer__direction">
  630. Previous
  631. </span>
  632. Module Management
  633. </div>
  634. </div>
  635. </a>
  636. <a href="ft2-lzw.html" class="md-footer__link md-footer__link--next" aria-label="Next: LZW Streams" rel="next">
  637. <div class="md-footer__title">
  638. <div class="md-ellipsis">
  639. <span class="md-footer__direction">
  640. Next
  641. </span>
  642. LZW Streams
  643. </div>
  644. </div>
  645. <div class="md-footer__button md-icon">
  646. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M4 11v2h12l-5.5 5.5 1.42 1.42L19.84 12l-7.92-7.92L10.5 5.5 16 11H4z"/></svg>
  647. </div>
  648. </a>
  649. </nav>
  650. <div class="md-footer-meta md-typeset">
  651. <div class="md-footer-meta__inner md-grid">
  652. <div class="md-footer-copyright">
  653. <div class="md-footer-copyright__highlight">
  654. Copyright 2021 <a href = "https://www.freetype.org/license.html">The FreeType Project</a>.
  655. </div>
  656. Made with
  657. <a href="https://squidfunk.github.io/mkdocs-material/" target="_blank" rel="noopener">
  658. Material for MkDocs
  659. </a>
  660. </div>
  661. </div>
  662. </div>
  663. </footer>
  664. </div>
  665. <div class="md-dialog" data-md-component="dialog">
  666. <div class="md-dialog__inner md-typeset"></div>
  667. </div>
  668. <script id="__config" type="application/json">{"base": ".", "features": [], "translations": {"clipboard.copy": "Copy to clipboard", "clipboard.copied": "Copied to clipboard", "search.config.lang": "en", "search.config.pipeline": "trimmer, stopWordFilter", "search.config.separator": "[\\s\\-]+", "search.placeholder": "Search", "search.result.placeholder": "Type to start searching", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.term.missing": "Missing", "select.version.title": "Select version"}, "search": "assets/javascripts/workers/search.477d984a.min.js", "version": null}</script>
  669. <script src="assets/javascripts/bundle.82b56eb2.min.js"></script>
  670. <script src="javascripts/extra.js"></script>
  671. </body>
  672. </html>