bend-kit-bits
Search uses release 0.1.0.1 · 55 definitions
Definitions (55)
- def mask
- def win.lsb.join
- def win.msb.join
- def win.lsb.at
- def win.msb.at
- def winThe 32 stream bits from bit p, in stream order: first bit lowest LSB-first, highest MSB-first.
- def fieldThe first n (at most 32) bits of a window as a number, first stream bit most significant MSB-first.
- type ReaderA reader owns the buffer of len bytes; pos is the next bit.
- def Reader.new
- def Reader.finishThe buffer back, and the bit position.
- def Reader.left
- def read.got
- def read.if
- def read
- def Reader.lsbThe next n bits (0 to 32) as a number, and the reader past them.
- def Reader.msb
- def peek.gotBits past the end read as 0: the low avail bits stay LSB-first, the high ones MSB-first.
- def peek
- def Reader.peek.lsbThe next n bits (at most 32) without moving.
- def Reader.peek.msb
- def Reader.skipMoves n bits on.
- def Reader.alignMoves to the next byte boundary, as a DEFLATE stored block or a JPEG marker needs.
- type WriterA writer's buf has 2^dep words, all 0 past bit pos.
- def Writer.new
- def roomA write adds at most 32 bits, so one doubling always makes room.
- def or.of
- def or.if
- def partsThe parts of an n-bit v that land in word k and word k + 1, as stored words.
- def write.put
- def write.at
- def write
- def Writer.lsbAppends the low n bits of v (n is cut to 32).
- def Writer.msb
- def Writer.alignPads with 0 bits to the next byte boundary.
- def Writer.finishThe bytes written; 0 bits fill the last byte.
- type HuffA canonical Huffman table: entry i of 2^max is (sym << 5) | len for the code that the first max stream bits i start with, or 0 when no code does.
- type CodeOne symbol and the length of its code.
- def lens.max
- def count.of
- def count.if
- def count
- def next.goRFC 1951 §3.2.2: next[l] = (next[l-1] + count[l-1]) << 1.
- def fill
- def rev
- def assign.putMSB-first, a code fills a run of consecutive entries; LSB-first, its bits reversed fill every 2^len-th.
- def assign.one
- def assign
- def build.next
- def build.short
- def Huff.from_codesA table from codes.
- def codes
- def Huff.from_lensSymbol i has length lens[i], as DEFLATE sends them (RFC 1951 §3.2.2).
- def decode.hitBits past the end may be garbage in w: a code's entry repeats over every suffix, so only its own len bits pick it, and len <= left keeps them inside the stream.
- def decode.look
- def Huff.decodeOne symbol, and the reader past its code.