diff options
author | Katja <katjav@users.sourceforge.net> | 2011-11-06 15:38:24 +0000 |
---|---|---|
committer | Katja <katjav@users.sourceforge.net> | 2011-11-06 15:38:24 +0000 |
commit | 7d41c2213b5070d444fa17cdb04eeb9fdc955309 (patch) | |
tree | 930e28f8ef74a6343d1cf3962e21048447651420 /lavg.c | |
parent | 2e5402b354317ba36480d00de4f1aced6755b7cf (diff) |
made smlib compliant with double precision
svn path=/trunk/externals/smlib/; revision=15707
Diffstat (limited to 'lavg.c')
-rw-r--r-- | lavg.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -7,9 +7,9 @@ static t_class *lavg_class; typedef struct _lavg
{
t_object x_obj;
- float m_avg;
- float m_c_leak;
- float m_leak;
+ t_float m_avg;
+ t_float m_c_leak;
+ t_float m_leak;
} t_lavg;
@@ -21,13 +21,13 @@ static void lavg_perform(t_lavg *x, t_float in) static void lavg_clear(t_lavg *x)
{
- x->m_avg=0.0f;
+ x->m_avg=0.0;
}
static void lavg_setHalfDecay(t_lavg *x, t_float halfDecayTime)
{
- x->m_c_leak=(float)powf(.5,(1.0f/halfDecayTime));
- x->m_leak=1.0f-x->m_c_leak;
+ x->m_c_leak=(t_float)powf(.5,(1.0/halfDecayTime));
+ x->m_leak=1.0-x->m_c_leak;
}
static void *lavg_new( t_float halfDecayTime)
|