mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-11 22:22:33 -05:00
Fix even more 'set but not used' warnings and a regression.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29873 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
4f4edd89e4
commit
2aa0759077
3 changed files with 32 additions and 9 deletions
|
|
@ -110,9 +110,12 @@ void hlshelf_check(t_hlshelf *x)
|
|||
void hlshelf_bang(t_hlshelf *x)
|
||||
{
|
||||
t_atom at[6];
|
||||
/* float c0; unused */
|
||||
#ifndef ROCKBOX
|
||||
float c0;
|
||||
float g1, g2;
|
||||
#endif
|
||||
float c1, c2, d0, d1, d2; /* output coefs */
|
||||
float a1, a2, b1, b2, g1, g2; /* temp coefs */
|
||||
float a1, a2, b1, b2; /* temp coefs */
|
||||
double xf;
|
||||
|
||||
hlshelf_check(x);
|
||||
|
|
@ -123,7 +126,9 @@ void hlshelf_bang(t_hlshelf *x)
|
|||
{
|
||||
a1 = 1.0f;
|
||||
b1 = -1.0f;
|
||||
#ifndef ROCKBOX
|
||||
g1 = 0.0f;
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -134,7 +139,9 @@ void hlshelf_bang(t_hlshelf *x)
|
|||
|
||||
a1 = (r - 1) / (r + 1);
|
||||
b1 = (kr - 1) / (kr + 1);
|
||||
#ifndef ROCKBOX
|
||||
g1 = (kr + 1) / (r + 1);
|
||||
#endif
|
||||
}
|
||||
|
||||
/* high shelf */
|
||||
|
|
@ -143,7 +150,9 @@ void hlshelf_bang(t_hlshelf *x)
|
|||
{
|
||||
a2 = -1.0f;
|
||||
b2 = 1.0f;
|
||||
#ifndef ROCKBOX
|
||||
g2 = 0.0f;
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -154,11 +163,15 @@ void hlshelf_bang(t_hlshelf *x)
|
|||
|
||||
a2 = (1 - r) / (1 + r);
|
||||
b2 = (1 - kr) / (1 + kr);
|
||||
#ifndef ROCKBOX
|
||||
g2 = (1 + kr) / (1 + r);
|
||||
#endif
|
||||
}
|
||||
|
||||
/* form product */
|
||||
/* c0 = g1 * g2 * (float)(exp((double)(x->s_gain1) * 0.05f * 2.302585093f)); unused */
|
||||
#ifndef ROCKBOX
|
||||
c0 = g1 * g2 * (float)(exp((double)(x->s_gain1) * 0.05f * 2.302585093f));
|
||||
#endif
|
||||
c1 = a1 + a2;
|
||||
c2 = a1 * a2;
|
||||
d0 = 1.0f;
|
||||
|
|
@ -167,7 +180,10 @@ void hlshelf_bang(t_hlshelf *x)
|
|||
|
||||
if (!hlshelf_check_stability(-c1/d0,-c2/d0,d0/d0,d1/d0,d2/d0)) {
|
||||
post("hlshelf: filter unstable -> resetting");
|
||||
/* c0=1.; unused */ c1=0.;c2=0.;
|
||||
#ifndef ROCKBOX
|
||||
c0=1.;
|
||||
#endif
|
||||
c1=0.;c2=0.;
|
||||
d0=1.;d1=0.;d2=0.;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -136,8 +136,10 @@ static t_int *sfwrite_perform(t_int *w)
|
|||
int i,num,n;
|
||||
short* tout = out;
|
||||
int ret;
|
||||
#ifndef ROCKBOX
|
||||
int timebefore,timeafter;
|
||||
/* double late; unused */
|
||||
double late;
|
||||
#endif
|
||||
|
||||
for (i=0;i < c;i++) {
|
||||
in[i] = (t_sample *)(w[2+i]);
|
||||
|
|
@ -155,13 +157,17 @@ static t_int *sfwrite_perform(t_int *w)
|
|||
}
|
||||
}
|
||||
|
||||
#ifndef ROCKBOX
|
||||
timebefore = sys_getrealtime();
|
||||
#endif
|
||||
if ((ret =write(x->x_file,out,sizeof(short)*num*c)) < (signed int)sizeof(short)*num*c) {
|
||||
post("sfwrite: short write %d",ret);
|
||||
|
||||
}
|
||||
#ifndef ROCKBOX
|
||||
timeafter = sys_getrealtime();
|
||||
/* late = timeafter - timebefore; unused */
|
||||
late = timeafter - timebefore;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
/* OK, we let only 10 ms block here */
|
||||
|
|
|
|||
|
|
@ -813,14 +813,15 @@ static t_gobj *canvas_findhitbox(t_canvas *x, int xpos, int ypos,
|
|||
/* right-clicking on a canvas object pops up a menu. */
|
||||
static void canvas_rightclick(t_canvas *x, int xpos, int ypos, t_gobj *y)
|
||||
{
|
||||
/* int canprop, canopen; unused */
|
||||
/* canprop = */ (!y || (y && class_getpropertiesfn(pd_class(&y->g_pd))));
|
||||
/* canopen = */ (y && zgetfn(&y->g_pd, gensym("menu-open")));
|
||||
#ifdef ROCKBOX
|
||||
(void) x;
|
||||
(void) xpos;
|
||||
(void) ypos;
|
||||
(void) y;
|
||||
#else /* ROCKBOX */
|
||||
int canprop, canopen;
|
||||
canprop = (!y || (y && class_getpropertiesfn(pd_class(&y->g_pd))));
|
||||
canopen = (y && zgetfn(&y->g_pd, gensym("menu-open")));
|
||||
sys_vgui("pdtk_canvas_popup .x%x %d %d %d %d\n",
|
||||
x, xpos, ypos, canprop, canopen);
|
||||
#endif /* ROCKBOX */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue