#include "builtins.h" #include "blocktype.h" static const char *ins[] = { "Freq", "Duty" }; static const char *outs[] = { "Sin", "Tri", "Sq" }; static BLOCKPARAM params_osc[] = { { .name = "Freq", .type = PAR_FREQ }, { .name = "Duty%", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } } }; BLOCKTYPE block_osc = { .name = "Osc", .n_in = 0, .ins = 0, .n_out = 3, .outs = &outs[0], .n_param = 2, .params = ¶ms_osc[0] }; static BLOCKPARAM params_vco[] = { { .name = "Freq1", .type = PAR_FREQ }, { .name = "Freq2", .type = PAR_FREQ }, { .name = "Duty%", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } } }; BLOCKTYPE block_vco = { .name = "VCO", .n_in = 1, .ins = &ins[0], .n_out = 3, .outs = &outs[0], .n_param = 3, .params = ¶ms_vco[0] }; static BLOCKPARAM params_ddcosc[] = { { .name = "Freq", .type = PAR_FREQ }, { .name = "Duty%1", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } }, { .name = "Duty%2", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } } }; BLOCKTYPE block_ddcosc = { .name = "DDCOsc", .n_in = 1, .ins = &ins[1], .n_out = 3, .outs = &outs[0], .n_param = 3, .params = ¶ms_ddcosc[0] }; static BLOCKPARAM params_genosc[] = { { .name = "Freq1", .type = PAR_FREQ }, { .name = "Freq2", .type = PAR_FREQ }, { .name = "Duty%1", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } }, { .name = "Duty%2", .type = PAR_FRANGE, .u = { .frange = { .min = 0, .max = 100 } } } }; BLOCKTYPE block_genosc = { .name = "GenOsc", .n_in = 2, .ins = &ins[0], .n_out = 3, .outs = &outs[0], .n_param = 4, .params = ¶ms_genosc[0] };