- Add packed 24-bit sample types
I24LE3,I24BE3,U24LE3andU24BE3todasp_sample::types, corresponding to the ALSAS24_3LE,S24_3BE,U24_3LEandU24_3BEformats. UnlikeI24/U24these occupy exactly three bytes with an alignment of one, so packed 24-bit PCM can be reinterpreted as a slice of them without a copy. Out-of-range values wrap modulo 2^24. - Bump
dasp_sampleanddasp_frameto 0.11.1, and raisedasp_frame's requirement ondasp_sampleto0.11.1, as it now references the packed types by name and would not build against 0.11.0. - Renamed
window-hanningtowindow-hann - Made
IntoInterleavedSamplesandIntoInterleavedSamplesIteratorstop yielding samples when the underlying signal gets exhausted. This is a breaking change. The return type of theIntoInterleavedSamples#next_samplemethod was modified.
- Refactor the
samplecrate into a modular collection of crates underdasp. - Rename repository from
sampletodasp, wheredaspstands for digital audio signal processing. - Add a suite of useful feature gates:
- Add
stdto all crates. Can be disabled in order to useno_std. - Add a
all-features-no-stdfeature todasp,dasp_envelope,dasp_interpolate,dasp_signal,dasp_sliceanddasp_window. Enables all features within ano_stdcontext. dasp_envelopecrate:peak- enables peak detector implementation.rms- enables RMS detector implementation.
dasp_interpolatecrate:floor- enablesFloorInterpolateimplementation.linear- enablesLinearInterpolateimplementation.sinc- enablesSincInterpolateimplementation.
dasp_signalcrate:boxed- enablesSignalimplementation forBox<dyn Signal>.bus- enablesSignalBustrait.envelope- enablesSignalEnvelopetrait.rms- enablesSignalRmstrait.window- enablessignal::windowmodule.window-hanning- enables hanning window constructor.window-rectangle- enables rectangle window constructor.
dasp_slicecrate:boxed- enables conversions between boxed slices.
- The
daspcrate has a feature for each of the above.
- Add
- Make Window trait generic over its phase and amplitude type. Update the
dasp_signal::windowmodule items accordingly. - Remove unsafe uninitialized ring buffer constructors.
- Remove
equilibrium()andidentity()constructors fromSampleandFrametraitsin favour ofEQUILIBRIUMandIDENTITYassociated consts. - Remove
Frame::n_channelsfunction in favour ofFrame::CHANNELSassociated const. - Add implementation of
Framefor all primitiveSampletypes where each are assumed to represent a frame of a monophonic signal. This greatly simplifies working with monophonic signal sources as demonstrated in the updateddasp_signalcrate.
CHANGELOG begins...