2015-06-07 13:18:59 -07:00
|
|
|
struct Crap {
|
|
|
|
virtual inline
|
|
|
|
~Crap() {}
|
|
|
|
|
2015-06-07 17:44:41 -07:00
|
|
|
ulong id;
|
|
|
|
char *label;
|
|
|
|
char *name;
|
|
|
|
char *author;
|
|
|
|
char *copyright;
|
|
|
|
ulong bands;
|
|
|
|
ulong parameters;
|
|
|
|
|
2015-06-07 13:18:59 -07:00
|
|
|
virtual void
|
|
|
|
pause() = 0;
|
|
|
|
|
|
|
|
virtual void
|
|
|
|
resume() = 0;
|
|
|
|
|
|
|
|
virtual void
|
|
|
|
process(
|
|
|
|
double *in_L, double *in_R,
|
|
|
|
double *out_L, double *out_R,
|
|
|
|
ulong count) = 0;
|
|
|
|
|
|
|
|
virtual void
|
|
|
|
process(
|
|
|
|
float *in_L, float *in_R,
|
|
|
|
float *out_L, float *out_R,
|
|
|
|
ulong count) = 0;
|
|
|
|
|
|
|
|
//void
|
|
|
|
//construct_params(param *params) = 0;
|
|
|
|
|
|
|
|
virtual void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust(Param *params, ulong fs) = 0;
|
2015-06-07 13:18:59 -07:00
|
|
|
|
|
|
|
virtual void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust_one(Param *params, int i) = 0;
|
2015-06-07 13:18:59 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
template<class Mixin>
|
|
|
|
struct AdjustAll : public virtual Mixin {
|
|
|
|
ulong fs;
|
|
|
|
|
|
|
|
virtual void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust_all(Param *params) = 0;
|
2015-06-07 13:18:59 -07:00
|
|
|
|
|
|
|
inline void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust(Param *params, ulong fs_new)
|
2015-06-07 13:18:59 -07:00
|
|
|
{
|
|
|
|
fs = fs_new;
|
|
|
|
adjust_all(params);
|
|
|
|
}
|
|
|
|
|
|
|
|
inline void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust_one(Param *params, int i)
|
2015-06-07 13:18:59 -07:00
|
|
|
{
|
|
|
|
adjust_all(params);
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
template<class Mixin>
|
|
|
|
struct NoParams : public virtual Mixin {
|
|
|
|
// etc
|
|
|
|
|
|
|
|
//void
|
|
|
|
//construct_params(param *params) = 0;
|
|
|
|
|
|
|
|
void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust(Param *params, ulong fs)
|
2015-06-07 13:18:59 -07:00
|
|
|
{}
|
|
|
|
|
|
|
|
void
|
2015-06-07 17:44:41 -07:00
|
|
|
adjust_one(Param *params, int i)
|
2015-06-07 13:18:59 -07:00
|
|
|
{}
|
|
|
|
};
|