[Gridflow-cvs] [svn] commit: r6051 - /trunk/src/classes2.cxx

svn-gridflow at artengine.ca svn-gridflow at artengine.ca
Thu Aug 12 21:24:12 EDT 2010


Author: matju
Date: Thu Aug 12 21:24:12 2010
New Revision: 6051

Log:
add 2nd inlet

Modified:
    trunk/src/classes2.cxx

Modified: trunk/src/classes2.cxx
==============================================================================
--- trunk/src/classes2.cxx (original)
+++ trunk/src/classes2.cxx Thu Aug 12 21:24:12 2010
@@ -761,6 +761,7 @@
 \class GFSprintf : FObject {
 	string format;
 	\constructor (...) {format = join(argc,argv);}
+	\decl 1 list (...) {format = join(argc,argv);}
 	\decl 0 bang   ()          {_0_list(0,0);}
 	\decl 0 float  (t_atom2 a) {_0_list(1,&a);}
 	\decl 0 symbol (t_atom2 a) {_0_list(1,&a);}
@@ -768,14 +769,15 @@
 		std::ostringstream o;
 		pd_oprintf(o,format.data(),argc,argv);
 		string s = o.str();
-		outlet_symbol(outlets[0],gensym(o.str().data()));
-	}
-};
-\end class {install("gf/sprintf",1,1);}
+		outlet_symbol(outlets[0],gensym(s.data()));
+	}
+};
+\end class {install("gf/sprintf",2,1);}
 \class GridSprintf : FObject {
 	string format;
 	\attr NumberTypeE cast;
 	\constructor (...) {format = join(argc,argv); cast = int32_e;}
+	\decl 1 list (...) {format = join(argc,argv);}
 	\decl 0 bang   ()          {_0_list(0,0);}
 	\decl 0 float  (t_atom2 a) {_0_list(1,&a);}
 	\decl 0 symbol (t_atom2 a) {_0_list(1,&a);}
@@ -786,7 +788,7 @@
 		GridOutlet out(this,0,Dim(s.size()),cast); out.send(s.size(),(uint8 *)s.data());
 	}
 };
-\end class {install("#sprintf",1,1);}
+\end class {install("#sprintf",2,1);}
 
 \class ForEach : FObject {
 	\constructor () {}



More information about the Gridflow-cvs mailing list