- merge with original master from jorgen
- minimize RAM usage of all components - use both IRAM and DRAM in player component so we can buffer up to 1s on modules without SPI RAM - support fragemented pcm chunks so we can use all available RAM if there isn't a big enough block available but still enough HEAP - reinclude all components from jorgen's master branch - add custom i2s driver to get a precise timing of initial sync - change wrong usage of esp_timer for latency measurement of snapcast protocol - add player component
This commit is contained in:
46
components/dsp_processor/include/dsp_processor.h
Normal file
46
components/dsp_processor/include/dsp_processor.h
Normal file
@@ -0,0 +1,46 @@
|
||||
#ifndef _DSP_PROCESSOR_H_
|
||||
#define _DSP_PROCESSOR_H_
|
||||
|
||||
typedef enum dspFlows {
|
||||
dspfStereo,
|
||||
dspfBiamp,
|
||||
dspf2DOT1,
|
||||
dspfFunkyHonda,
|
||||
dspfBassBoost
|
||||
} dspFlows_t;
|
||||
|
||||
enum filtertypes {
|
||||
LPF,
|
||||
HPF,
|
||||
BPF,
|
||||
BPF0DB,
|
||||
NOTCH,
|
||||
ALLPASS360,
|
||||
ALLPASS180,
|
||||
PEAKINGEQ,
|
||||
LOWSHELF,
|
||||
HIGHSHELF
|
||||
};
|
||||
|
||||
// Process node
|
||||
typedef struct ptype {
|
||||
int filtertype;
|
||||
float freq;
|
||||
float gain;
|
||||
float q;
|
||||
float *in, *out;
|
||||
float coeffs[5];
|
||||
float w[2];
|
||||
} ptype_t;
|
||||
|
||||
// Process flow
|
||||
typedef struct pnode {
|
||||
ptype_t process;
|
||||
struct pnode *next;
|
||||
} pnode_t;
|
||||
|
||||
void dsp_setup_flow(double freq, uint32_t samplerate);
|
||||
int dsp_processor(char *audio, size_t chunk_size, dspFlows_t dspFlow);
|
||||
void dsp_set_xoverfreq(uint8_t, uint8_t, uint32_t);
|
||||
|
||||
#endif /* _DSP_PROCESSOR_H_ */
|
||||
Reference in New Issue
Block a user