00001
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #ifndef CSHELLSYNTH_LOWPASS_H
00031 #define CSHELLSYNTH_LOWPASS_H 1
00032
00033 #include <jack/jack.h>
00034 #include <cshellsynth/atomic-types.h>
00035 #include <cshellsynth/filter.h>
00036
00044 typedef struct cs_lowpass_struct {
00045 jack_client_t *client;
00046 jack_port_t *in_port;
00047 atomic_float_t in;
00048 jack_port_t *out_port;
00049 jack_port_t *freq_port;
00050 atomic_float_t freq;
00051 jack_port_t *Q_port;
00052 atomic_float_t Q;
00053 atomic_float_t atten;
00054 double x1;
00055 double x2;
00056 double y1;
00057 double y2;
00058 } cs_lowpass_t;
00059
00065 #define cs_lowpass_destroy(cs_lowpass) cs_filter_destroy((cs_filter_t *) (cs_lowpass))
00066
00072 int cs_lowpass_subclass_init(cs_lowpass_t *self, const char *client_name, jack_options_t flags, char *server_name);
00073
00079 int cs_lowpass_init(cs_lowpass_t *self, const char *client_name, jack_options_t flags, char *server_name);
00080
00084 #define cs_lowpass_set_in(self, in) cs_filter_set_in(self, in)
00085
00091 void cs_lowpass_set_freq(cs_lowpass_t *self, float freq);
00092
00098 void cs_lowpass_set_Q(cs_lowpass_t *self, float Q);
00099
00107 void cs_lowpass_set_atten(cs_lowpass_t *self, float atten);
00108
00109
00110 #endif