Update of /cvsroot/pure-data/externals/unauthorized/sonogram~
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8741
Modified Files:
CHANGES.LOG sonogram~.c
Log Message:
fixed coordinates for GOP
Index: CHANGES.LOG
===================================================================
RCS file: /cvsroot/pure-data/externals/unauthorized/sonogram~/CHANGES.LOG,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** CHANGES.LOG 2 Mar 2005 02:48:57 -0000 1.3
--- CHANGES.LOG 26 Jul 2006 16:57:46 -0000 1.4
***************
*** 1,2 ****
--- 1,4 ----
+ 0.14
+ remove GOP support
0.13
added GOP support
Index: sonogram~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/unauthorized/sonogram~/sonogram~.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** sonogram~.c 7 Apr 2006 02:06:09 -0000 1.12
--- sonogram~.c 26 Jul 2006 16:57:46 -0000 1.13
***************
*** 30,36 ****
- /* this doesn't compile on MinGW */
- #ifndef _WIN32
-
#include <sys/types.h>
--- 30,33 ----
***************
*** 41,65 ****
#include <fcntl.h>
#include <sys/stat.h>
-
- #ifdef __APPLE__
- #include <sys/malloc.h>
- #else
#include <malloc.h>
- #endif
-
#include <ctype.h>
#include <pthread.h>
! #ifdef _WIN32
! #include <io.h>
! #define random rand
! #define usleep(a) _sleep(a/1000)
! #else
#include <unistd.h>
#endif
! #include <math.h>
!
! #ifndef M_PI
#define M_PI 3.14159265358979323846
#endif
#include "m_pd.h"
--- 38,51 ----
#include <fcntl.h>
#include <sys/stat.h>
#include <malloc.h>
#include <ctype.h>
#include <pthread.h>
! #ifdef UNIX
#include <unistd.h>
#endif
! #ifdef NT
#define M_PI 3.14159265358979323846
#endif
+ #include <math.h>
#include "m_pd.h"
***************
*** 111,115 ****
#define THREAD_SLEEP_TIME 100000 // 100000 us = 100 ms
! static char *sonogram_version = "sonogram~: version 0.12, written by Yves Degoyon (ydegoyon(a)free.fr)";
static t_class *sonogram_class;
--- 97,101 ----
#define THREAD_SLEEP_TIME 100000 // 100000 us = 100 ms
! static char *sonogram_version = "sonogram~: version 0.14, written by Yves Degoyon (ydegoyon(a)free.fr)";
static t_class *sonogram_class;
***************
*** 335,339 ****
for ( i=0; i<x->x_zoom; i++ )
{
! sprintf( x->x_guicommand, "SONIMAGE%x put {%s} -to %d 0\n", (unsigned int)x, x->x_gifdata, (int) ((bnumber*x->x_zoom)+i) );
sys_gui( x->x_guicommand );
}
--- 321,325 ----
for ( i=0; i<x->x_zoom; i++ )
{
! sprintf( x->x_guicommand, "SONIMAGE%x put {%s} -to %d 0\n", (unsigned int)x, x->x_gifdata, (bnumber*x->x_zoom)+i );
sys_gui( x->x_guicommand );
}
***************
*** 355,359 ****
for ( i=0; i<x->x_zoom; i++ )
{
! sprintf( x->x_guicommand, "FAZIMAGE%x put {%s} -to %d 0\n", (unsigned int)x, x->x_gifdata, (int) ((bnumber*x->x_zoom)+i) );
sys_gui( x->x_guicommand );
}
--- 341,345 ----
for ( i=0; i<x->x_zoom; i++ )
{
! sprintf( x->x_guicommand, "FAZIMAGE%x put {%s} -to %d 0\n", (unsigned int)x, x->x_gifdata, (bnumber*x->x_zoom)+i );
sys_gui( x->x_guicommand );
}
***************
*** 386,398 ****
static void *sonogram_do_update_part(void *tdata)
{
! t_sonogram *x = (t_sonogram*) tdata;
! t_int si;
! t_int nbpoints = 0;
! t_float percentage = 0, opercentage = 0;
! t_canvas *canvas=glist_getcanvas(x->x_glist);
!
!
// loose synchro
! usleep( THREAD_SLEEP_TIME );
// check boundaries
--- 372,384 ----
static void *sonogram_do_update_part(void *tdata)
{
! t_sonogram *x = (t_sonogram*) tdata;
! t_int si;
! t_int nbpoints = 0;
! t_float percentage = 0, opercentage = 0;
! t_canvas *canvas=glist_getcanvas(x->x_glist);
!
!
// loose synchro
! usleep( THREAD_SLEEP_TIME );
// check boundaries
***************
*** 861,865 ****
binbuf_addv(b, "ssiisiii", gensym("#X"),gensym("obj"),
! (t_int)x->x_xpos, (t_int)x->x_ypos,
gensym("sonogram~"), x->x_size, x->x_graphic, x->x_phaso );
binbuf_addv(b, ";");
--- 847,851 ----
binbuf_addv(b, "ssiisiii", gensym("#X"),gensym("obj"),
! (t_int)x->x_obj.te_xpix, (t_int)x->x_obj.te_ypix,
gensym("sonogram~"), x->x_size, x->x_graphic, x->x_phaso );
binbuf_addv(b, ";");
***************
*** 2091,2094 ****
class_addmethod(sonogram_class, (t_method)sonogram_undo, gensym("undo"), A_NULL);
}
-
- #endif /* not _WIN32 */
--- 2077,2078 ----