|
FZGPUModules 2.0
GPU-accelerated modular compression pipelines
|
Header: modules/transforms/zigzag/zigzag_stage.h Class: fz::ZigzagStage<TIn, TOut> Category: Transform (lossless)
Element-wise zigzag encoding (two's complement to magnitude-sign). Converts a signed integer stream into unsigned integers of the same width so small magnitudes map to small codes.
Output is the same byte size as input.
| Parameter | Constraint |
|---|---|
TIn | Signed integer (see available instantiations below) |
TOut | Unsigned counterpart of TIn |
Only these pairs are compiled and linked:
ZigzagStage<int8_t, uint8_t>ZigzagStage<int16_t, uint16_t>ZigzagStage<int32_t, uint32_t>ZigzagStage<int64_t, uint64_t>Using any other pair will result in a linker error. Most common: ZigzagStage<int32_t, uint32_t> (to match typical code widths).
No stage-specific setters. This stage is purely type-driven.
Single input -> single output; element count and byte size are unchanged.
| Direction | Port | Type |
|---|---|---|
| Input | "output" (default) | TIn[n] |
| Output | "output" | TOut[n] |