You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
972 B
58 lines
972 B
#ifndef SYNTH_SHED_H
|
|
#define SYNTH_SHED_H
|
|
|
|
// Types
|
|
// != 0 means ERR
|
|
typedef int SYNTH_STATUS;
|
|
typedef enum _filtertype filtertype_t;
|
|
typedef struct _synth synth_t;
|
|
|
|
// Enums
|
|
enum _filtertype {
|
|
HPF,
|
|
LPF,
|
|
BPF
|
|
};
|
|
|
|
typedef enum _tech {
|
|
ANALOG,
|
|
DIGITAL
|
|
} tech_t;
|
|
|
|
// Structs
|
|
typedef struct _filter {
|
|
tech_t technology;
|
|
filtertype_t *type;
|
|
} filter_t;
|
|
|
|
|
|
struct _synth {
|
|
const char* model_name;
|
|
int osc_count;
|
|
tech_t technolgy;
|
|
filter_t filter;
|
|
};
|
|
|
|
|
|
// Functions
|
|
void init_synth_shed();
|
|
|
|
synth_t* synth_create(const char* name);
|
|
|
|
//SYNTH_STATUS synth_set_osc_count(synth_t* synth,
|
|
// int osc_count);
|
|
//
|
|
//SYNTH_STATUS synth_set_filter(synth_t* synth,
|
|
// filter_t* filt);
|
|
//
|
|
//SYNTH_STATUS synth_set_tech(synth_t* synth,
|
|
// tech_t tech);
|
|
|
|
const char* tech_to_string(const tech_t* tech);
|
|
|
|
const char* filtertype_to_string(const filtertype_t *filt);
|
|
|
|
|
|
const char* play_synth(synth_t *synth);
|
|
|
|
#endif //SYNTH_SHED_H
|
|
|