aboutsummaryrefslogtreecommitdiff
path: root/packages/patches/delwrite~_nogui_fix-0.42.5.patch
diff options
context:
space:
mode:
authorHans-Christoph Steiner <eighthave@users.sourceforge.net>2010-07-21 22:07:40 +0000
committerHans-Christoph Steiner <eighthave@users.sourceforge.net>2010-07-21 22:07:40 +0000
commit6a40415e3ab3b67dc2a9515727e74307235bd839 (patch)
treefe80341c55726fa94f870d7256a2a8337f26a056 /packages/patches/delwrite~_nogui_fix-0.42.5.patch
parent37453bcbffb55590eb460499aec9f63f04da5d1a (diff)
first big round of patches accepted by Miller into 0.43
svn path=/trunk/; revision=13724
Diffstat (limited to 'packages/patches/delwrite~_nogui_fix-0.42.5.patch')
-rw-r--r--packages/patches/delwrite~_nogui_fix-0.42.5.patch75
1 files changed, 0 insertions, 75 deletions
diff --git a/packages/patches/delwrite~_nogui_fix-0.42.5.patch b/packages/patches/delwrite~_nogui_fix-0.42.5.patch
deleted file mode 100644
index d1172156..00000000
--- a/packages/patches/delwrite~_nogui_fix-0.42.5.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-Index: d_delay.c
-===================================================================
---- d_delay.c (révision 13558)
-+++ d_delay.c (copie de travail)
-@@ -24,6 +24,7 @@
- {
- t_object x_obj;
- t_symbol *x_sym;
-+ t_float x_deltime; /* delay in msec (added by Mathieu Bouchard) */
- t_delwritectl x_cspace;
- int x_sortno; /* DSP sort number at which this was last put on chain */
- int x_rsortno; /* DSP sort # for first delread or write in chain */
-@@ -34,6 +35,21 @@
- #define XTRASAMPS 4
- #define SAMPBLK 4
-
-+static void sigdelwrite_updatesr (t_sigdelwrite *x, t_float sr) /* added by Mathieu Bouchard */
-+{
-+ int nsamps = x->x_deltime * sr * (t_float)(0.001f);
-+ if (nsamps < 1) nsamps = 1;
-+ nsamps += ((- nsamps) & (SAMPBLK - 1));
-+ nsamps += DEFDELVS;
-+ if (x->x_cspace.c_n != nsamps) {
-+ x->x_cspace.c_vec = (t_sample *)resizebytes(x->x_cspace.c_vec,
-+ (x->x_cspace.c_n + XTRASAMPS) * sizeof(t_sample),
-+ ( nsamps + XTRASAMPS) * sizeof(t_sample));
-+ x->x_cspace.c_n = nsamps;
-+ x->x_cspace.c_phase = XTRASAMPS;
-+ }
-+}
-+
- /* routine to check that all delwrites/delreads/vds have same vecsize */
- static void sigdelwrite_checkvecsize(t_sigdelwrite *x, int vecsize)
- {
-@@ -54,19 +70,13 @@
-
- static void *sigdelwrite_new(t_symbol *s, t_floatarg msec)
- {
-- int nsamps;
- t_sigdelwrite *x = (t_sigdelwrite *)pd_new(sigdelwrite_class);
- if (!*s->s_name) s = gensym("delwrite~");
- pd_bind(&x->x_obj.ob_pd, s);
- x->x_sym = s;
-- nsamps = msec * sys_getsr() * (t_float)(0.001f);
-- if (nsamps < 1) nsamps = 1;
-- nsamps += ((- nsamps) & (SAMPBLK - 1));
-- nsamps += DEFDELVS;
-- x->x_cspace.c_n = nsamps;
-- x->x_cspace.c_vec =
-- (t_sample *)getbytes((nsamps + XTRASAMPS) * sizeof(t_sample));
-- x->x_cspace.c_phase = XTRASAMPS;
-+ x->x_deltime = msec;
-+ x->x_cspace.c_n = 0;
-+ x->x_cspace.c_vec = getbytes(XTRASAMPS * sizeof(t_sample));
- x->x_sortno = 0;
- x->x_vecsize = 0;
- x->x_f = 0;
-@@ -109,6 +119,7 @@
- dsp_add(sigdelwrite_perform, 3, sp[0]->s_vec, &x->x_cspace, sp[0]->s_n);
- x->x_sortno = ugen_getsortno();
- sigdelwrite_checkvecsize(x, sp[0]->s_n);
-+ sigdelwrite_updatesr(x, sp[0]->s_sr);
- }
-
- static void sigdelwrite_free(t_sigdelwrite *x)
-@@ -200,6 +211,7 @@
- x->x_n = sp[0]->s_n;
- if (delwriter)
- {
-+ sigdelwrite_updatesr(delwriter, sp[0]->s_sr);
- sigdelwrite_checkvecsize(delwriter, sp[0]->s_n);
- x->x_zerodel = (delwriter->x_sortno == ugen_getsortno() ?
- 0 : delwriter->x_vecsize);
-
-