[Gridflow-cvs] [svn] commit: r3604 - in /trunk/base: flow_objects.c grid.h

gridflow-cvs at artengine.ca gridflow-cvs at artengine.ca
Fri Apr 18 18:04:16 EDT 2008


Author: matju
Date: Fri Apr 18 18:04:16 2008
New Revision: 3604

Log:
t_atom2* arguments instead of Ruby* ... last part

Modified:
    trunk/base/flow_objects.c
    trunk/base/grid.h

Modified: trunk/base/flow_objects.c
==============================================================================
--- trunk/base/flow_objects.c (original)
+++ trunk/base/flow_objects.c Fri Apr 18 18:04:16 2008
@@ -2248,10 +2248,9 @@
 };
 \def 0 list (...) {
 	t_outlet *o = bself->out[0];
-	R *a = (R *)argv;
 	for (int i=0; i<argc; i++) {
-		if      (argv[i].a_type==A_FLOAT)  outlet_float( o,a[i]);
-		else if (argv[i].a_type==A_SYMBOL) outlet_symbol(o,a[i]);
+		if      (argv[i].a_type==A_FLOAT)  outlet_float( o,argv[i]);
+		else if (argv[i].a_type==A_SYMBOL) outlet_symbol(o,argv[i]);
 		else RAISE("oops. unsupported.");
 	}
 }

Modified: trunk/base/grid.h
==============================================================================
--- trunk/base/grid.h (original)
+++ trunk/base/grid.h Fri Apr 18 18:04:16 2008
@@ -319,8 +319,13 @@
  		return a_symbol;}
 	operator std::string () const {
 		if (a_type!=A_SYMBOL) RAISE("expected symbol");
-		return std::string(a_symbol->s_name);
-	}
+		return std::string(a_symbol->s_name);}
+	operator void * () const {
+		if (a_type!=A_POINTER) RAISE("expected pointer");
+ 		return a_gpointer;}
+	operator t_binbuf * () const {
+		if (a_type!=A_LIST) RAISE("expected nested list");
+ 		return (t_binbuf *)a_gpointer;}
 };
 
 template <class T> T convert(const t_atom &x, T *foo) {const t_atom2 *xx = (const t_atom2 *)&x; return (T)*xx;}
@@ -961,8 +966,8 @@
 
 #define install_format(name,mode,suffixes) do {install(name,1,1); suffixes_are(name,suffixes);} while(0)
 
-
-#define SUPER rb_call_super(argc,argv);
+void call_super(int argc, t_atom *argv);
+#define SUPER call_super(argc,argv);
 
 \class Format : GridObject {
 	int mode;



More information about the Gridflow-cvs mailing list