Expand description
Allocation-free Quake and GoldSrc visibility row codecs. Allocation-free Quake/GoldSrc visibility RLE.
Nonzero bytes are literals; zero followed by a count advances over invisible leaves. The caller selects strict container validation or GoldSrc’s bounded best-effort policy, and replacement or OR merging, without a second row buffer.
Functions§
- decode_
clamped - Decode a bounded GoldSrc row, clipping oversized runs and leaving a truncated tail invisible. Zero-length runs are consumed, not rejected.
- decode_
strict - Decode exactly one row, rejecting truncation, zero runs and oversized runs.
Bytes already decoded remain in
outputon failure. - merge_
clamped - OR a bounded GoldSrc row into an existing row, clipping oversized runs and preserving the destination after truncated input or invisible runs.
- merge_
strict - OR one strict row into an existing row. Invisible runs leave it unchanged.
Bytes already merged remain in
outputon failure.