Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23827/src
Modified Files:
Tag: devel_0_39
d_array.c d_ctl.c d_dac.c d_delay.c d_fftroutine.c
d_mayer_fft.c d_osc.c d_soundfile.c d_ugen.c desire.c
g_all_guis.h g_rtext.c m_atom.c m_binbuf.c m_class.c m_obj.c
m_pd.c m_sched.c s_audio.c s_audio_alsa.c s_audio_alsamm.c
s_audio_jack.c s_audio_oss.c s_audio_pa.c s_audio_pablio.c
s_file.c s_inter.c s_loader.c s_main.c s_midi.c s_midi_alsa.c
s_midi_oss.c s_path.c s_print.c t_main.c t_tkcmd.c
u_pdreceive.c x_connective.c x_gui.c x_interface.c x_list.c
x_midi.c x_net.c x_qlist.c x_time.c
Log Message:
reverting Matju's untested (and partly buggy) changes (see saved patch 1370034 in the patch tracker)
Index: m_binbuf.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_binbuf.c,v
retrieving revision 1.4.4.1.2.3
retrieving revision 1.4.4.1.2.4
diff -C2 -d -r1.4.4.1.2.3 -r1.4.4.1.2.4
*** m_binbuf.c 27 Nov 2005 23:13:13 -0000 1.4.4.1.2.3
--- m_binbuf.c 30 Nov 2005 13:36:57 -0000 1.4.4.1.2.4
***************
*** 78,81 ****
--- 78,82 ----
while (1)
{
+ int type;
/* skip leading space */
while ((textp != etext) && (*textp == ' ' || *textp == '\n'
***************
*** 235,240 ****
if (length && buf[length-1] == ' ')
{
! newbuf = (char *)t_resizebytes(buf, length, length-1);
! if (newbuf)
{
buf = newbuf;
--- 236,240 ----
if (length && buf[length-1] == ' ')
{
! if (newbuf = (char *)t_resizebytes(buf, length, length-1))
{
buf = newbuf;
***************
*** 253,259 ****
int newsize = x->b_n + argc, i;
t_atom *ap;
! ap = (t_atom *)t_resizebytes(x->b_vec, x->b_n * sizeof(*x->b_vec),
! newsize * sizeof(*x->b_vec));
! if (ap) x->b_vec = ap;
else
{
--- 253,259 ----
int newsize = x->b_n + argc, i;
t_atom *ap;
! if (ap = (t_atom *)t_resizebytes(x->b_vec, x->b_n * sizeof(*x->b_vec),
! newsize * sizeof(*x->b_vec)))
! x->b_vec = ap;
else
{
***************
*** 363,369 ****
int newsize = x->b_n + argc, i;
t_atom *ap;
! ap = (t_atom *)t_resizebytes(x->b_vec, x->b_n * sizeof(*x->b_vec),
! newsize * sizeof(*x->b_vec));
! if (ap) x->b_vec = ap;
else
{
--- 363,369 ----
int newsize = x->b_n + argc, i;
t_atom *ap;
! if (ap = (t_atom *)t_resizebytes(x->b_vec, x->b_n * sizeof(*x->b_vec),
! newsize * sizeof(*x->b_vec)))
! x->b_vec = ap;
else
{
***************
*** 607,611 ****
else pd_list(target, 0, nargs, stackwas);
break;
- default: error("binbuf_eval: d'oh");
}
}
--- 607,610 ----
Index: x_qlist.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_qlist.c,v
retrieving revision 1.2.8.2
retrieving revision 1.2.8.3
diff -C2 -d -r1.2.8.2 -r1.2.8.3
*** x_qlist.c 27 Nov 2005 07:57:10 -0000 1.2.8.2
--- x_qlist.c 30 Nov 2005 13:36:58 -0000 1.2.8.3
***************
*** 33,36 ****
--- 33,37 ----
static void *qlist_new( void)
{
+ t_symbol *name, *filename = 0;
t_qlist *x = (t_qlist *)pd_new(qlist_class);
x->x_binbuf = binbuf_new();
***************
*** 239,242 ****
--- 240,244 ----
static void *textfile_new( void)
{
+ t_symbol *name, *filename = 0;
t_textfile *x = (t_textfile *)pd_new(textfile_class);
x->x_binbuf = binbuf_new();
***************
*** 255,259 ****
static void textfile_bang(t_textfile *x)
{
! int argc = binbuf_getnatom(x->x_binbuf), onset = x->x_onset, onset2;
t_atom *argv = binbuf_getvec(x->x_binbuf);
t_atom *ap = argv + onset, *ap2;
--- 257,262 ----
static void textfile_bang(t_textfile *x)
{
! int argc = binbuf_getnatom(x->x_binbuf),
! count, onset = x->x_onset, onset2;
t_atom *argv = binbuf_getvec(x->x_binbuf);
t_atom *ap = argv + onset, *ap2;
Index: s_path.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_path.c,v
retrieving revision 1.3.4.6.2.4
retrieving revision 1.3.4.6.2.5
diff -C2 -d -r1.3.4.6.2.4 -r1.3.4.6.2.5
*** s_path.c 27 Nov 2005 23:15:45 -0000 1.3.4.6.2.4
--- s_path.c 30 Nov 2005 13:36:58 -0000 1.3.4.6.2.5
***************
*** 11,15 ****
*/
- #undef DEBUG
/* #define DEBUG(x) x */
#define DEBUG(x)
--- 11,14 ----
***************
*** 41,45 ****
{
char c;
! while ((c = *from++))
{
#ifdef MSW
--- 40,44 ----
{
char c;
! while (c = *from++)
{
#ifdef MSW
***************
*** 55,59 ****
{
char c;
! while ((c = *from++))
{
#ifdef MSW
--- 54,58 ----
{
char c;
! while (c = *from++)
{
#ifdef MSW
***************
*** 124,128 ****
const char *npos;
char temp[MAXPDSTRING];
! t_namelist *nl = listwas;
npos = s;
--- 123,127 ----
const char *npos;
char temp[MAXPDSTRING];
! t_namelist *nl = listwas, *rtn = listwas;
npos = s;
***************
*** 300,304 ****
#endif
{
! if (sys_verbose) post("tried %s and succeeded", dirresult);
sys_unbashfilename(dirresult, dirresult);
close (fd);
--- 299,304 ----
#endif
{
! char *slash;
! if (sys_verbose) post("tried %s and succeeded", dirresult);
sys_unbashfilename(dirresult, dirresult);
close (fd);
***************
*** 320,324 ****
void open_via_helppath(const char *name, const char *dir)
{
! t_namelist thislist, *listp;
char dirbuf2[MAXPDSTRING], realname[MAXPDSTRING];
--- 320,325 ----
void open_via_helppath(const char *name, const char *dir)
{
! t_namelist *nl, thislist, *listp;
! int fd = -1;
char dirbuf2[MAXPDSTRING], realname[MAXPDSTRING];
***************
*** 367,372 ****
--- 368,375 ----
FILE* file;
int i;
+ int k;
int rcargc;
char* rcargv[NUMARGS];
+ char* buffer;
char buf[1000];
char c[MAXPDSTRING];
Index: s_audio_alsamm.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_alsamm.c,v
retrieving revision 1.1.4.5.2.1
retrieving revision 1.1.4.5.2.2
diff -C2 -d -r1.1.4.5.2.1 -r1.1.4.5.2.2
*** s_audio_alsamm.c 27 Nov 2005 08:08:28 -0000 1.1.4.5.2.1
--- s_audio_alsamm.c 30 Nov 2005 13:36:58 -0000 1.1.4.5.2.2
***************
*** 82,91 ****
*/
- /*
static int alsamm_incards = 0;
static t_alsa_dev *alsamm_indevice[ALSA_MAXDEV];
static int alsamm_outcards = 0;
static t_alsa_dev *alsamm_outdevice[ALSA_MAXDEV];
- */
/*
--- 82,89 ----
***************
*** 160,169 ****
}
#else
! #undef DEBUG
! #define DEBUG(x)
! #define DEBUG2(x) {}
#endif
/* protos */
static int set_hwparams(snd_pcm_t *handle,
snd_pcm_hw_params_t *params, int *chs);
--- 158,168 ----
}
#else
! #define DEBUG(x)
! #define DEBUG2(x) {}
#endif
/* protos */
+ static char *alsamm_getdev(int nr);
+
static int set_hwparams(snd_pcm_t *handle,
snd_pcm_hw_params_t *params, int *chs);
***************
*** 186,189 ****
--- 185,190 ----
{
int err;
+ char devname[80];
+ char *cardname;
snd_pcm_hw_params_t* hw_params;
snd_pcm_sw_params_t* sw_params;
***************
*** 196,199 ****
--- 197,203 ----
int i;
+ short* tmp_buf;
+ unsigned int tmp_uint;
+
snd_pcm_hw_params_alloca(&hw_params);
snd_pcm_sw_params_alloca(&sw_params);
***************
*** 318,321 ****
--- 322,327 ----
for(i=0; i<(alsa_noutdev < alsa_nindev ? alsa_noutdev:alsa_nindev); i++){
+ t_alsa_dev *ad = &alsa_outdev[i];
+
if (alsa_outdev[i].a_devno == alsa_indev[i].a_devno){
if ((err = snd_pcm_link (alsa_indev[i].a_handle,
***************
*** 424,427 ****
--- 430,435 ----
unsigned int rrate;
int err, dir;
+ int channels_allocated = 0;
+
/* choose all parameters */
err = snd_pcm_hw_params_any(handle, params);
***************
*** 853,857 ****
int err = 0;
int devno;
! int chn;
#ifdef ALSAMM_DEBUG
if(sys_verbose)
--- 861,868 ----
int err = 0;
int devno;
! int chn,nchns;
!
! const snd_pcm_channel_area_t *mm_areas;
!
#ifdef ALSAMM_DEBUG
if(sys_verbose)
***************
*** 1057,1060 ****
--- 1068,1073 ----
t_sample *fpo, *fpi, *fp1, *fp2;
int i, err, devno;
+
+ const snd_pcm_channel_area_t *my_areas;
snd_pcm_sframes_t size;
snd_pcm_sframes_t commitres;
***************
*** 1356,1359 ****
--- 1369,1374 ----
int err;
snd_pcm_status_t *status;
+ snd_output_t *output = NULL;
+
snd_pcm_status_alloca(&status);
if ((err = snd_pcm_status(handle, status)) < 0) {
Index: g_rtext.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/g_rtext.c,v
retrieving revision 1.4.8.5
retrieving revision 1.4.8.6
diff -C2 -d -r1.4.8.5 -r1.4.8.6
*** g_rtext.c 27 Nov 2005 08:10:18 -0000 1.4.8.5
--- g_rtext.c 30 Nov 2005 13:36:57 -0000 1.4.8.6
***************
*** 48,51 ****
--- 48,52 ----
{
t_rtext *x = (t_rtext *)getbytes(sizeof *x);
+ int w = 0, h = 0, indx;
x->x_height = -1;
x->x_text = who;
***************
*** 301,304 ****
--- 302,306 ----
char *decimal = 0, *nextchar, *ebuf = x->x_buf + bufsize,
*s1, *s2;
+ int ndecimals;
for (decimal = x->x_buf; decimal < ebuf; decimal++)
if (*decimal == '.')
***************
*** 412,415 ****
--- 414,418 ----
{
int w = 0, h = 0, indx, i, newsize, ndel;
+ char *s1, *s2;
if (keynum)
{
Index: m_class.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_class.c,v
retrieving revision 1.3.4.7.2.10
retrieving revision 1.3.4.7.2.11
diff -C2 -d -r1.3.4.7.2.10 -r1.3.4.7.2.11
*** m_class.c 27 Nov 2005 23:13:13 -0000 1.3.4.7.2.10
--- m_class.c 30 Nov 2005 13:36:57 -0000 1.3.4.7.2.11
***************
*** 558,562 ****
sym1 = symhash + (hash2 & (HASHSIZE-1));
#endif
! while ((sym2 = *sym1))
{
if (!strcmp(sym2->s_name, s)) return(sym2);
--- 558,562 ----
sym1 = symhash + (hash2 & (HASHSIZE-1));
#endif
! while (sym2 = *sym1)
{
if (!strcmp(sym2->s_name, s)) return(sym2);
***************
*** 601,605 ****
}
! /*static t_symbol *addfileextent(t_symbol *s)
{
char namebuf[MAXPDSTRING], *str = s->s_name;
--- 601,605 ----
}
! static t_symbol *addfileextent(t_symbol *s)
{
char namebuf[MAXPDSTRING], *str = s->s_name;
***************
*** 609,613 ****
strcpy(namebuf+ln, ".pd");
return (gensym(namebuf));
! }*/
static int tryingalready;
--- 609,613 ----
strcpy(namebuf+ln, ".pd");
return (gensym(namebuf));
! }
static int tryingalready;
***************
*** 721,724 ****
--- 721,725 ----
void pd_typedmess(t_pd *x, t_symbol *s, int argc, t_atom *argv)
{
+ t_method *f;
t_class *c = *x;
t_methodentry *m;
***************
*** 772,776 ****
if (argc > MAXPDARG) argc = MAXPDARG;
if (x != &pd_objectmaker) *(ap++) = (t_int)x, narg++;
! while ((wanttype = *wp++))
{
switch (wanttype)
--- 773,777 ----
if (argc > MAXPDARG) argc = MAXPDARG;
if (x != &pd_objectmaker) *(ap++) = (t_int)x, narg++;
! while (wanttype = *wp++)
{
switch (wanttype)
***************
*** 824,828 ****
narg++;
ap++;
- default: error("pd_typedmess: d'oh");
}
}
--- 825,828 ----
Index: x_interface.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_interface.c,v
retrieving revision 1.2.8.1
retrieving revision 1.2.8.2
diff -C2 -d -r1.2.8.1 -r1.2.8.2
*** x_interface.c 27 Nov 2005 07:57:10 -0000 1.2.8.1
--- x_interface.c 30 Nov 2005 13:36:58 -0000 1.2.8.2
***************
*** 41,44 ****
--- 41,46 ----
static void print_list(t_print *x, t_symbol *s, int argc, t_atom *argv)
{
+ int i;
+ char buf[80];
if (argc && argv->a_type != A_SYMBOL) startpost("%s:", x->x_sym->s_name);
else startpost("%s: %s", x->x_sym->s_name,
***************
*** 51,54 ****
--- 53,58 ----
static void print_anything(t_print *x, t_symbol *s, int argc, t_atom *argv)
{
+ int i;
+ char buf[80];
startpost("%s: %s", x->x_sym->s_name, s->s_name);
postatom(argc, argv);
Index: x_list.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_list.c,v
retrieving revision 1.2.2.6
retrieving revision 1.2.2.7
diff -C2 -d -r1.2.2.6 -r1.2.2.7
*** x_list.c 27 Nov 2005 07:57:10 -0000 1.2.2.6
--- x_list.c 30 Nov 2005 13:36:58 -0000 1.2.2.7
***************
*** 196,200 ****
{
t_atom *outv;
! int outc = x->x_alist.l_n + argc;
ATOMS_ALLOCA(outv, outc);
atoms_copy(argc, argv, outv);
--- 196,200 ----
{
t_atom *outv;
! int n, outc = x->x_alist.l_n + argc;
ATOMS_ALLOCA(outv, outc);
atoms_copy(argc, argv, outv);
***************
*** 208,212 ****
{
t_atom *outv;
! int outc = x->x_alist.l_n + argc + 1;
ATOMS_ALLOCA(outv, outc);
SETSYMBOL(outv, s);
--- 208,212 ----
{
t_atom *outv;
! int n, outc = x->x_alist.l_n + argc + 1;
ATOMS_ALLOCA(outv, outc);
SETSYMBOL(outv, s);
***************
*** 256,260 ****
{
t_atom *outv;
! int outc = x->x_alist.l_n + argc;
ATOMS_ALLOCA(outv, outc);
alist_toatoms(&x->x_alist, outv);
--- 256,260 ----
{
t_atom *outv;
! int n, outc = x->x_alist.l_n + argc;
ATOMS_ALLOCA(outv, outc);
alist_toatoms(&x->x_alist, outv);
***************
*** 268,272 ****
{
t_atom *outv;
! int outc = x->x_alist.l_n + argc + 1;
ATOMS_ALLOCA(outv, outc);
alist_toatoms(&x->x_alist, outv);
--- 268,272 ----
{
t_atom *outv;
! int n, outc = x->x_alist.l_n + argc + 1;
ATOMS_ALLOCA(outv, outc);
alist_toatoms(&x->x_alist, outv);
Index: d_fftroutine.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_fftroutine.c,v
retrieving revision 1.2.8.2
retrieving revision 1.2.8.3
diff -C2 -d -r1.2.8.2 -r1.2.8.3
*** d_fftroutine.c 27 Nov 2005 07:59:05 -0000 1.2.8.2
--- d_fftroutine.c 30 Nov 2005 13:36:57 -0000 1.2.8.3
***************
*** 281,285 ****
net_dealloc(thisnet);
free((char *)thisnet);
! } while ((thisnet = nextnet));
}
}
--- 281,285 ----
net_dealloc(thisnet);
free((char *)thisnet);
! } while (thisnet = nextnet);
}
}
***************
*** 487,491 ****
int *load_index = fft_net->load_index;
SAMPLE *window;
! int index, i = 0;
if (trnsfrm_dir==FORWARD) window = fft_net->window;
--- 487,491 ----
int *load_index = fft_net->load_index;
SAMPLE *window;
! int index, i = 0, n = fft_net->n;
if (trnsfrm_dir==FORWARD) window = fft_net->window;
***************
*** 618,622 ****
{
int i;
! SAMPLE real, imag;
int n;
--- 618,622 ----
{
int i;
! SAMPLE real, imag, mag, phase;
int n;
***************
*** 991,995 ****
{
double renorm;
! float *fp;
int i;
renorm = (inverse ? npoints : 1.);
--- 991,995 ----
{
double renorm;
! float *fp, *fp2;
int i;
renorm = (inverse ? npoints : 1.);
Index: s_print.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_print.c,v
retrieving revision 1.2.4.1.2.1
retrieving revision 1.2.4.1.2.2
diff -C2 -d -r1.2.4.1.2.1 -r1.2.4.1.2.2
*** s_print.c 27 Nov 2005 08:12:10 -0000 1.2.4.1.2.1
--- s_print.c 30 Nov 2005 13:36:58 -0000 1.2.4.1.2.2
***************
*** 46,49 ****
--- 46,51 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
va_start(ap, fmt);
vsnprintf(buf, MAXPDSTRING-1, fmt, ap);
***************
*** 57,60 ****
--- 59,64 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
va_start(ap, fmt);
vsnprintf(buf, MAXPDSTRING-1, fmt, ap);
***************
*** 82,85 ****
--- 86,90 ----
void postfloat(float f)
{
+ char buf[80];
t_atom a;
SETFLOAT(&a, f);
***************
*** 96,99 ****
--- 101,106 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
dopost("error: ");
va_start(ap, fmt);
***************
*** 108,111 ****
--- 115,120 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
if(level>sys_verbose)return;
dopost("verbose(");
***************
*** 132,135 ****
--- 141,146 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
static int saidit;
dopost("error: ");
***************
*** 163,166 ****
--- 174,179 ----
char buf[MAXPDSTRING];
va_list ap;
+ t_int arg[8];
+ int i;
dopost("consistency check failed: ");
va_start(ap, fmt);
Index: x_gui.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_gui.c,v
retrieving revision 1.3.4.1.2.4
retrieving revision 1.3.4.1.2.5
diff -C2 -d -r1.3.4.1.2.4 -r1.3.4.1.2.5
*** x_gui.c 27 Nov 2005 07:57:10 -0000 1.3.4.1.2.4
--- x_gui.c 30 Nov 2005 13:36:58 -0000 1.3.4.1.2.5
***************
*** 86,90 ****
if (gfxstub_list == x)
gfxstub_list = x->x_next;
! else for (y1 = gfxstub_list; (y2 = y1->x_next); y1 = y2)
if (y2 == x)
{
--- 86,90 ----
if (gfxstub_list == x)
gfxstub_list = x->x_next;
! else for (y1 = gfxstub_list; y2 = y1->x_next; y1 = y2)
if (y2 == x)
{
Index: m_atom.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_atom.c,v
retrieving revision 1.2.8.1
retrieving revision 1.2.8.2
diff -C2 -d -r1.2.8.1 -r1.2.8.2
*** m_atom.c 27 Nov 2005 08:10:18 -0000 1.2.8.1
--- m_atom.c 30 Nov 2005 13:36:57 -0000 1.2.8.2
***************
*** 24,27 ****
--- 24,28 ----
t_symbol *atom_getsymbol(t_atom *a) /* LATER think about this more carefully */
{
+ char buf[30];
if (a->a_type == A_SYMBOL) return (a->a_w.w_symbol);
else return (&s_float);
Index: m_obj.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_obj.c,v
retrieving revision 1.2.4.3.2.4
retrieving revision 1.2.4.3.2.5
diff -C2 -d -r1.2.4.3.2.4 -r1.2.4.3.2.5
*** m_obj.c 27 Nov 2005 08:14:14 -0000 1.2.4.3.2.4
--- m_obj.c 30 Nov 2005 13:36:58 -0000 1.2.4.3.2.5
***************
*** 72,78 ****
x->i_next = 0;
x->i_tip = gensym("?");
! if ((y = owner->ob_inlet))
{
! while ((y2 = y->i_next)) y = y2;
y->i_next = x;
}
--- 72,78 ----
x->i_next = 0;
x->i_tip = gensym("?");
! if (y = owner->ob_inlet)
{
! while (y2 = y->i_next) y = y2;
y->i_next = x;
}
***************
*** 155,158 ****
--- 155,159 ----
static void inlet_list(t_inlet *x, t_symbol *s, int argc, t_atom *argv)
{
+ t_atom at;
if (x->i_symfrom == &s_list || x->i_symfrom == &s_float
|| x->i_symfrom == &s_symbol || x->i_symfrom == &s_pointer)
***************
*** 202,208 ****
x->i_pointerslot = gp;
x->i_next = 0;
! if ((y = owner->ob_inlet))
{
! while ((y2 = y->i_next)) y = y2;
y->i_next = x;
}
--- 203,209 ----
x->i_pointerslot = gp;
x->i_next = 0;
! if (y = owner->ob_inlet)
{
! while (y2 = y->i_next) y = y2;
y->i_next = x;
}
***************
*** 224,230 ****
x->i_floatslot = fp;
x->i_next = 0;
! if ((y = owner->ob_inlet))
{
! while ((y2 = y->i_next)) y = y2;
y->i_next = x;
}
--- 225,231 ----
x->i_floatslot = fp;
x->i_next = 0;
! if (y = owner->ob_inlet)
{
! while (y2 = y->i_next) y = y2;
y->i_next = x;
}
***************
*** 246,252 ****
x->i_symslot = sp;
x->i_next = 0;
! if ((y = owner->ob_inlet))
{
! while ((y2 = y->i_next)) y = y2;
y->i_next = x;
}
--- 247,253 ----
x->i_symslot = sp;
x->i_next = 0;
! if (y = owner->ob_inlet)
{
! while (y2 = y->i_next) y = y2;
y->i_next = x;
}
***************
*** 354,360 ****
x->o_owner = owner;
x->o_next = 0;
! if ((y = owner->ob_outlet))
{
! while ((y2 = y->o_next)) y = y2;
y->o_next = x;
}
--- 355,361 ----
x->o_owner = owner;
x->o_next = 0;
! if (y = owner->ob_outlet)
{
! while (y2 = y->o_next) y = y2;
y->o_next = x;
}
***************
*** 580,584 ****
goto done;
}
! while ((oc2 = oc->oc_next))
{
if (oc2->oc_to == to)
--- 581,585 ----
goto done;
}
! while (oc2 = oc->oc_next)
{
if (oc2->oc_to == to)
Index: g_all_guis.h
===================================================================
RCS file: /cvsroot/pure-data/pd/src/g_all_guis.h,v
retrieving revision 1.4.8.3
retrieving revision 1.4.8.4
diff -C2 -d -r1.4.8.3 -r1.4.8.4
*** g_all_guis.h 27 Nov 2005 23:13:12 -0000 1.4.8.3
--- g_all_guis.h 30 Nov 2005 13:36:57 -0000 1.4.8.4
***************
*** 245,250 ****
float x_fr;
int x_scale;
! t_outlet *x_out_rms;
! t_outlet *x_out_peak;
unsigned int x_updaterms:1;
unsigned int x_updatepeak:1;
--- 245,250 ----
float x_fr;
int x_scale;
! void *x_out_rms;
! void *x_out_peak;
unsigned int x_updaterms:1;
unsigned int x_updatepeak:1;
Index: s_audio_pablio.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_pablio.c,v
retrieving revision 1.1.4.2.2.2
retrieving revision 1.1.4.2.2.3
diff -C2 -d -r1.1.4.2.2.2 -r1.1.4.2.2.3
*** s_audio_pablio.c 27 Nov 2005 23:14:02 -0000 1.1.4.2.2.2
--- s_audio_pablio.c 30 Nov 2005 13:36:58 -0000 1.1.4.2.2.3
***************
*** 194,206 ****
/************************************************************/
- /*
static unsigned long RoundUpToNextPowerOf2( unsigned long n )
{
long numBits = 0;
! if( ((n-1) & n) == 0) return n; // Already Power of two.
! while(n>0) {n>>=1; numBits++;}
return (1<<numBits);
}
- */
/************************************************************
--- 194,208 ----
/************************************************************/
static unsigned long RoundUpToNextPowerOf2( unsigned long n )
{
long numBits = 0;
! if( ((n-1) & n) == 0) return n; /* Already Power of two. */
! while( n > 0 )
! {
! n= n>>1;
! numBits++;
! }
return (1<<numBits);
}
/************************************************************
***************
*** 221,229 ****
PaError err;
PABLIO_Stream *aStream;
long numFrames;
#ifdef PA19
PaStreamParameters instreamparams, outstreamparams; /* MSP */
- #else
- long minNumBuffers;
#endif
--- 223,230 ----
PaError err;
PABLIO_Stream *aStream;
+ long minNumBuffers;
long numFrames;
#ifdef PA19
PaStreamParameters instreamparams, outstreamparams; /* MSP */
#endif
Index: s_audio_alsa.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_alsa.c,v
retrieving revision 1.5.4.5.2.1
retrieving revision 1.5.4.5.2.2
diff -C2 -d -r1.5.4.5.2.1 -r1.5.4.5.2.2
*** s_audio_alsa.c 27 Nov 2005 08:08:28 -0000 1.5.4.5.2.1
--- s_audio_alsa.c 30 Nov 2005 13:36:58 -0000 1.5.4.5.2.2
***************
*** 28,32 ****
/* Defines */
- #undef DEBUG
#define DEBUG(x) x
#define DEBUG2(x) {x;}
--- 28,31 ----
***************
*** 231,239 ****
int *choutdev, int rate)
{
! int err, inchans = 0, outchans = 0;
char devname[512];
int frag_size = (sys_blocksize ? sys_blocksize : ALSA_DEFFRAGSIZE);
! int i, iodev, dev2;
! int nfrags = sys_schedadvance * (float)rate / (1e6 * frag_size);
/* save our belief as to ALSA's buffer size for later */
alsa_buf_samps = nfrags * frag_size;
--- 230,241 ----
int *choutdev, int rate)
{
! int err, inchans = 0, outchans = 0, subunitdir;
char devname[512];
+ snd_output_t* out;
int frag_size = (sys_blocksize ? sys_blocksize : ALSA_DEFFRAGSIZE);
! int nfrags, i, iodev, dev2;
! int wantinchans, wantoutchans, device;
!
! nfrags = sys_schedadvance * (float)rate / (1e6 * frag_size);
/* save our belief as to ALSA's buffer size for later */
alsa_buf_samps = nfrags * frag_size;
***************
*** 386,391 ****
static double timenow;
double timelast;
! t_sample *fp1, *fp2;
! int i, j, k, iodev, result, ch;
int chansintogo, chansouttogo;
unsigned int transfersize;
--- 388,393 ----
static double timenow;
double timelast;
! t_sample *fp, *fp1, *fp2;
! int i, j, k, err, iodev, result, ch;
int chansintogo, chansouttogo;
unsigned int transfersize;
***************
*** 562,566 ****
void alsa_printstate( void)
{
! int result, iodev = 0;
snd_pcm_sframes_t indelay, outdelay;
if (sys_audioapi != API_ALSA)
--- 564,568 ----
void alsa_printstate( void)
{
! int i, result, iodev = 0;
snd_pcm_sframes_t indelay, outdelay;
if (sys_audioapi != API_ALSA)
***************
*** 646,650 ****
static void alsa_checkiosync( void)
{
! int result, giveup = 1000, alreadylogged = 0, iodev = 0;
snd_pcm_sframes_t minphase, maxphase, thisphase, outdelay;
--- 648,652 ----
static void alsa_checkiosync( void)
{
! int i, result, giveup = 1000, alreadylogged = 0, iodev = 0;
snd_pcm_sframes_t minphase, maxphase, thisphase, outdelay;
Index: desire.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v
retrieving revision 1.1.2.61
retrieving revision 1.1.2.62
diff -C2 -d -r1.1.2.61 -r1.1.2.62
*** desire.c 24 Nov 2005 23:18:02 -0000 1.1.2.61
--- desire.c 30 Nov 2005 13:36:57 -0000 1.1.2.62
***************
*** 11839,11842 ****
--- 11839,11843 ----
i+=snprintf(buf+i,n-i,"\n");
if (i>=n) goto over;
+
sys_gui(buf);
return;
Index: x_time.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_time.c,v
retrieving revision 1.2.8.2
retrieving revision 1.2.8.3
diff -C2 -d -r1.2.8.2 -r1.2.8.3
*** x_time.c 27 Nov 2005 23:16:19 -0000 1.2.8.2
--- x_time.c 30 Nov 2005 13:36:58 -0000 1.2.8.3
***************
*** 428,432 ****
union word *w;
if (x->x_hang == h) x->x_hang = h->h_next;
! else for (h2 = x->x_hang; (h3 = h2->h_next); h2 = h3)
{
if (h3 == h)
--- 428,432 ----
union word *w;
if (x->x_hang == h) x->x_hang = h->h_next;
! else for (h2 = x->x_hang; h3 = h2->h_next; h2 = h3)
{
if (h3 == h)
***************
*** 448,452 ****
else post("pipe: stale pointer");
break;
- default: error("hang_tick: huh?");
}
}
--- 448,451 ----
***************
*** 482,486 ****
}
gp++;
- default: error("pipe_list: huh?");
}
}
--- 481,484 ----
***************
*** 511,515 ****
{
t_hang *hang;
! while ((hang = x->x_hang))
{
x->x_hang = hang->h_next;
--- 509,513 ----
{
t_hang *hang;
! while (hang = x->x_hang)
{
x->x_hang = hang->h_next;
Index: x_net.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_net.c,v
retrieving revision 1.2.4.2.2.1
retrieving revision 1.2.4.2.2.2
diff -C2 -d -r1.2.4.2.2.1 -r1.2.4.2.2.2
*** x_net.c 27 Nov 2005 07:57:10 -0000 1.2.4.2.2.1
--- x_net.c 30 Nov 2005 13:36:58 -0000 1.2.4.2.2.2
***************
*** 201,204 ****
--- 201,205 ----
static void netreceive_doit(void *z, t_binbuf *b)
{
+ t_atom messbuf[1024];
t_netreceive *x = (t_netreceive *)z;
int msg, natom = binbuf_getnatom(b);
Index: d_ctl.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_ctl.c,v
retrieving revision 1.3.4.12.2.2
retrieving revision 1.3.4.12.2.3
diff -C2 -d -r1.3.4.12.2.2 -r1.3.4.12.2.3
*** d_ctl.c 27 Nov 2005 07:59:05 -0000 1.3.4.12.2.2
--- d_ctl.c 30 Nov 2005 13:36:57 -0000 1.3.4.12.2.3
***************
*** 202,206 ****
if (x->x_ticksleft)
{
! line_tilde_slope(out, n, &x->x_value, x->x_slopes, &x->x_slopestep);
x->x_value += x->x_biginc;
x->x_ticksleft--;
--- 202,207 ----
if (x->x_ticksleft)
{
! float f = x->x_value;
! line_tilde_slope(out, n, &x->x_value, x->x_slopes, &x->x_slopestep);
x->x_value += x->x_biginc;
x->x_ticksleft--;
***************
*** 243,247 ****
if (x->x_ticksleft)
{
! line_tilde_slope_simd(out, n, &x->x_value, x->x_slopes, &x->x_slopestep);
x->x_value += x->x_biginc;
x->x_ticksleft--;
--- 244,249 ----
if (x->x_ticksleft)
{
! float f = x->x_value;
! line_tilde_slope_simd(out, n, &x->x_value, x->x_slopes, &x->x_slopestep);
x->x_value += x->x_biginc;
x->x_ticksleft--;
***************
*** 355,358 ****
--- 357,361 ----
double inc = x->x_inc;
double msecpersamp = x->x_msecpersamp;
+ double samppermsec = x->x_samppermsec;
double timenow = clock_gettimesince(x->x_referencetime) - n * msecpersamp;
t_vseg *s = x->x_list;
***************
*** 443,447 ****
else
{
! for (s1 = x->x_list; (s2 = s1->s_next); s1 = s2)
{
if (s2->s_starttime > starttime ||
--- 446,450 ----
else
{
! for (s1 = x->x_list; s2 = s1->s_next; s1 = s2)
{
if (s2->s_starttime > starttime ||
Index: d_soundfile.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_soundfile.c,v
retrieving revision 1.4.4.11.2.8
retrieving revision 1.4.4.11.2.9
diff -C2 -d -r1.4.4.11.2.8 -r1.4.4.11.2.9
*** d_soundfile.c 27 Nov 2005 07:59:05 -0000 1.4.4.11.2.8
--- d_soundfile.c 30 Nov 2005 13:36:57 -0000 1.4.4.11.2.9
***************
*** 206,210 ****
{
char buf[OBUFSIZE], *bufptr;
! int fd, nchannels, bigendian, bytespersamp, swap, sysrtn;
long bytelimit = 0x7fffffff;
errno = 0;
--- 206,210 ----
{
char buf[OBUFSIZE], *bufptr;
! int fd, format, nchannels, bigendian, bytespersamp, swap, sysrtn;
long bytelimit = 0x7fffffff;
errno = 0;
***************
*** 247,251 ****
if (format == FORMAT_NEXT) /* nextstep header */
{
! if (bytesread < (int)sizeof(t_nextstep))
goto badheader;
nchannels = swap4(((t_nextstep *)buf)->ns_nchans, swap);
--- 247,252 ----
if (format == FORMAT_NEXT) /* nextstep header */
{
! uint32 param;
! if (bytesread < (int)sizeof(t_nextstep))
goto badheader;
nchannels = swap4(((t_nextstep *)buf)->ns_nchans, swap);
***************
*** 1880,1884 ****
int headersize = -1, channels = 0, bytespersamp = 0, bigendian = 0,
resize = 0, i, j;
! long skipframes = 0, nframes = 0, finalsize = 0,
maxsize = DEFMAXSIZE, itemsread = 0, bytelimit = 0x7fffffff;
int fd = -1;
--- 1881,1885 ----
int headersize = -1, channels = 0, bytespersamp = 0, bigendian = 0,
resize = 0, i, j;
! long skipframes = 0, nframes = 0, finalsize = 0, itemsleft,
maxsize = DEFMAXSIZE, itemsread = 0, bytelimit = 0x7fffffff;
int fd = -1;
***************
*** 2040,2044 ****
for (i = 0; i < argc; i++)
{
! int vecsize;
garray_getfloatarray(garrays[i], &vecsize, &vecs[i]);
for (j = itemsread; j < vecsize; j++)
--- 2041,2045 ----
for (i = 0; i < argc; i++)
{
! int nzero, vecsize;
garray_getfloatarray(garrays[i], &vecsize, &vecs[i]);
for (j = itemsread; j < vecsize; j++)
***************
*** 2076,2085 ****
int argc, t_atom *argv)
{
! int bytespersamp, bigendian, swap, filetype, normalize, i, j, nchannels;
! long onset, nframes, itemswritten = 0;
t_garray *garrays[MAXSFCHANS];
t_float *vecs[MAXSFCHANS];
char sampbuf[SAMPBUFSIZE];
! int bufframes;
int fd = -1;
float normfactor, biggest = 0, samplerate;
--- 2077,2088 ----
int argc, t_atom *argv)
{
! int headersize, bytespersamp, bigendian,
! endianness, swap, filetype, normalize, i, j, nchannels;
! long onset, nframes, itemsleft,
! maxsize = DEFMAXSIZE, itemswritten = 0;
t_garray *garrays[MAXSFCHANS];
t_float *vecs[MAXSFCHANS];
char sampbuf[SAMPBUFSIZE];
! int bufframes, nitems;
int fd = -1;
float normfactor, biggest = 0, samplerate;
***************
*** 2150,2154 ****
for (itemswritten = 0; itemswritten < nframes; )
{
! int thiswrite = nframes - itemswritten, nbytes;
thiswrite = (thiswrite > bufframes ? bufframes : thiswrite);
soundfile_xferout(argc, vecs, (unsigned char *)sampbuf, thiswrite,
--- 2153,2157 ----
for (itemswritten = 0; itemswritten < nframes; )
{
! int thiswrite = nframes - itemswritten, nitems, nbytes;
thiswrite = (thiswrite > bufframes ? bufframes : thiswrite);
soundfile_xferout(argc, vecs, (unsigned char *)sampbuf, thiswrite,
***************
*** 2348,2351 ****
--- 2351,2355 ----
else if (x->x_requestcode == REQUEST_OPEN)
{
+ char boo[80];
int sysrtn, wantbytes;
***************
*** 2664,2668 ****
if (x->x_state == STATE_STREAM)
{
! int wantbytes, sfchannels = x->x_sfchannels;
pthread_mutex_lock(&x->x_mutex);
wantbytes = sfchannels * vecsize * bytespersample;
--- 2668,2672 ----
if (x->x_state == STATE_STREAM)
{
! int wantbytes, nchannels, sfchannels = x->x_sfchannels;
pthread_mutex_lock(&x->x_mutex);
wantbytes = sfchannels * vecsize * bytespersample;
***************
*** 2730,2733 ****
--- 2734,2738 ----
else
{
+ idle:
for (i = 0; i < noutlets; i++)
for (j = vecsize, fp = x->x_outvec[i]; j--; )
***************
*** 2896,2907 ****
else if (x->x_requestcode == REQUEST_OPEN)
{
int fd, sysrtn, writebytes;
/* copy file stuff out of the data structure so we can
relinquish the mutex while we're in open_soundfile(). */
int bytespersample = x->x_bytespersample;
int sfchannels = x->x_sfchannels;
int filetype = x->x_filetype;
- int bigendian = x->x_bigendian;
char *filename = x->x_filename;
t_canvas *canvas = x->x_canvas;
--- 2901,2916 ----
else if (x->x_requestcode == REQUEST_OPEN)
{
+ char boo[80];
int fd, sysrtn, writebytes;
/* copy file stuff out of the data structure so we can
relinquish the mutex while we're in open_soundfile(). */
+ long onsetframes = x->x_onsetframes;
+ long bytelimit = 0x7fffffff;
+ int skipheaderbytes = x->x_skipheaderbytes;
int bytespersample = x->x_bytespersample;
int sfchannels = x->x_sfchannels;
+ int bigendian = x->x_bigendian;
int filetype = x->x_filetype;
char *filename = x->x_filename;
t_canvas *canvas = x->x_canvas;
***************
*** 2922,2925 ****
--- 2931,2935 ----
{
int bytesperframe = x->x_bytespersample * x->x_sfchannels;
+ int bigendian = x->x_bigendian;
char *filename = x->x_filename;
int fd = x->x_fd;
***************
*** 2949,2953 ****
pthread_mutex_unlock(&x->x_mutex);
fd = create_soundfile(canvas, filename, filetype, 0,
! bytespersample, x->x_bigendian, sfchannels,
garray_ambigendian() != bigendian, samplerate);
pthread_mutex_lock(&x->x_mutex);
--- 2959,2963 ----
pthread_mutex_unlock(&x->x_mutex);
fd = create_soundfile(canvas, filename, filetype, 0,
! bytespersample, bigendian, sfchannels,
garray_ambigendian() != bigendian, samplerate);
pthread_mutex_lock(&x->x_mutex);
***************
*** 3063,3066 ****
--- 3073,3077 ----
{
int bytesperframe = x->x_bytespersample * x->x_sfchannels;
+ int bigendian = x->x_bigendian;
char *filename = x->x_filename;
int fd = x->x_fd;
***************
*** 3099,3102 ****
--- 3110,3115 ----
/******** the object proper runs in the calling (parent) thread ****/
+ static void writesf_tick(t_writesf *x);
+
static void *writesf_new(t_floatarg fnchannels, t_floatarg fbufsize)
{
***************
*** 3144,3150 ****
{
t_writesf *x = (t_writesf *)(w[1]);
! int vecsize = x->x_vecsize, sfchannels = x->x_sfchannels,
bytespersample = x->x_bytespersample,
bigendian = x->x_bigendian;
if (x->x_state == STATE_STREAM)
{
--- 3157,3164 ----
{
t_writesf *x = (t_writesf *)(w[1]);
! int vecsize = x->x_vecsize, sfchannels = x->x_sfchannels, i, j,
bytespersample = x->x_bytespersample,
bigendian = x->x_bigendian;
+ float *fp;
if (x->x_state == STATE_STREAM)
{
Index: s_audio.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio.c,v
retrieving revision 1.5.4.16.2.3
retrieving revision 1.5.4.16.2.4
diff -C2 -d -r1.5.4.16.2.3 -r1.5.4.16.2.4
*** s_audio.c 27 Nov 2005 08:08:28 -0000 1.5.4.16.2.3
--- s_audio.c 30 Nov 2005 13:36:58 -0000 1.5.4.16.2.4
***************
*** 145,148 ****
--- 145,149 ----
void sys_setchsr(int chin, int chout, int sr, int dacblocksize)
{
+ int nblk;
int inbytes;
int outbytes;
***************
*** 199,203 ****
int *choutdev, int rate, int dacblocksize, int advance, int schedmode, int enable)
{
! int i;
int defaultchannels = SYS_DEFAULTCH;
int inchans, outchans;
--- 200,204 ----
int *choutdev, int rate, int dacblocksize, int advance, int schedmode, int enable)
{
! int i, *ip;
int defaultchannels = SYS_DEFAULTCH;
int inchans, outchans;
***************
*** 350,356 ****
if (sys_audioapi == API_PORTAUDIO)
{
pa_open_audio(inchans, outchans, rate, advance,
! (naudiooutdev > 0 ? audioindev[0] : 0),
! (naudiooutdev > 0 ? audiooutdev[0] : 0), schedmode);
}
else
--- 351,359 ----
if (sys_audioapi == API_PORTAUDIO)
{
+ int blksize = (sys_blocksize ? sys_blocksize : 64);
pa_open_audio(inchans, outchans, rate, advance,
! (naudiooutdev > 0 ? audioindev[0] : 0),
! (naudiooutdev > 0 ? audiooutdev[0] : 0),
! schedmode);
}
else
***************
*** 780,784 ****
void glob_audio_dialog(t_pd *dummy, t_symbol *s, int argc, t_atom *argv)
{
! int i, nindev, noutdev;
int newaudioindev[4], newaudioinchan[4],
newaudiooutdev[4], newaudiooutchan[4];
--- 783,790 ----
void glob_audio_dialog(t_pd *dummy, t_symbol *s, int argc, t_atom *argv)
{
! int naudioindev, audioindev[MAXAUDIOINDEV], chindev[MAXAUDIOINDEV];
! int naudiooutdev, audiooutdev[MAXAUDIOOUTDEV], choutdev[MAXAUDIOOUTDEV];
! int rate, dacblocksize, advance, audioon, i, nindev, noutdev;
! int audioindev1, audioinchan1, audiooutdev1, audiooutchan1;
int newaudioindev[4], newaudioinchan[4],
newaudiooutdev[4], newaudiooutchan[4];
***************
*** 788,791 ****
--- 794,798 ----
int newadvance = atom_getintarg(18, argc, argv);
int newschedmode = atom_getintarg(19, argc, argv);
+ int statewas;
for (i = 0; i < 4; i++)
***************
*** 803,806 ****
--- 810,815 ----
newaudioindev[nindev] = newaudioindev[i];
newaudioinchan[nindev] = newaudioinchan[i];
+ /* post("in %d %d %d", nindev,
+ newaudioindev[nindev] , newaudioinchan[nindev]); */
nindev++;
}
***************
*** 812,815 ****
--- 821,826 ----
newaudiooutdev[noutdev] = newaudiooutdev[i];
newaudiooutchan[noutdev] = newaudiooutchan[i];
+ /* post("out %d %d %d", noutdev,
+ newaudiooutdev[noutdev] , newaudioinchan[noutdev]); */
noutdev++;
}
Index: d_osc.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_osc.c,v
retrieving revision 1.2.4.1.2.3
retrieving revision 1.2.4.1.2.4
diff -C2 -d -r1.2.4.1.2.3 -r1.2.4.1.2.4
*** d_osc.c 27 Nov 2005 07:59:05 -0000 1.2.4.1.2.3
--- d_osc.c 30 Nov 2005 13:36:57 -0000 1.2.4.1.2.4
***************
*** 64,68 ****
/* -------------------------- phasor~ ------------------------------ */
! static t_class *phasor_class;
#if 1 /* in the style of R. Hoeldrich (ICMC 1995 Banff) */
--- 64,68 ----
/* -------------------------- phasor~ ------------------------------ */
! static t_class *phasor_class, *scalarphasor_class;
#if 1 /* in the style of R. Hoeldrich (ICMC 1995 Banff) */
***************
*** 243,247 ****
/* ------------------------ osc~ ----------------------------- */
! static t_class *osc_class;
typedef struct _osc
--- 243,247 ----
/* ------------------------ osc~ ----------------------------- */
! static t_class *osc_class, *scalarosc_class;
typedef struct _osc
Index: x_midi.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_midi.c,v
retrieving revision 1.2.8.2
retrieving revision 1.2.8.3
diff -C2 -d -r1.2.8.2 -r1.2.8.3
*** x_midi.c 27 Nov 2005 23:16:47 -0000 1.2.8.2
--- x_midi.c 30 Nov 2005 13:36:58 -0000 1.2.8.3
***************
*** 571,575 ****
static float prev = 0;
static float count = 0;
! float diff;
if (midiclkin_sym->s_thing)
--- 571,575 ----
static float prev = 0;
static float count = 0;
! float cur,diff;
if (midiclkin_sym->s_thing)
***************
*** 962,966 ****
outlet_float(x->x_pitchout, hang->h_pitch);
if (x->x_hang == hang) x->x_hang = hang->h_next;
! else for (h2 = x->x_hang; (h3 = h2->h_next); h2 = h3)
{
if (h3 == hang)
--- 962,966 ----
outlet_float(x->x_pitchout, hang->h_pitch);
if (x->x_hang == hang) x->x_hang = hang->h_next;
! else for (h2 = x->x_hang; h3 = h2->h_next; h2 = h3)
{
if (h3 == hang)
***************
*** 992,996 ****
{
t_hang *hang;
! while ((hang = x->x_hang))
{
outlet_float(x->x_velout, 0);
--- 992,996 ----
{
t_hang *hang;
! while (hang = x->x_hang)
{
outlet_float(x->x_velout, 0);
***************
*** 1005,1009 ****
{
t_hang *hang;
! while ((hang = x->x_hang))
{
x->x_hang = hang->h_next;
--- 1005,1009 ----
{
t_hang *hang;
! while (hang = x->x_hang)
{
x->x_hang = hang->h_next;
***************
*** 1048,1051 ****
--- 1048,1052 ----
static void stripnote_float(t_stripnote *x, t_float f)
{
+ t_hang *hang;
if (!x->x_velo) return;
outlet_float(x->x_velout, x->x_velo);
***************
*** 1181,1185 ****
static void poly_free(t_poly *x)
{
- poly_clear(x);
freebytes(x->x_vec, x->x_n * sizeof (*x->x_vec));
}
--- 1182,1185 ----
***************
*** 1188,1192 ****
{
poly_class = class_new(gensym("poly"),
! (t_newmethod)poly_new, (t_method)poly_free,
sizeof(t_poly), 0, A_DEFFLOAT, A_DEFFLOAT, 0);
class_addfloat(poly_class, poly_float);
--- 1188,1192 ----
{
poly_class = class_new(gensym("poly"),
! (t_newmethod)poly_new, (t_method)poly_clear,
sizeof(t_poly), 0, A_DEFFLOAT, A_DEFFLOAT, 0);
class_addfloat(poly_class, poly_float);
***************
*** 1233,1237 ****
else /* LATER replace with a faster algorithm */
{
! for (e2 = x->x_first; (e3 = e2->e_next); e2 = e3)
;
e2->e_next = bagelem;
--- 1233,1237 ----
else /* LATER replace with a faster algorithm */
{
! for (e2 = x->x_first; e3 = e2->e_next; e2 = e3)
;
e2->e_next = bagelem;
***************
*** 1248,1252 ****
return;
}
! for (e2 = x->x_first; (e3 = e2->e_next); e2 = e3)
if (e3->e_value == f)
{
--- 1248,1252 ----
return;
}
! for (e2 = x->x_first; e3 = e2->e_next; e2 = e3)
if (e3->e_value == f)
{
***************
*** 1261,1265 ****
{
t_bagelem *bagelem;
! while ((bagelem = x->x_first))
{
outlet_float(x->x_obj.ob_outlet, bagelem->e_value);
--- 1261,1265 ----
{
t_bagelem *bagelem;
! while (bagelem = x->x_first)
{
outlet_float(x->x_obj.ob_outlet, bagelem->e_value);
***************
*** 1272,1276 ****
{
t_bagelem *bagelem;
! while ((bagelem = x->x_first))
{
x->x_first = bagelem->e_next;
--- 1272,1276 ----
{
t_bagelem *bagelem;
! while (bagelem = x->x_first)
{
x->x_first = bagelem->e_next;
Index: s_loader.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_loader.c,v
retrieving revision 1.4.4.5.2.4
retrieving revision 1.4.4.5.2.5
diff -C2 -d -r1.4.4.5.2.4 -r1.4.4.5.2.5
*** s_loader.c 27 Nov 2005 23:15:45 -0000 1.4.4.5.2.4
--- s_loader.c 30 Nov 2005 13:36:58 -0000 1.4.4.5.2.5
***************
*** 91,95 ****
filename[MAXPDSTRING-1] = 0;
/* extract the setup function name */
! if ((lastdot = strrchr(nameptr, '.')))
*lastdot = 0;
--- 91,95 ----
filename[MAXPDSTRING-1] = 0;
/* extract the setup function name */
! if (lastdot = strrchr(nameptr, '.'))
*lastdot = 0;
***************
*** 224,228 ****
loader_queue_t *q;
for(q = &loaders; q; q = q->next)
! if((ok = q->loader(dirname,classname))) break;
canvas_resume_dsp(dspstate);
--- 224,228 ----
loader_queue_t *q;
for(q = &loaders; q; q = q->next)
! if(ok = q->loader(dirname,classname)) break;
canvas_resume_dsp(dspstate);
Index: d_dac.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_dac.c,v
retrieving revision 1.3.4.2.2.1
retrieving revision 1.3.4.2.2.2
diff -C2 -d -r1.3.4.2.2.1 -r1.3.4.2.2.2
*** d_dac.c 27 Nov 2005 07:59:05 -0000 1.3.4.2.2.1
--- d_dac.c 30 Nov 2005 13:36:57 -0000 1.3.4.2.2.2
***************
*** 26,30 ****
{
t_dac *x = (t_dac *)pd_new(dac_class);
! t_atom defarg[2];
int i;
if (!argc)
--- 26,30 ----
{
t_dac *x = (t_dac *)pd_new(dac_class);
! t_atom defarg[2], *ap;
int i;
if (!argc)
***************
*** 54,58 ****
if ((*sp2)->s_n != sys_dacblocksize)
error("dac~: bad vector size");
! else if (ch >= 0 && ch < sys_get_outchannels()) {
if(SIMD_CHECK3(sys_dacblocksize,sys_soundout + sys_dacblocksize*ch,
(*sp2)->s_vec,sys_soundout + sys_dacblocksize*ch))
--- 54,59 ----
if ((*sp2)->s_n != sys_dacblocksize)
error("dac~: bad vector size");
! else
! if (ch >= 0 && ch < sys_get_outchannels())
if(SIMD_CHECK3(sys_dacblocksize,sys_soundout + sys_dacblocksize*ch,
(*sp2)->s_vec,sys_soundout + sys_dacblocksize*ch))
***************
*** 62,66 ****
dsp_add(plus_perform, 4, sys_soundout + sys_dacblocksize*ch,
(*sp2)->s_vec, sys_soundout + sys_dacblocksize*ch, sys_dacblocksize);
- }
}
}
--- 63,66 ----
***************
*** 93,97 ****
{
t_adc *x = (t_adc *)pd_new(adc_class);
! t_atom defarg[2];
int i;
if (!argc)
--- 93,97 ----
{
t_adc *x = (t_adc *)pd_new(adc_class);
! t_atom defarg[2], *ap;
int i;
if (!argc)
Index: s_main.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_main.c,v
retrieving revision 1.7.4.17.2.9
retrieving revision 1.7.4.17.2.10
diff -C2 -d -r1.7.4.17.2.9 -r1.7.4.17.2.10
*** s_main.c 27 Nov 2005 23:15:45 -0000 1.7.4.17.2.9
--- s_main.c 30 Nov 2005 13:36:58 -0000 1.7.4.17.2.10
***************
*** 470,474 ****
}
! /*static int sys_getmultidevchannels(int n, int *devlist)
{
int sum = 0;
--- 470,474 ----
}
! static int sys_getmultidevchannels(int n, int *devlist)
{
int sum = 0;
***************
*** 477,481 ****
while(n--)sum+=*devlist++;
return sum;
! }*/
/* this routine tries to figure out where to find the auxilliary files
--- 477,482 ----
while(n--)sum+=*devlist++;
return sum;
! }
!
/* this routine tries to figure out where to find the auxilliary files
***************
*** 485,489 ****
void sys_findprogdir(char *progname)
{
! char sbuf[MAXPDSTRING], sbuf2[MAXPDSTRING];
char *lastslash;
#ifdef UNISTD
--- 486,490 ----
void sys_findprogdir(char *progname)
{
! char sbuf[MAXPDSTRING], sbuf2[MAXPDSTRING], *sp;
char *lastslash;
#ifdef UNISTD
***************
*** 583,586 ****
--- 584,589 ----
int sys_argparse(int argc, char **argv)
{
+ char sbuf[MAXPDSTRING];
+ int i;
while ((argc > 0) && **argv == '-')
{
***************
*** 1059,1060 ****
--- 1062,1068 ----
sys_open_midi(nmidiindev, midiindev, nmidioutdev, midioutdev, 0);
}
+
+ static void sys_addreferencepath(void)
+ {
+ char sbuf[MAXPDSTRING];
+ }
Index: m_sched.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_sched.c,v
retrieving revision 1.5.4.35.2.8
retrieving revision 1.5.4.35.2.9
diff -C2 -d -r1.5.4.35.2.8 -r1.5.4.35.2.9
*** m_sched.c 27 Nov 2005 23:14:53 -0000 1.5.4.35.2.8
--- m_sched.c 30 Nov 2005 13:36:58 -0000 1.5.4.35.2.9
***************
*** 195,199 ****
int sys_addhist(int phase)
{
! int j, phasewas = sys_histphase;
double newtime = sys_getrealtime();
int msec = (newtime - sys_histtime) * 1000.;
--- 195,199 ----
int sys_addhist(int phase)
{
! int i, j, phasewas = sys_histphase;
double newtime = sys_getrealtime();
int msec = (newtime - sys_histtime) * 1000.;
***************
*** 236,240 ****
void glob_audiostatus(void)
{
! int nresync, nresyncphase, i;
nresync = (oss_nresync >= NRESYNC ? NRESYNC : oss_nresync);
nresyncphase = oss_resyncphase - 1;
--- 236,240 ----
void glob_audiostatus(void)
{
! int dev, nresync, nresyncphase, i;
nresync = (oss_nresync >= NRESYNC ? NRESYNC : oss_nresync);
nresyncphase = oss_resyncphase - 1;
***************
*** 506,509 ****
--- 506,511 ----
while(sys_keepsched)
{
+ int didsomething = 0;
+
/* tb: allow the audio callback to run */
sys_unlock();
***************
*** 708,712 ****
/* append idle callback to ringbuffer */
! while ((new_callback = (t_sched_callback*) fifo_get(callback_fifo)))
{
t_sched_callback * next;
--- 710,714 ----
/* append idle callback to ringbuffer */
! while (new_callback = (t_sched_callback*) fifo_get(callback_fifo))
{
t_sched_callback * next;
Index: s_midi.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_midi.c,v
retrieving revision 1.4.4.1.2.3
retrieving revision 1.4.4.1.2.4
diff -C2 -d -r1.4.4.1.2.3 -r1.4.4.1.2.4
*** s_midi.c 27 Nov 2005 08:08:44 -0000 1.4.4.1.2.3
--- s_midi.c 30 Nov 2005 13:36:58 -0000 1.4.4.1.2.4
***************
*** 155,158 ****
--- 155,159 ----
static void sys_queuemidimess(int portno, int onebyte, int a, int b, int c)
{
+ t_midiqelem *midiqelem;
int newhead = midi_outhead +1;
if (newhead == MIDIQSIZE)
***************
*** 425,428 ****
--- 426,430 ----
{
static int warned = 0;
+ t_midiqelem *midiqelem;
int newhead = midi_inhead +1;
if (newhead == MIDIQSIZE)
***************
*** 529,533 ****
midi_oss_init();
#endif
! if (enable) {
#ifdef USEAPI_ALSA
if (sys_midiapi == API_ALSA)
--- 531,535 ----
midi_oss_init();
#endif
! if (enable)
#ifdef USEAPI_ALSA
if (sys_midiapi == API_ALSA)
***************
*** 536,540 ****
#endif /* ALSA */
sys_do_open_midi(nmidiindev, midiindev, nmidioutdev, midioutdev);
- }
sys_save_midi_params(nmidiindev, midiindev,
nmidioutdev, midioutdev);
--- 538,541 ----
***************
*** 716,719 ****
--- 717,722 ----
void glob_midi_dialog(t_pd *dummy, t_symbol *s, int argc, t_atom *argv)
{
+ int nmidiindev, midiindev[MAXMIDIINDEV];
+ int nmidioutdev, midioutdev[MAXMIDIOUTDEV];
int i, nindev, noutdev;
int newmidiindev[4], newmidioutdev[4];
Index: t_main.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/t_main.c,v
retrieving revision 1.2.8.3
retrieving revision 1.2.8.4
diff -C2 -d -r1.2.8.3 -r1.2.8.4
*** t_main.c 27 Nov 2005 08:14:14 -0000 1.2.8.3
--- t_main.c 30 Nov 2005 13:36:58 -0000 1.2.8.4
***************
*** 86,89 ****
--- 86,91 ----
Tcl_Interp *interp /* Interpreter for application. */
) {
+ Tk_Window mainwindow;
+
if (Tcl_Init(interp) == TCL_ERROR) {
return TCL_ERROR;
Index: s_audio_jack.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_jack.c,v
retrieving revision 1.5.4.8.2.5
retrieving revision 1.5.4.8.2.6
diff -C2 -d -r1.5.4.8.2.5 -r1.5.4.8.2.6
*** s_audio_jack.c 27 Nov 2005 23:14:02 -0000 1.5.4.8.2.5
--- s_audio_jack.c 30 Nov 2005 13:36:58 -0000 1.5.4.8.2.6
***************
*** 104,112 ****
int status = sys_timedlock(timeout);
! if (status) {
if (status == ETIMEDOUT)
/* we're late ... lets hope that jack doesn't kick us out */
{
post("timeout %d", (timeout));
sys_log_error(ERR_SYSLOCK);
return 0;
--- 104,114 ----
int status = sys_timedlock(timeout);
! if (status)
if (status == ETIMEDOUT)
/* we're late ... lets hope that jack doesn't kick us out */
{
+ static int k = 0;
post("timeout %d", (timeout));
+
sys_log_error(ERR_SYSLOCK);
return 0;
***************
*** 117,121 ****
return 0;
}
! }
for (i = 0; i != dspticks_per_jacktick; ++i)
{
--- 119,123 ----
return 0;
}
!
for (i = 0; i != dspticks_per_jacktick; ++i)
{
***************
*** 167,170 ****
--- 169,173 ----
static t_int jack_shutdown_handler(t_int* none)
{
+ int i;
post("jack kicked us out ... trying to reconnect");
jack_ignore_graph_callback = 1;
***************
*** 191,199 ****
}
! /*static int jack_xrun(void* arg) {
jack_dio_error = 1;
sys_log_error(ERR_XRUN);
return 0;
! }*/
static int jack_graph_order_callback(void* arg)
--- 194,202 ----
}
! static int jack_xrun(void* arg) {
jack_dio_error = 1;
sys_log_error(ERR_XRUN);
return 0;
! }
static int jack_graph_order_callback(void* arg)
Index: s_audio_oss.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_oss.c,v
retrieving revision 1.6.4.2.2.1
retrieving revision 1.6.4.2.2.2
diff -C2 -d -r1.6.4.2.2.1 -r1.6.4.2.2.2
*** s_audio_oss.c 27 Nov 2005 08:08:28 -0000 1.6.4.2.2.1
--- s_audio_oss.c 30 Nov 2005 13:36:58 -0000 1.6.4.2.2.2
***************
*** 25,29 ****
/* Defines */
- #undef DEBUG
#define DEBUG(x) x
#define DEBUG2(x) {x;}
--- 25,28 ----
***************
*** 43,46 ****
--- 42,48 ----
/* GLOBALS */
+ static int linux_meters; /* true if we're metering */
+ static float linux_inmax; /* max input amplitude */
+ static float linux_outmax; /* max output amplitude */
static int linux_fragsize = 0; /* for block mode; block size (sample frames) */
***************
*** 70,73 ****
--- 72,76 ----
static int oss_blockmode = 0; /* flag to use "blockmode" */
static int oss_32bit = 0; /* allow 23 bit transfers in OSS */
+ static char ossdsp[] = "/dev/dsp%d";
/* don't assume we can turn all 31 bits when doing float-to-fix;
***************
*** 137,142 ****
void oss_configure(t_oss_dev *dev, int srate, int dac, int skipblocksize)
{ /* IOhannes */
! int orig, param, fd = dev->d_fd, wantformat;
int nchannels = dev->d_nchannels;
audio_buf_info ainfo;
--- 140,147 ----
void oss_configure(t_oss_dev *dev, int srate, int dac, int skipblocksize)
{ /* IOhannes */
! int orig, param, nblk, fd = dev->d_fd, wantformat;
int nchannels = dev->d_nchannels;
+ int advwas = sys_schedadvance;
+
audio_buf_info ainfo;
***************
*** 271,275 ****
--- 276,284 ----
int n, i, fd, flags;
char buf[OSS_MAXSAMPLEWIDTH * sys_dacblocksize * OSS_MAXCHPERDEV];
+ int num_devs = 0;
int wantmore=0;
+ int spread = 0;
+ audio_buf_info ainfo;
+
linux_nindevs = linux_noutdevs = 0;
/* mark devices unopened */
***************
*** 543,547 ****
static void oss_doresync( void)
{
! int dev, zeroed = 0;
char buf[OSS_MAXSAMPLEWIDTH * sys_dacblocksize * OSS_MAXCHPERDEV];
audio_buf_info ainfo;
--- 552,556 ----
static void oss_doresync( void)
{
! int dev, zeroed = 0, wantsize;
char buf[OSS_MAXSAMPLEWIDTH * sys_dacblocksize * OSS_MAXCHPERDEV];
audio_buf_info ainfo;
***************
*** 622,625 ****
--- 631,635 ----
{
float *fp1, *fp2;
+ long fill;
int i, j, dev, rtnval = SENDDACS_YES;
char buf[OSS_MAXSAMPLEWIDTH * sys_dacblocksize * OSS_MAXCHPERDEV];
***************
*** 666,669 ****
--- 676,680 ----
if (linux_adcs[dev].d_space == 0)
{
+ audio_buf_info ainfo;
sys_microsleep(sys_sleepgrain); /* tb: changed to sys_sleepgrain */
oss_calcspace();
Index: s_midi_alsa.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_midi_alsa.c,v
retrieving revision 1.1.2.2.2.5
retrieving revision 1.1.2.2.2.6
diff -C2 -d -r1.1.2.2.2.5 -r1.1.2.2.2.6
*** s_midi_alsa.c 27 Nov 2005 08:08:44 -0000 1.1.2.2.2.5
--- s_midi_alsa.c 30 Nov 2005 13:36:58 -0000 1.1.2.2.2.6
***************
*** 239,242 ****
--- 239,243 ----
{
// repack into 1 byte char and put somewhere to point at
+ unsigned char data = (unsigned char)byte;
unsigned char *dataptr = malloc(1);
memcpy(dataptr,&byte,1);
***************
*** 295,298 ****
--- 296,300 ----
void midi_alsa_init(void)
{
+ int i;
if (alsa_initted)
return;
Index: s_midi_oss.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_midi_oss.c,v
retrieving revision 1.3.8.1
retrieving revision 1.3.8.2
diff -C2 -d -r1.3.8.1 -r1.3.8.2
*** s_midi_oss.c 27 Nov 2005 08:08:44 -0000 1.3.8.1
--- s_midi_oss.c 30 Nov 2005 13:36:58 -0000 1.3.8.2
***************
*** 230,236 ****
{
int i, throttle = 100;
! int did = 1;
while (did)
{
did = 0;
if (throttle-- < 0)
--- 230,238 ----
{
int i, throttle = 100;
! struct timeval timout;
! int did = 1, maxfd = 0;
while (did)
{
+ fd_set readset, writeset, exceptset;
did = 0;
if (throttle-- < 0)
Index: u_pdreceive.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/u_pdreceive.c,v
retrieving revision 1.2.8.2
retrieving revision 1.2.8.3
diff -C2 -d -r1.2.8.2 -r1.2.8.3
*** u_pdreceive.c 27 Nov 2005 08:14:14 -0000 1.2.8.2
--- u_pdreceive.c 30 Nov 2005 13:36:58 -0000 1.2.8.3
***************
*** 21,25 ****
#include <stdio.h>
#include <unistd.h>
- #include <sys/select.h>
#define SOCKET_ERROR -1
#endif
--- 21,24 ----
***************
*** 49,52 ****
--- 48,52 ----
int portno;
struct sockaddr_in server;
+ int nretry = 10;
#ifdef MSW
short version = MAKEWORD(2, 0);
***************
*** 115,118 ****
--- 115,119 ----
static void addport(int fd)
{
+ int nfd = nfdpoll;
t_fdpoll *fp;
fdpoll = (t_fdpoll *)realloc(fdpoll,
***************
*** 133,137 ****
static void rmport(t_fdpoll *x)
{
! int i;
t_fdpoll *fp;
for (i = nfdpoll, fp = fdpoll; i--; fp++)
--- 134,139 ----
static void rmport(t_fdpoll *x)
{
! int nfd = nfdpoll;
! int i, size = nfdpoll * sizeof(t_fdpoll);
t_fdpoll *fp;
for (i = nfdpoll, fp = fdpoll; i--; fp++)
***************
*** 321,323 ****
#endif
}
-
--- 323,324 ----
Index: t_tkcmd.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/t_tkcmd.c,v
retrieving revision 1.2.4.1.2.8
retrieving revision 1.2.4.1.2.9
diff -C2 -d -r1.2.4.1.2.8 -r1.2.4.1.2.9
*** t_tkcmd.c 27 Nov 2005 08:14:14 -0000 1.2.4.1.2.8
--- t_tkcmd.c 30 Nov 2005 13:36:58 -0000 1.2.4.1.2.9
***************
*** 345,351 ****
const char *arg0;
struct sockaddr_in server;
! int len = sizeof(server);
int ntry = 0, portno = FIRSTPORTNUM;
int xsock = -1;
#ifdef MSW
short version = MAKEWORD(2, 0);
--- 345,353 ----
const char *arg0;
struct sockaddr_in server;
! int msgsock;
! int len = sizeof(server), nchar;
int ntry = 0, portno = FIRSTPORTNUM;
int xsock = -1;
+ char morebuf[256];
#ifdef MSW
short version = MAKEWORD(2, 0);
***************
*** 594,598 ****
char *str;
int n;
! t = strrchr(s, '/'); if (t) str = s, n = (t-s) + 1;
else str = "./", n = 2;
if (n > GUISTRING-100) n = GUISTRING-100;
--- 596,600 ----
char *str;
int n;
! if (t = strrchr(s, '/')) str = s, n = (t-s) + 1;
else str = "./", n = 2;
if (n > GUISTRING-100) n = GUISTRING-100;
***************
*** 602,606 ****
while (strlen(pdgui_path) > 0 && pdgui_path[strlen(pdgui_path)-1] == '/')
pdgui_path[strlen(pdgui_path)-1] = 0;
! t = strrchr(pdgui_path, '/'); if (t) *t = 0;
}
#endif
--- 604,609 ----
while (strlen(pdgui_path) > 0 && pdgui_path[strlen(pdgui_path)-1] == '/')
pdgui_path[strlen(pdgui_path)-1] = 0;
! if (t = strrchr(pdgui_path, '/'))
! *t = 0;
}
#endif
***************
*** 614,618 ****
{
const char *argv = Tcl_GetVar(interp, "argv", 0);
! int portno;
/* argument passing seems to be different in MSW as opposed to
unix-likes. Here we check if we got sent a "port number" as an
--- 617,621 ----
{
const char *argv = Tcl_GetVar(interp, "argv", 0);
! int portno, argno = 0;
/* argument passing seems to be different in MSW as opposed to
unix-likes. Here we check if we got sent a "port number" as an
Index: s_file.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_file.c,v
retrieving revision 1.2.4.8.2.6
retrieving revision 1.2.4.8.2.7
diff -C2 -d -r1.2.4.8.2.6 -r1.2.4.8.2.7
*** s_file.c 27 Nov 2005 23:14:02 -0000 1.2.4.8.2.6
--- s_file.c 30 Nov 2005 13:36:58 -0000 1.2.4.8.2.7
***************
*** 37,41 ****
static char *sys_prefbuf;
! /*static int sys_prefbufsize;*/
static void sys_initloadpreferences( void)
--- 37,41 ----
static char *sys_prefbuf;
! static int sys_prefbufsize;
static void sys_initloadpreferences( void)
***************
*** 106,114 ****
}
! /*static void sys_doneloadpreferences( void)
{
if (sys_prefbuf)
free(sys_prefbuf);
! }*/
static FILE *sys_prefsavefp;
--- 106,114 ----
}
! static void sys_doneloadpreferences( void)
{
if (sys_prefbuf)
free(sys_prefbuf);
! }
static FILE *sys_prefsavefp;
***************
*** 118,121 ****
--- 118,122 ----
char filenamebuf[MAXPDSTRING], errbuf[MAXPDSTRING],
*homedir = getenv("HOME");
+ FILE *fp;
if (!homedir)
***************
*** 263,267 ****
int nmidiindev, midiindev[MAXMIDIINDEV];
int nmidioutdev, midioutdev[MAXMIDIOUTDEV];
! int i, rate = 0, advance = 0, dacblocksize = 0, api, maxi, scheduler = 0;
char prefbuf[MAXPDSTRING], keybuf[80];
sys_initloadpreferences();
--- 264,268 ----
int nmidiindev, midiindev[MAXMIDIINDEV];
int nmidioutdev, midioutdev[MAXMIDIOUTDEV];
! int i, rate = 0, advance = 0, dacblocksize = 0, api, nolib, maxi, scheduler = 0;
char prefbuf[MAXPDSTRING], keybuf[80];
sys_initloadpreferences();
Index: s_inter.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_inter.c,v
retrieving revision 1.5.4.10.2.11
retrieving revision 1.5.4.10.2.12
diff -C2 -d -r1.5.4.10.2.11 -r1.5.4.10.2.12
*** s_inter.c 27 Nov 2005 23:15:45 -0000 1.5.4.10.2.11
--- s_inter.c 30 Nov 2005 13:36:58 -0000 1.5.4.10.2.12
***************
*** 518,521 ****
--- 518,522 ----
else /* TCP ("streaming") socket protocol */
{
+ char *semi;
int readto =
(x->sr_inhead >= x->sr_intail ? INBUFSIZE : x->sr_intail-1);
***************
*** 659,663 ****
void sys_vgui(char *fmt, ...)
{
! int msglen;
va_list ap;
--- 660,664 ----
void sys_vgui(char *fmt, ...)
{
! int msglen, bytesleft, headwas, nwrote;
va_list ap;
***************
*** 841,845 ****
sys_guiqueuehead = 0;
}
! else for (gq = sys_guiqueuehead; (gq2 = gq->gq_next); gq = gq2)
if (gq2->gq_client == client)
{
--- 842,846 ----
sys_guiqueuehead = 0;
}
! else for (gq = sys_guiqueuehead; gq2 = gq->gq_next; gq = gq2)
if (gq2->gq_client == client)
{
Index: d_delay.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_delay.c,v
retrieving revision 1.2.4.6.2.1
retrieving revision 1.2.4.6.2.2
diff -C2 -d -r1.2.4.6.2.1 -r1.2.4.6.2.2
*** d_delay.c 27 Nov 2005 07:59:05 -0000 1.2.4.6.2.1
--- d_delay.c 30 Nov 2005 13:36:57 -0000 1.2.4.6.2.2
***************
*** 12,15 ****
--- 12,16 ----
#define DEFDELVS 64 /* LATER get this from canvas at DSP time */
+ static int delread_zero = 0; /* four bytes of zero for delread~, vd~ */
/* ----------------------------- delwrite~ ----------------------------- */
***************
*** 235,238 ****
--- 236,240 ----
static void sigdelread_float(t_sigdelread *x, t_float f)
{
+ int samps;
t_sigdelwrite *delwriter =
(t_sigdelwrite *)pd_findbyclass(x->x_sym, sigdelwrite_class);
***************
*** 240,243 ****
--- 242,246 ----
if (delwriter)
{
+ int delsize = delwriter->x_cspace.c_n;
x->x_delsamps = (int)(0.5 + x->x_sr * x->x_deltime)
+ x->x_n - x->x_zerodel;
Index: d_array.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_array.c,v
retrieving revision 1.3.4.3.2.2
retrieving revision 1.3.4.3.2.3
diff -C2 -d -r1.3.4.3.2.2 -r1.3.4.3.2.3
*** d_array.c 27 Nov 2005 07:59:05 -0000 1.3.4.3.2.2
--- d_array.c 30 Nov 2005 13:36:57 -0000 1.3.4.3.2.3
***************
*** 24,27 ****
--- 24,29 ----
} t_tabwrite_tilde;
+ static void tabwrite_tilde_tick(t_tabwrite_tilde *x);
+
static void *tabwrite_tilde_new(t_symbol *s)
{
***************
*** 324,328 ****
int n = (int)(w[4]);
int maxindex;
! float *buf = x->x_vec;
int i;
--- 326,330 ----
int n = (int)(w[4]);
int maxindex;
! float *buf = x->x_vec, *fp;
int i;
***************
*** 448,451 ****
--- 450,454 ----
int index = findex;
float frac, a, b, c, d, cminusb;
+ static int count;
if (index < 1)
index = 1, frac = 0;
***************
*** 458,461 ****
--- 461,466 ----
c = fp[1];
d = fp[2];
+ /* if (!i && !(count++ & 1023))
+ post("fp = %lx, shit = %lx, b = %f", fp, buf->b_shit, b); */
cminusb = c-b;
*out++ = b + frac * (
***************
*** 620,624 ****
--- 625,631 ----
int mask = fnpoints - 1;
float conv = fnpoints * x->x_conv;
+ int maxindex;
float *tab = x->x_vec, *addr;
+ int i;
double dphase = fnpoints * x->x_phase + UNITBIT32;
***************
*** 627,630 ****
--- 634,638 ----
normhipart = tf.tf_i[HIOFFSET];
+ #if 1
while (n--)
{
***************
*** 646,649 ****
--- 654,658 ----
);
}
+ #endif
tf.tf_d = UNITBIT32 * fnpoints;
***************
*** 733,736 ****
--- 742,747 ----
} t_tabsend;
+ static void tabsend_tick(t_tabsend *x);
+
static void *tabsend_new(t_symbol *s)
{
***************
*** 794,798 ****
static void tabsend_dsp(t_tabsend *x, t_signal **sp)
{
! int vecsize;
t_garray *a;
--- 805,809 ----
static void tabsend_dsp(t_tabsend *x, t_signal **sp)
{
! int i, vecsize;
t_garray *a;
***************
*** 1054,1058 ****
static void tabwrite_float(t_tabwrite *x, t_float f)
{
! int vecsize;
t_garray *a;
t_float *vec;
--- 1065,1069 ----
static void tabwrite_float(t_tabwrite *x, t_float f)
{
! int i, vecsize;
t_garray *a;
t_float *vec;
Index: d_ugen.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_ugen.c,v
retrieving revision 1.3.4.1.2.4
retrieving revision 1.3.4.1.2.5
diff -C2 -d -r1.3.4.1.2.4 -r1.3.4.1.2.5
*** d_ugen.c 27 Nov 2005 07:59:05 -0000 1.3.4.1.2.4
--- d_ugen.c 30 Nov 2005 13:36:57 -0000 1.3.4.1.2.5
***************
*** 350,356 ****
void signal_cleanup(void)
{
! t_signal *sig;
int i;
! while ((sig = signal_usedlist))
{
signal_usedlist = sig->s_nextused;
--- 350,356 ----
void signal_cleanup(void)
{
! t_signal **svec, *sig, *sig2;
int i;
! while (sig = signal_usedlist)
{
signal_usedlist = sig->s_nextused;
***************
*** 423,428 ****
t_signal *signal_new(int n, float sr)
{
! int logn;
t_signal *ret, **whichlist;
logn = ilog2(n);
if (n)
--- 423,429 ----
t_signal *signal_new(int n, float sr)
{
! int logn, n2;
t_signal *ret, **whichlist;
+ t_sample *fp;
logn = ilog2(n);
if (n)
***************
*** 438,443 ****
/* first try to reclaim one from the free list */
! ret = *whichlist;
! if (ret) *whichlist = ret->s_nextfree;
else
{
--- 439,444 ----
/* first try to reclaim one from the free list */
! if (ret = *whichlist)
! *whichlist = ret->s_nextfree;
else
{
***************
*** 550,553 ****
--- 551,556 ----
void ugen_stop(void)
{
+ t_signal *s;
+ int i;
if (dsp_chain)
{
***************
*** 605,609 ****
--- 608,616 ----
{
t_dspcontext *dc = (t_dspcontext *)getbytes(sizeof(*dc));
+ float parent_srate, srate;
+ int parent_vecsize, vecsize;
+
if (ugen_loud) post("ugen_start_graph...");
+
dc->dc_ugenlist = 0;
dc->dc_toplevel = toplevel;
***************
*** 696,700 ****
t_sigoutlet *uout;
t_siginlet *uin;
! t_sigoutconnect *oc;
t_class *klass = pd_class(&u->u_obj->ob_pd);
int i, n;
--- 703,707 ----
t_sigoutlet *uout;
t_siginlet *uin;
! t_sigoutconnect *oc, *oc2;
t_class *klass = pd_class(&u->u_obj->ob_pd);
int i, n;
***************
*** 724,728 ****
/* post("%s: unconnected signal inlet set to zero",
class_getname(u->u_obj->ob_pd)); */
! if ((scalar = obj_findsignalscalar(u->u_obj, i)))
dsp_add_scalarcopy(scalar, s3->s_vec, s3->s_n);
else
--- 731,735 ----
/* post("%s: unconnected signal inlet set to zero",
class_getname(u->u_obj->ob_pd)); */
! if (scalar = obj_findsignalscalar(u->u_obj, i))
dsp_add_scalarcopy(scalar, s3->s_vec, s3->s_n);
else
***************
*** 804,808 ****
uin = &u2->u_in[oc->oc_inno];
/* if there's already someone here, sum the two */
! if ((s2 = uin->i_signal))
{
s1->s_refcount--;
--- 811,815 ----
uin = &u2->u_in[oc->oc_inno];
/* if there's already someone here, sum the two */
! if (s2 = uin->i_signal)
{
s1->s_refcount--;
***************
*** 848,852 ****
void ugen_done_graph(t_dspcontext *dc)
{
! t_ugenbox *u;
t_sigoutlet *uout;
t_siginlet *uin;
--- 855,859 ----
void ugen_done_graph(t_dspcontext *dc)
{
! t_ugenbox *u, *u2;
t_sigoutlet *uout;
t_siginlet *uin;
***************
*** 989,993 ****
{
t_pd *zz = &u->u_obj->ob_pd;
! t_signal **outsigs = dc->dc_iosigs;
if (outsigs) outsigs += dc->dc_ninlets;
--- 996,1000 ----
{
t_pd *zz = &u->u_obj->ob_pd;
! t_signal **insigs = dc->dc_iosigs, **outsigs = dc->dc_iosigs;
if (outsigs) outsigs += dc->dc_ninlets;
Index: d_mayer_fft.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_mayer_fft.c,v
retrieving revision 1.2.4.1.2.1
retrieving revision 1.2.4.1.2.2
diff -C2 -d -r1.2.4.1.2.1 -r1.2.4.1.2.2
*** d_mayer_fft.c 27 Nov 2005 07:59:05 -0000 1.2.4.1.2.1
--- d_mayer_fft.c 30 Nov 2005 13:36:57 -0000 1.2.4.1.2.2
***************
*** 398,402 ****
void mayer_realfft(int n, REAL *real)
{
! REAL a,b;
int i,j,k;
mayer_fht(real,n);
--- 398,402 ----
void mayer_realfft(int n, REAL *real)
{
! REAL a,b,c,d;
int i,j,k;
mayer_fht(real,n);
***************
*** 411,415 ****
void mayer_realifft(int n, REAL *real)
{
! REAL a,b;
int i,j,k;
for (i=1,j=n-1,k=n/2;i<k;i++,j--) {
--- 411,415 ----
void mayer_realifft(int n, REAL *real)
{
! REAL a,b,c,d;
int i,j,k;
for (i=1,j=n-1,k=n/2;i<k;i++,j--) {
Index: m_pd.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_pd.c,v
retrieving revision 1.3.8.3
retrieving revision 1.3.8.4
diff -C2 -d -r1.3.8.3 -r1.3.8.4
*** m_pd.c 27 Nov 2005 23:14:53 -0000 1.3.8.3
--- m_pd.c 30 Nov 2005 13:36:58 -0000 1.3.8.4
***************
*** 165,169 ****
freebytes(e, sizeof(t_bindelem));
}
! else for (e = b->b_list; (e2 = e->e_next); e = e2)
if (e2->e_who == x)
{
--- 165,169 ----
freebytes(e, sizeof(t_bindelem));
}
! else for (e = b->b_list; e2 = e->e_next; e = e2)
if (e2->e_who == x)
{
***************
*** 193,197 ****
{
t_bindlist *b = (t_bindlist *)s->s_thing;
! t_bindelem *e;
int warned = 0;
for (e = b->b_list; e; e = e->e_next)
--- 193,197 ----
{
t_bindlist *b = (t_bindlist *)s->s_thing;
! t_bindelem *e, *e2;
int warned = 0;
for (e = b->b_list; e; e = e->e_next)
Index: x_connective.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/x_connective.c,v
retrieving revision 1.3.4.1.2.7
retrieving revision 1.3.4.1.2.8
diff -C2 -d -r1.3.4.1.2.7 -r1.3.4.1.2.8
*** x_connective.c 27 Nov 2005 07:57:10 -0000 1.3.4.1.2.7
--- x_connective.c 30 Nov 2005 13:36:58 -0000 1.3.4.1.2.8
***************
*** 136,140 ****
always check and call the more specific method, or should it be the
object's responsibility? Dunno... */
! /*static void pdsymbol_list(t_pdsymbol *x, t_symbol *s, int ac, t_atom *av)
{
if (!ac)
--- 136,140 ----
always check and call the more specific method, or should it be the
object's responsibility? Dunno... */
! static void pdsymbol_list(t_pdsymbol *x, t_symbol *s, int ac, t_atom *av)
{
if (!ac)
***************
*** 143,147 ****
pdsymbol_symbol(x, av->a_w.w_symbol);
else pdsymbol_anything(x, s, ac, av);
! }*/
void pdsymbol_setup(void)
--- 143,147 ----
pdsymbol_symbol(x, av->a_w.w_symbol);
else pdsymbol_anything(x, s, ac, av);
! }
void pdsymbol_setup(void)
Index: s_audio_pa.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_audio_pa.c,v
retrieving revision 1.4.4.7.2.3
retrieving revision 1.4.4.7.2.4
diff -C2 -d -r1.4.4.7.2.3 -r1.4.4.7.2.4
*** s_audio_pa.c 27 Nov 2005 08:08:28 -0000 1.4.4.7.2.3
--- s_audio_pa.c 30 Nov 2005 13:36:58 -0000 1.4.4.7.2.4
***************
*** 227,231 ****
PaStreamCallbackFlags statusFlags, void *userData)
{
! int j;
int timeout = (float)frameCount / (float) sys_dacsr * 1e6;
--- 227,231 ----
PaStreamCallbackFlags statusFlags, void *userData)
{
! int i,j;
int timeout = (float)frameCount / (float) sys_dacsr * 1e6;
***************
*** 405,410 ****
void pa_listdevs(void) /* lifted from pa_devs.c in portaudio */
{
! int i;
int numDevices;
PaError err;
Pa_Initialize();
--- 405,411 ----
void pa_listdevs(void) /* lifted from pa_devs.c in portaudio */
{
! int i,j;
int numDevices;
+ const PaDeviceInfo *pdi;
PaError err;
Pa_Initialize();