Skip to main content

Module smk

Module smk 

Source
Expand description

Smacker (SMK2/SMK4) video decoder, written from the public format description: a header with per-frame sizes and types, four Huffman trees, then per frame an optional palette update, audio chunks (skipped; Blood’s cutscene audio is in separate WAV files) and a bitstream of 4x4 blocks.

Structs§

BigTree 🔒
16-bit tree with Smacker’s three “recent value” escape leaves.
Bits 🔒
Least-significant-bit-first bit reader.
SmallTree 🔒
8-bit tree used to build the 16-bit trees.
Smk
An open Smacker video; call Smk::next_frame to advance and read Smk::pixels.

Enums§

Node 🔒
Huffman tree stored as nodes: Branch(zero, one) or a leaf index into a value table.

Constants§

BLOCK_RUNS 🔒
RING_FRAME 🔒
Y_DOUBLE 🔒
Y_INTERLACE 🔒

Functions§

invalid 🔒
pal6 🔒