[PD-cvs] pd/src builtins_dsp.c,1.1.2.17,1.1.2.18
Mathieu Bouchard
matju at users.sourceforge.net
Tue Jan 9 21:09:04 CET 2007
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4363
Modified Files:
Tag: desiredata
builtins_dsp.c
Log Message:
introducing in() out() C++ methods in t_object
Index: builtins_dsp.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/builtins_dsp.c,v
retrieving revision 1.1.2.17
retrieving revision 1.1.2.18
diff -C2 -d -r1.1.2.17 -r1.1.2.18
*** builtins_dsp.c 9 Jan 2007 15:07:39 -0000 1.1.2.17
--- builtins_dsp.c 9 Jan 2007 20:09:02 -0000 1.1.2.18
***************
*** 350,354 ****
static t_class *tabplay_tilde_class;
struct t_tabplay_tilde : t_object {
- t_outlet *bangout;
int phase;
int nsampsintab;
--- 350,353 ----
***************
*** 366,370 ****
x->arrayname = s;
outlet_new(x, &s_signal);
! x->bangout = outlet_new(x, &s_bang);
return x;
}
--- 365,369 ----
x->arrayname = s;
outlet_new(x, &s_signal);
! outlet_new(x, &s_bang);
return x;
}
***************
*** 417,421 ****
}
static void tabplay_tilde_stop(t_tabplay_tilde *x) {x->phase = 0x7fffffff;}
! static void tabplay_tilde_tick(t_tabplay_tilde *x) {outlet_bang(x->bangout);}
static void tabplay_tilde_free(t_tabplay_tilde *x) {clock_free(x->clock);}
static void tabplay_tilde_setup() {
--- 416,420 ----
}
static void tabplay_tilde_stop(t_tabplay_tilde *x) {x->phase = 0x7fffffff;}
! static void tabplay_tilde_tick(t_tabplay_tilde *x) {outlet_bang(x->out(1));}
static void tabplay_tilde_free(t_tabplay_tilde *x) {clock_free(x->clock);}
static void tabplay_tilde_setup() {
***************
*** 1414,1418 ****
#define MAXVSTAKEN 64
struct t_sigenv : t_object {
- t_outlet *outlet; /* a "float" outlet */
t_clock *clock; /* a "clock" object */
float *buf; /* a Hanning window */
--- 1413,1416 ----
***************
*** 1570,1575 ****
static t_class *threshold_tilde_class;
struct t_threshold_tilde : t_object {
- t_outlet *outlet1; /* bang out for high thresh */
- t_outlet *outlet2; /* bang out for low thresh */
t_clock *clock; /* wakeup for message output */
float a; /* scalar inlet */
--- 1568,1571 ----
***************
*** 1597,1602 ****
x->deadwait = 0; /* no dead time */
x->clock = clock_new(x, threshold_tilde_tick);
! x->outlet1 = outlet_new(x, &s_bang);
! x->outlet2 = outlet_new(x, &s_bang);
inlet_new(x, x, &s_float, gensym("ft1"));
x->msecpertick = 0.;
--- 1593,1598 ----
x->deadwait = 0; /* no dead time */
x->clock = clock_new(x, threshold_tilde_tick);
! outlet_new(x, &s_bang);
! outlet_new(x, &s_bang);
inlet_new(x, x, &s_float, gensym("ft1"));
x->msecpertick = 0.;
***************
*** 1612,1617 ****
}
static void threshold_tilde_tick(t_threshold_tilde *x) {
! if (x->state) outlet_bang(x->outlet1);
! else outlet_bang(x->outlet2);
}
static t_int *threshold_tilde_perform(t_int *w) {
--- 1608,1612 ----
}
static void threshold_tilde_tick(t_threshold_tilde *x) {
! outlet_bang(x->out(x->state?0:1));
}
static t_int *threshold_tilde_perform(t_int *w) {
More information about the Pd-cvs
mailing list