[PD-cvs] externals/clr clr.c,1.3,1.4
dmorelli
morellid at users.sourceforge.net
Fri Jan 13 14:02:24 CET 2006
Update of /cvsroot/pure-data/externals/clr
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20621
Modified Files:
clr.c
Log Message:
single atom ok, no luck with arrays
Index: clr.c
===================================================================
RCS file: /cvsroot/pure-data/externals/clr/clr.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** clr.c 12 Jan 2006 17:09:45 -0000 1.3
--- clr.c 13 Jan 2006 13:02:17 -0000 1.4
***************
*** 50,53 ****
--- 50,54 ----
A_S_SYMBOL=2,
} t_atomtype_simple;
+
typedef struct atom_simple
{
***************
*** 61,64 ****
--- 62,72 ----
};
+ /*
+ typedef struct atom_simple
+ {
+ int a;
+ int b;
+ };
+ */
static t_class *clr_class;
***************
*** 304,308 ****
float *fp;
! MonoClass *c = mono_class_from_name (x->image, "PureData", "Atom");
arystr = mono_array_new (x->domain, c /*mono_get_string_class ()*/, argc);
//arystr = mono_array_new (x->domain, c, 2);
--- 312,319 ----
float *fp;
! MonoClass *c = mono_class_from_name (x->image, "PureData", "Atom2");
! if (!c)
! error("----> can't find Atom");
! //arystr = mono_array_new (x->domain, atom_simple, argc);
arystr = mono_array_new (x->domain, c /*mono_get_string_class ()*/, argc);
//arystr = mono_array_new (x->domain, c, 2);
***************
*** 354,365 ****
// send just 1 atom
- atmp2 = malloc(sizeof(atom_simple));
- atmp2->a_type = 121;
- atmp2->float_value = atom_getfloat(argv);
- strsymbol = atom_getsymbol(argv);
- atmp2->string_value = mono_string_new (x->domain, strsymbol->s_name);
- args[0] = atmp2;
/*
// a list of atoms
--- 365,385 ----
// send just 1 atom
+ atmp2 = malloc(sizeof(atom_simple));
+ atmp2->a_type = 121;
+ atmp2->float_value = atom_getfloat(argv);
+ strsymbol = atom_getsymbol(argv);
+ printf("strsymbol->s_name = %s\n", strsymbol->s_name);
+ atmp2->string_value = mono_string_new (x->domain, strsymbol->s_name);
+ args[0] = atmp2;
+
+ /*
+ atmp2 = malloc(sizeof(atom_simple));
+ atmp2->a = 121;
+ atmp2->b = 1;
+ args[0] = atmp2;
+ */
+
/*
// a list of atoms
***************
*** 384,388 ****
mono_array_set (arystr, atom_simple *, 1, atmp3);
*/
! // args[0] = arystr;
//args[0] = strings;
--- 404,408 ----
mono_array_set (arystr, atom_simple *, 1, atmp3);
*/
! //args[0] = arystr;
//args[0] = strings;
More information about the Pd-cvs
mailing list