Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22021
Modified Files: Tag: desiredata builtins.c Log Message: removed more pointer stuff
Index: builtins.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/builtins.c,v retrieving revision 1.1.2.45 retrieving revision 1.1.2.46 diff -C2 -d -r1.1.2.45 -r1.1.2.46 *** builtins.c 20 Jul 2007 14:19:27 -0000 1.1.2.45 --- builtins.c 20 Jul 2007 14:33:55 -0000 1.1.2.46 *************** *** 1426,1430 **** t_pack *x = (t_pack *)pd_new(pack_class); t_atom defarg[2], *ap, *vec, *vp; - int nptr = 0; if (!argc) { argv = defarg; --- 1426,1429 ---- *************** *** 1436,1444 **** vec = x->vec = (t_atom *)getbytes(argc * sizeof(*x->vec)); x->outvec = (t_atom *)getbytes(argc * sizeof(*x->outvec)); ! int i; ! for (i = argc, ap = argv; i--; ap++) ! if (ap->a_type == A_SYMBOL && *ap->a_symbol->name == 'p') ! nptr++; ! for (i = 0, vp = x->vec, ap = argv; i < argc; i++, ap++, vp++) { if (ap->a_type == A_FLOAT) { *vp = *ap; --- 1435,1441 ---- vec = x->vec = (t_atom *)getbytes(argc * sizeof(*x->vec)); x->outvec = (t_atom *)getbytes(argc * sizeof(*x->outvec)); ! vp = x->vec; ! ap = argv; ! for (int i = 0; i < argc; i++, ap++, vp++) { if (ap->a_type == A_FLOAT) { *vp = *ap; *************** *** 1446,1462 **** } else if (ap->a_type == A_SYMBOL) { char c = *ap->a_symbol->name; ! if (c == 's') { ! SETSYMBOL(vp, &s_symbol); ! if (i) symbolinlet_new(x, &vp->a_symbol); ! } else if (c == 'p') { ! vp->a_type = A_POINTER; ! //vp->a_pointer = gp; ! //gpointer_init(gp); ! //if (i) pointerinlet_new(x, gp); ! } else { ! if (c != 'f') error("pack: %s: bad type", ap->a_symbol->name); ! SETFLOAT(vp, 0); ! if (i) floatinlet_new(x, &vp->a_float); ! } } } --- 1443,1450 ---- } else if (ap->a_type == A_SYMBOL) { char c = *ap->a_symbol->name; ! if (c == 's') { SETSYMBOL(vp, &s_symbol); if (i) symbolinlet_new(x, &vp->a_symbol);} ! else if (c == 'p') { /* SETPOINTER(vp, gpointer_new()) if (i) pointerinlet_new(x, gp); */} ! else if (c == 'f') { SETFLOAT(vp, 0); if (i) floatinlet_new(x, &vp->a_float);} ! else error("pack: %s: bad type '%c'", ap->a_symbol->name, c); } } *************** *** 2702,2706 **** struct t_pipe : t_object { int n; - int nptr; float deltime; t_atom *vec; --- 2690,2693 ---- *************** *** 2711,2715 **** t_atom defarg, *ap; t_atom *vec, *vp; - int nptr = 0; float deltime=0; if (argc) { --- 2698,2701 ---- *************** *** 2729,2734 **** vec = x->vec = (t_atom *)getbytes(argc * sizeof(*x->vec)); int i; - for (i = argc, ap = argv; i--; ap++) if (ap->a_type == A_SYMBOL && *ap->a_symbol->name == 'p') nptr++; - x->nptr = nptr; for (i = 0, vp = vec, ap = argv; i < argc; i++, ap++, vp++) { if (ap->a_type == A_FLOAT) { --- 2715,2718 ----