Skip to main content

Crate dsd_source

Crate dsd_source 

Source
Expand description

A trait abstraction over DSD audio sources, plus the small set of shared DSD model types (bit endianness, channel layout, rate multiplier) used to describe them.

Container/metadata crates (e.g. dsf-meta, dff-meta, or a WavPack equivalent) implement DsdSource to describe the native shape of the DSD audio they expose (DsdSourceInfo) and to hand back a byte stream of that native-shape audio data.

Readers (e.g. dsd-reader) depend on this crate instead of on any specific container format, and are responsible for reshaping the native byte stream into whatever output shape a caller asks for (planar vs. interleaved, LSB- vs. MSB-first, output block size). This crate does not perform that reshaping itself; it only describes the source.

Structs§

DsdSourceInfo
Describes the native shape of a DsdSource’s audio data.

Enums§

DsdRate
DSD rate multiplier, relative to the DSD64 base rate (DSD_64_RATE).
Endianness
DSD bit endianness.
FmtType
DSD channel layout.

Constants§

DSD_64_RATE
The DSD64 native sample rate, in Hz. All other DsdRate variants are integer multiples of this base rate.

Traits§

DsdSource
A source of DSD audio data with a known native shape.
DsdSourceExtensions
File extensions (lowercase, no leading dot) recognized as this source’s container format. Kept separate from DsdSource since associated consts aren’t dyn-compatible: implementers declare this alongside DsdSource, and callers reference it on the concrete type (e.g. DsfFile::EXTENSIONS) to build a format dispatch table without a reader needing to hardcode each format’s extensions itself.

Type Aliases§

DsdSourceError
Error type returned by DsdSource methods.