[PD-cvs] externals/creb/modules eadsr~.c, 1.1, 1.2 ead~.c, 1.1, 1.2 ear~.c, 1.1, 1.2

Hans-Christoph Steiner eighthave at users.sourceforge.net
Thu May 25 18:47:34 CEST 2006


Update of /cvsroot/pure-data/externals/creb/modules
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv387

Modified Files:
	eadsr~.c ead~.c ear~.c 
Log Message:
appended externals/creb/system/envelope_util.c to the end to make building dead simple

Index: eadsr~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/creb/modules/eadsr~.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** eadsr~.c	25 May 2006 16:40:19 -0000	1.1
--- eadsr~.c	25 May 2006 16:47:32 -0000	1.2
***************
*** 173,174 ****
--- 173,207 ----
  }
  
+ /*
+  *   Utility functions for exponential decay 
+  *   Copyright (c) 2000-2003 by Tom Schouten
+  *
+  *   This program is free software; you can redistribute it and/or modify
+  *   it under the terms of the GNU General Public License as published by
+  *   the Free Software Foundation; either version 2 of the License, or
+  *   (at your option) any later version.
+  *
+  *   This program is distributed in the hope that it will be useful,
+  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  *   GNU General Public License for more details.
+  *
+  *   You should have received a copy of the GNU General Public License
+  *   along with this program; if not, write to the Free Software
+  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+  */
+ 
+ 
+ #include "extlib_util.h"
+ 
+ float milliseconds_2_one_minus_realpole(float time)
+ {
+   float r;
+ 
+   if (time < 0.0f) time = 0.0f;
+   r = -expm1(1000.0f * log(ENVELOPE_RANGE) / (sys_getsr() * time));
+   if (!(r < 1.0f)) r = 1.0f;
+ 
+   //post("%f",r);
+   return r;
+ }

Index: ear~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/creb/modules/ear~.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** ear~.c	25 May 2006 16:40:19 -0000	1.1
--- ear~.c	25 May 2006 16:47:32 -0000	1.2
***************
*** 143,144 ****
--- 143,177 ----
  }
  
+ /*
+  *   Utility functions for exponential decay 
+  *   Copyright (c) 2000-2003 by Tom Schouten
+  *
+  *   This program is free software; you can redistribute it and/or modify
+  *   it under the terms of the GNU General Public License as published by
+  *   the Free Software Foundation; either version 2 of the License, or
+  *   (at your option) any later version.
+  *
+  *   This program is distributed in the hope that it will be useful,
+  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  *   GNU General Public License for more details.
+  *
+  *   You should have received a copy of the GNU General Public License
+  *   along with this program; if not, write to the Free Software
+  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+  */
+ 
+ 
+ #include "extlib_util.h"
+ 
+ float milliseconds_2_one_minus_realpole(float time)
+ {
+   float r;
+ 
+   if (time < 0.0f) time = 0.0f;
+   r = -expm1(1000.0f * log(ENVELOPE_RANGE) / (sys_getsr() * time));
+   if (!(r < 1.0f)) r = 1.0f;
+ 
+   //post("%f",r);
+   return r;
+ }

Index: ead~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/creb/modules/ead~.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** ead~.c	25 May 2006 16:40:19 -0000	1.1
--- ead~.c	25 May 2006 16:47:32 -0000	1.2
***************
*** 157,158 ****
--- 157,191 ----
  }
  
+ /*
+  *   Utility functions for exponential decay 
+  *   Copyright (c) 2000-2003 by Tom Schouten
+  *
+  *   This program is free software; you can redistribute it and/or modify
+  *   it under the terms of the GNU General Public License as published by
+  *   the Free Software Foundation; either version 2 of the License, or
+  *   (at your option) any later version.
+  *
+  *   This program is distributed in the hope that it will be useful,
+  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  *   GNU General Public License for more details.
+  *
+  *   You should have received a copy of the GNU General Public License
+  *   along with this program; if not, write to the Free Software
+  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+  */
+ 
+ 
+ #include "extlib_util.h"
+ 
+ float milliseconds_2_one_minus_realpole(float time)
+ {
+   float r;
+ 
+   if (time < 0.0f) time = 0.0f;
+   r = -expm1(1000.0f * log(ENVELOPE_RANGE) / (sys_getsr() * time));
+   if (!(r < 1.0f)) r = 1.0f;
+ 
+   //post("%f",r);
+   return r;
+ }





More information about the Pd-cvs mailing list