Parsed shards (any order, unique indexes).
Shard count from the terminal signal, or null when none arrived.
Captured sample count from the terminal signal, or null.
The one decoder for this stream.
RecordingAssemblyError on a duplicate index, a shard overlapping the audio before it, or a shard/sample count over MAX_ASSEMBLY_SHARDS / MAX_ASSEMBLY_SAMPLES.
Lays a session's shards out on one 48 kHz timeline and decodes them with one decoder.
SampleCountsamples are kept (decoded audio past it is dropped, a shortfall stays silent). Every packet is still decoded so the decoder state stays continuous into the next shard.DecodeFailures.The samples are decoded straight into the returned WAV's data section (see
allocatePcm16Wav).The shard count is
expectedShards, or the highest present index + 1 when no terminal signal has arrived. The length iscapturedSamples, or the end of the last shard when unknown (and never less than the end of the last shard: audio past a stale terminal is kept, not cut).