MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/SPlisHSPlasH / _tr_init

Function _tr_init

extern/zlib/src/trees.c:455–476  ·  view source on GitHub ↗

=========================================================================== * Initialize the tree data structures for a new zlib stream. */

Source from the content-addressed store, hash-verified

453 * Initialize the tree data structures for a new zlib stream.
454 */
455void ZLIB_INTERNAL _tr_init(deflate_state *s) {
456 tr_static_init();
457
458 s->l_desc.dyn_tree = s->dyn_ltree;
459 s->l_desc.stat_desc = &static_l_desc;
460
461 s->d_desc.dyn_tree = s->dyn_dtree;
462 s->d_desc.stat_desc = &static_d_desc;
463
464 s->bl_desc.dyn_tree = s->bl_tree;
465 s->bl_desc.stat_desc = &static_bl_desc;
466
467 s->bi_buf = 0;
468 s->bi_valid = 0;
469#ifdef ZLIB_DEBUG
470 s->compressed_len = 0L;
471 s->bits_sent = 0L;
472#endif
473
474 /* Initialize the first block of the first file: */
475 init_block(s);
476}
477
478#define SMALLEST 1
479/* Index within the heap array of least frequent node in the Huffman tree */

Callers 1

deflate.cFile · 0.85

Calls 2

tr_static_initFunction · 0.85
init_blockFunction · 0.85

Tested by

no test coverage detected