(bind-func analogue_reset
(let ((i 0) (j 0))
(lambda (inst:i8*)
;;
;; oscillators
;;
;; amplitude of osc 1
(set_osc1_amp inst 0.5)
;; waveform of osc 1 (PARAM_SINE,PARAM_SAW,PARAM_PULSE,PARAM_TRI)
(set_osc1_wave inst PARAM_SAW)
;; frequency shift of osc - tuning - 2.0 up tune 0.5 down tune etc..
(set_osc1_tune inst 1.0)
;; pulse width (for PARAM_PULSE wave) 0.0-1.0 (0.5 is square)
(set_osc1_pw inst 0.5)
;; stereo pan (default is 0.5)
(set_osc1_phase inst 0.0)
;; amplitude of osc 2
(set_osc2_amp inst 0.0)
;; waveform of osc 2 (PARAM_SINE,PARAM_SAW,PARAM_PULSE,PARAM_TRI)
(set_osc2_wave inst PARAM_SAW)
;; frequency shift of osc - tuning - 2.0 up tune 0.5 down tune etc..
(set_osc2_tune inst 1.0)
;; pulse width (for PARAM_PULSE wave) 0.0-1.0 (0.5 is square)
(set_osc2_pw inst 0.5)
;; stereo pan (default is 0.5)
(set_osc2_phase inst 0.0)
;; amplitude of osc 3
(set_osc3_amp inst 0.0)
;; waveform of osc 3 (PARAM_SINE,PARAM_SAW,PARAM_PULSE,PARAM_TRI)
(set_osc3_wave inst PARAM_SAW)
;; frequency shift of osc - tuning - 2.0 up tune 0.5 down tune etc..
(set_osc3_tune inst 1.0)
;; pulse width (for PARAM_PULSE wave) 0.0-1.0 (0.5 is square)
(set_osc3_pw inst 0.5)
;; stereo pan (default is 0.5)
(set_osc3_phase inst 0.0)
;; amplitude of osc 4
(set_osc4_amp inst 0.0)
;; waveform of osc 3 (PARAM_SINE,PARAM_SAW,PARAM_PULSE,PARAM_TRI)
(set_osc4_wave inst PARAM_SAW)
;; frequency shift of osc - tuning - 2.0 up tune 0.5 down tune etc..
(set_osc4_tune inst 1.0)
;; pulse width (for PARAM_PULSE wave) 0.0-1.0 (0.5 is square)
(set_osc4_pw inst 0.5)
;; stereo pan (default is 0.5)
(set_osc4_phase inst 0.0)
;; sub oscilltor amp (two tunes under sine wave)
(set_sub_amp inst 0.0)
;; noise (PARAM_WHITE or PARAM_PINK)
(set_noise_type inst PARAM_WHITE)
;; noise amplitude
(set_noise_amp inst 0.0)
;;
;; filters
;;
;; lpf filter cutoff frq in hz
(set_filter_frq inst 15000.0)
;; lpf filter resonance (0.0-1.0)
(set_filter_res inst 0.0)
;; hpf cutoff frequency
(set_hpf_frq inst 20001.0)
;;
;; envelopes
;;
;; main amplitude adsr envelope (adr in ms) (sus [0.0-1.0])
(set_amp_env inst 0.0 0.0 1.0 0.0)
;; filter (LPF) adsr envelope (adr in ms) (sus [0.0-1.0])
(set_filter_env inst 0.0 0.0 1.0 0.0)
;; the amount of filter envelope to apply in hz 0.0 - 20000.0
;; this envelope is summed to the current filter_frq
(set_filter_env_amt inst 0.0)
;; follow note frequency as a percentage of the note frequency
;; i.e. (+ cutoff (* frequency value))
(set_filter_env_follow_frq inst 0.0)
;; follow note amplitude as a frequency related to the note amplitude
;; i.e. (+ cutoff (* amplitude value))
(set_filter_env_follow_amp inst 0.0)
;; pitch envelope attack and decay only in ms
(set_pitch_env inst 0.0 0.0)
;; the amount of pitch envelope to apply as a ratio of the note frequency
;; i.e. a value of 1.0 will add 1 tune to current pitch
;; a value of 0.5 will subtract 1 tune
(set_pitch_env_amt inst 0.0)
;;
;; delay
;;
;; delay time in ms
(set_delay_time_left inst 0.0)
(set_delay_time_right inst 0.0)
;; delay amt (gain) 0.0-1.0
(set_delay_mix inst 0.0)
;; delay fb
(set_delay_fb inst 0.0)
;; delay damping (cutoff frq)
(set_delay_frq inst 12000.0)
;; delay resonance
(set_delay_res inst 0.0)
;;
;; reverb
;;
;; reverb_mix 0.0-1.0 0.0 is dry 1.0 is wet
(set_reverb_mix inst 0.0)
;; reverb size (room size) 0.0-1.0 - 1.0 is large
(set_reverb_size inst 0.4)
;; reverb predelay in ms (up to 2 seconds)
(set_reverb_predelay inst 40.0)
;; reverb absorbtion 0.0-1.0
(set_reverb_absorb inst 0.45)
;;
;; flanger
;;
(set_flanger_mix inst 0.0)
;; the low mark (time in ms) for the flanger
(set_flanger_low inst 0.1)
;; the high mark (time in ms) for the flanger
(set_flanger_high inst 4.0)
;; the rate (in hz) of the flanger
(set_flanger_rate inst 0.127287)
;; any feedback -1.0 - 1.0
(set_flanger_fb inst 0.25)
;;
;; panning
;;
;; see pan_c in audio_dsp for detailed info
;; about the values for pos and width
;; for channels > 2
;;
;; pan pos 0.0-1.0 (assuming stereo)
(set_pan_pos inst 0.5)
;; pan width 1.0
(set_pan_width inst 1.0)
;;
;; gain
;;
(set_gain inst 2.0)
;;
;; portamento (in millis)
(set_portamento inst 0.0)
;;
;; set max polyphony
(set_polyphonic inst)
;;
;; lfos
;;
;; attack, decay, attack slope, decay slope
;; attack ins ms, decay in ms, attack & decay slopes -1.0 log and 1.0 exp (0.0 is linear)
(set_lfo_ad inst PARAM_LFO1 10.0 10.0 0.0 0.0)
(set_lfo_ad inst PARAM_LFO2 10.0 10.0 0.0 0.0)
(set_lfo_ad inst PARAM_LFO3 10.0 10.0 0.0 0.0)
(set_lfo_ad inst PARAM_LFO4 10.0 10.0 0.0 0.0)
;; set amp frq
(set_lfo inst PARAM_LFO1 1.0 1.0 0.0 0)
(set_lfo inst PARAM_LFO2 1.0 1.0 0.0 0)
(set_lfo inst PARAM_LFO3 1.0 1.0 0.0 0)
(set_lfo inst PARAM_LFO4 1.0 1.0 0.0 0)
;; set LFO type
(set_lfo_type inst PARAM_LFO1 PARAM_SINE)
(set_lfo_type inst PARAM_LFO2 PARAM_SINE)
(set_lfo_type inst PARAM_LFO3 PARAM_SINE)
(set_lfo_type inst PARAM_LFO4 PARAM_SINE)
;;
;; mod matrix
;;
;; reset mod matrix - turn everything off
(dotimes (i 4) ;; 4 modulation sources
(doloop (j 32) ;; 32 modulation targets
(set_mod_matrix inst i j 0.0)))