Changeset 95239 in vbox for trunk/src/libs/zlib-1.2.12/deflate.h
- Timestamp:
- Jun 9, 2022 9:09:44 AM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 151769
- Location:
- trunk/src/libs/zlib-1.2.12
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/libs/zlib-1.2.12
- Property svn:mergeinfo
-
old new 20 20 /branches/dsen/gui3/src/libs/zlib-1.2.11:79645-79692 21 21 /trunk/src/src/libs/zlib-1.2.11:92342 22 /vendor/zlib/1.2.12:151751 23 /vendor/zlib/current:150724-151750
-
- Property svn:mergeinfo
-
trunk/src/libs/zlib-1.2.12/deflate.h
r76163 r95239 1 1 /* deflate.h -- internal compression state 2 * Copyright (C) 1995-201 6Jean-loup Gailly2 * Copyright (C) 1995-2018 Jean-loup Gailly 3 3 * For conditions of distribution and use, see copyright notice in zlib.h 4 4 */ … … 218 218 */ 219 219 220 uchf * l_buf; /* buffer for literals orlengths */220 uchf *sym_buf; /* buffer for distances and literals/lengths */ 221 221 222 222 uInt lit_bufsize; … … 240 240 */ 241 241 242 uInt last_lit; /* running index in l_buf */ 243 244 ushf *d_buf; 245 /* Buffer for distances. To simplify the code, d_buf and l_buf have 246 * the same number of elements. To use different lengths, an extra flag 247 * array would be necessary. 248 */ 242 uInt sym_next; /* running index in sym_buf */ 243 uInt sym_end; /* symbol table full when sym_next reaches this */ 249 244 250 245 ulg opt_len; /* bit length of current block with optimal trees */ … … 326 321 # define _tr_tally_lit(s, c, flush) \ 327 322 { uch cc = (c); \ 328 s->d_buf[s->last_lit] = 0; \ 329 s->l_buf[s->last_lit++] = cc; \ 323 s->sym_buf[s->sym_next++] = 0; \ 324 s->sym_buf[s->sym_next++] = 0; \ 325 s->sym_buf[s->sym_next++] = cc; \ 330 326 s->dyn_ltree[cc].Freq++; \ 331 flush = (s-> last_lit == s->lit_bufsize-1); \327 flush = (s->sym_next == s->sym_end); \ 332 328 } 333 329 # define _tr_tally_dist(s, distance, length, flush) \ 334 330 { uch len = (uch)(length); \ 335 331 ush dist = (ush)(distance); \ 336 s->d_buf[s->last_lit] = dist; \ 337 s->l_buf[s->last_lit++] = len; \ 332 s->sym_buf[s->sym_next++] = dist; \ 333 s->sym_buf[s->sym_next++] = dist >> 8; \ 334 s->sym_buf[s->sym_next++] = len; \ 338 335 dist--; \ 339 336 s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \ 340 337 s->dyn_dtree[d_code(dist)].Freq++; \ 341 flush = (s-> last_lit == s->lit_bufsize-1); \338 flush = (s->sym_next == s->sym_end); \ 342 339 } 343 340 #else
Note:
See TracChangeset
for help on using the changeset viewer.