24#ifndef TRANSPORT_DELAY_H
25#define TRANSPORT_DELAY_H
29#define TRANSPORT_DELAY_BUFFER_SIZE 20
57 td->
buffer[i] = initial_value;
72 float output = td->
buffer[read_index];
87 td->
buffer[i] = initial_value;
101 return td->
buffer[read_index];
static float get_transport_delay(const struct TransportDelay *td)
Get the current output value from the transport delay buffer without updating it.
static void init_transport_delay(struct TransportDelay *td, uint8_t delay_samples, const float initial_value)
Initialize a transport delay buffer.
float buffer[TRANSPORT_DELAY_BUFFER_SIZE]
static void reset_transport_delay(struct TransportDelay *td, const float initial_value)
Reset the transport delay buffer to a specific initial value.
static float update_transport_delay(struct TransportDelay *td, const float input)
Propagate a new input value through the transport delay buffer.
#define TRANSPORT_DELAY_BUFFER_SIZE
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.