Sound Byte Libs 0.5.1-121-g3358a44
C++ firmware library for audio applications on 32-bit ARM Cortex-M processors
Loading...
Searching...
No Matches
interpolate.hpp File Reference

Interpolation and blending utilities. More...

Detailed Description

Interpolation and blending utilities.

Definition in file interpolate.hpp.

#include <cstdint>
#include <cmath>

Go to the source code of this file.

Namespaces

namespace  sbl
 Root namespace for all Sound Byte Libs code.
 
namespace  sbl::dsp
 
namespace  sbl::dsp::math
 Cross-cutting math used at every audio layer.
 

Functions

constexpr float sbl::dsp::math::crossfade (float a, float b, float t)
 Linear crossfade between two values.
 
constexpr float sbl::dsp::math::smooth_step (float t)
 Hermite smooth step (3rd-order S-curve)
 
constexpr int32_t sbl::dsp::math::crossfade_i16 (int16_t a, int16_t b, uint16_t t)
 Integer crossfade for 16-bit values.
 
float sbl::dsp::math::crossfade_equal_power (float a, float b, float t)
 Equal-power crossfade between two values.
 
void sbl::dsp::math::crossfade_block (const float *a, const float *b, float *out, float mix, uint16_t frames)
 Linear crossfade over a block with constant mix.
 
void sbl::dsp::math::crossfade_block_equal_power (const float *a, const float *b, float *out, float mix, uint16_t frames)
 Equal-power crossfade over a block with constant mix.