Skip to main content

Module quant

Module quant 

Source
Expand description

Signed 16-bit PCM quantization, shared by every output path.

A single canonical quantizer keeps the CLI, the encoders and the language bindings byte-identical. Sample values are host-native i16; serializing to a little-endian wire format (s16le) is the consumer’s responsibility (this crate returns values, not byte-order-specific buffers).

Functions§

quantize_i16
Quantize one f32 sample to signed 16-bit PCM (no dither).