Update of /cvsroot/pure-data/pd/extra/expr~ In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13977
Modified Files: Tag: branch-v0-39-2-extended vexp_if.c Log Message: reverted to previous version of this file since this doesn't compile on MinGW/Win32
Index: vexp_if.c =================================================================== RCS file: /cvsroot/pure-data/pd/extra/expr~/vexp_if.c,v retrieving revision 1.5.8.1 retrieving revision 1.5.8.2 diff -C2 -d -r1.5.8.1 -r1.5.8.2 *** vexp_if.c 20 Apr 2007 03:33:44 -0000 1.5.8.1 --- vexp_if.c 25 Apr 2007 14:39:54 -0000 1.5.8.2 *************** *** 896,903 **** t_garray *garray; int size, indx; ! t_word *wvec;
if (!s || !(garray = (t_garray *)pd_findbyclass(s, garray_class)) || ! !garray_getfloatwords(garray, &size, &wvec)) { optr->ex_type = ET_FLT; --- 896,903 ---- t_garray *garray; int size, indx; ! t_float *vec;
if (!s || !(garray = (t_garray *)pd_findbyclass(s, garray_class)) || ! !garray_getfloatarray(garray, &size, &vec)) { optr->ex_type = ET_FLT; *************** *** 923,927 **** if (indx < 0) indx = 0; else if (indx >= size) indx = size - 1; ! optr->ex_flt = wvec[indx].w_float; #else /* MSP */ /* --- 923,927 ---- if (indx < 0) indx = 0; else if (indx >= size) indx = size - 1; ! optr->ex_flt = vec[indx]; #else /* MSP */ /* *************** *** 953,957 **** #define ISTABLE(sym, garray, size, vec) \ if (!sym || !(garray = (t_garray *)pd_findbyclass(sym, garray_class)) || \ ! !garray_getfloatwords(garray, &size, &vec)) { \ optr->ex_type = ET_FLT; \ optr->ex_int = 0; \ --- 953,957 ---- #define ISTABLE(sym, garray, size, vec) \ if (!sym || !(garray = (t_garray *)pd_findbyclass(sym, garray_class)) || \ ! !garray_getfloatarray(garray, &size, &vec)) { \ optr->ex_type = ET_FLT; \ optr->ex_int = 0; \ *************** *** 969,973 **** t_garray *garray; int size; ! t_word *wvec;
if (argv->ex_type != ET_SYM) --- 969,973 ---- t_garray *garray; int size; ! t_float *vec;
if (argv->ex_type != ET_SYM) *************** *** 981,985 **** s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, wvec);
optr->ex_type = ET_INT; --- 981,985 ---- s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, vec);
optr->ex_type = ET_INT; *************** *** 997,1002 **** t_garray *garray; int size; ! t_word *wvec; ! float sum; int indx;
--- 997,1001 ---- t_garray *garray; int size; ! t_float *vec, sum; int indx;
*************** *** 1011,1018 **** s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, wvec);
for (indx = 0, sum = 0; indx < size; indx++) ! sum += wvec[indx].w_float;
optr->ex_type = ET_FLT; --- 1010,1017 ---- s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, vec);
for (indx = 0, sum = 0; indx < size; indx++) ! sum += vec[indx];
optr->ex_type = ET_FLT; *************** *** 1031,1036 **** t_garray *garray; int size; ! t_word *wvec; ! t_float sum; int indx, n1, n2;
--- 1030,1034 ---- t_garray *garray; int size; ! t_float *vec, sum; int indx, n1, n2;
*************** *** 1045,1049 **** s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, wvec);
if (argv->ex_type != ET_INT || argv[1].ex_type != ET_INT) --- 1043,1047 ---- s = (fts_symbol_t ) argv->ex_ptr;
! ISTABLE(s, garray, size, vec);
if (argv->ex_type != ET_INT || argv[1].ex_type != ET_INT) *************** *** 1059,1063 **** for (indx = n1, sum = 0; indx < n2; indx++) if (indx >= 0 && indx < size) ! sum += wvec[indx].w_float;
optr->ex_type = ET_FLT; --- 1057,1061 ---- for (indx = n1, sum = 0; indx < n2; indx++) if (indx >= 0 && indx < size) ! sum += vec[indx];
optr->ex_type = ET_FLT;