[Gridflow-cvs] [svn] commit: r6117 - in /trunk: doc/flow_classes/gf/class_info-help.pd src/classes2.cxx

svn-gridflow at artengine.ca svn-gridflow at artengine.ca
Sun Aug 15 13:53:50 EDT 2010


Author: matju
Date: Sun Aug 15 13:53:49 2010
New Revision: 6117

Log:
[gf/class_info]: report 'inlets' 'outlets'

Modified:
    trunk/doc/flow_classes/gf/class_info-help.pd
    trunk/src/classes2.cxx

Modified: trunk/doc/flow_classes/gf/class_info-help.pd
==============================================================================
--- trunk/doc/flow_classes/gf/class_info-help.pd (original)
+++ trunk/doc/flow_classes/gf/class_info-help.pd Sun Aug 15 13:53:49 2010
@@ -1,8 +1,8 @@
 #N canvas 0 0 632 704 10;
 #X obj 0 0 doc_h gf/;
-#X obj 3 1020 doc_also;
-#X obj 0 1040 doc_f;
-#X obj 103 1020 class_exists;
+#X obj 3 1342 doc_also;
+#X obj 0 1362 doc_f;
+#X obj 103 1342 class_exists;
 #X obj 3 378 doc_o 1;
 #X obj 14 408 doc_oo 0;
 #X obj 3 290 doc_i 1;
@@ -16,38 +16,35 @@
 #X obj 10 220 print;
 #X obj 543 73 #pack 4;
 #X msg 543 47 help;
-#X text 232 408 if class or alias is not found in GridFlow's class
-database.;
-#X obj 97 539 doc_m o0 method;
-#X text 232 539 indicates that the class has a method named \$2 in
+#X obj 97 726 doc_m o0 method;
+#X text 232 726 indicates that the class has a method named \$2 in
 inlet \$1.;
-#X text 232 622 inlet -1 represents methods that exist in all inlets
+#X text 232 809 inlet -1 represents methods that exist in all inlets
 at once from a single definition. this occurs normally only when there
 is a variable number of inlets.;
-#X text 232 670 a grid method is listed three times : each grid method
+#X text 232 857 a grid method is listed three times : each grid method
 is accompanied by a float method and a list method. If any local float
 method or list method is hiding the default method(s) brought by the
 grid method \, you will not notice.;
-#X text 232 731 "method -2 anything" represents a method that catches
+#X text 232 918 "method -2 anything" represents a method that catches
 anything in any inlet at once.;
-#X text 232 766 there is currently no way to define a anything in a
+#X text 232 953 there is currently no way to define a anything in a
 single inlet at a time.;
-#X text 232 801 other methods in inlet -2 are for internal use ONLY.
+#X text 232 988 other methods in inlet -2 are for internal use ONLY.
 they are not directly reachable from pd.;
-#X text 232 561 the constructor (aka creator or new-method) and the
+#X text 232 748 the constructor (aka creator or new-method) and the
 destructor (free-method) are not listed. the dsp-method and perform-function
 (for ~ objects) are not listed. however \, the loadbang method is listed.
 ;
-#X text 232 836 inlet numbers don't correspond in some rare cases :
-when the CLASS_NOINLET option is in use \, GF inlet numbers don't match
-Pd inlet numbers \, the left inlet will be numbered 1 instead of 0
-\, and inlet 0 will be invisible. GF currently only uses this for [#from~]
-\, but may come to use it for [shunt] \, [route2] \, [route3] and some
-more.;
+#X text 232 1023 inlet numbers don't correspond in some rare cases
+: when the CLASS_NOINLET option is in use \, GF inlet numbers don't
+match Pd inlet numbers \, the left inlet will be numbered 1 instead
+of 0 \, and inlet 0 will be invisible. GF currently only uses this
+for [#from~] \, but may come to use it for [shunt] \, [route2] \, [route3]
+and some more.;
 #X text 86 176 is not part of GF;
 #X text 65 30 has two grid methods;
 #X msg 16 51 symbol #pack;
-#X text 96 51 has variable number of inlets;
 #X msg 22 71 symbol cv/#Ellipse;
 #X text 139 70 has many methods;
 #X msg 27 91 symbol gf/gl;
@@ -59,37 +56,66 @@
 #X text 117 105 is weird because GF's framework doesn't support ~ inlets
 directly;
 #X msg 37 132 ...;
-#X obj 97 430 doc_m o0 attr;
-#X text 232 430 indicates that \$1 is a valid argument to the get-method
+#X obj 97 456 doc_m o0 attr;
+#X text 232 456 indicates that \$1 is a valid argument to the get-method
 \, and that the get-method will output something named like that when
 called without arguments.;
-#X text 232 478 some attributes are special in some ways that make
+#X text 232 504 some attributes are special in some ways that make
 them hidden from that list but still supported by 'get'. this coïncides
 with when 'get' exceptionally appears in the list of methods.;
-#X text 232 923 methods of superclasses are not listed. those are rare
-in GF. this mostly just means that 'get' is not listed \, because it
-is common to all classes. ('help' was also a common method like that
-\, but it was removed in 9.11). it can happen that 'get' is listed
+#X text 232 1110 methods of superclasses are not listed. those are
+rare in GF. this mostly just means that 'get' is not listed \, because
+it is common to all classes. ('help' was also a common method like
+that \, but it was removed in 9.11). it can happen that 'get' is listed
 \, when the 'get' of a class has any special cases in it.;
+#X text 232 408 if class or alias is not found in GridFlow's class
+database. this only covers the C++/source_filter.rb interface \, and
+NOT the abstractions.;
+#X text 96 51 has variable number of inlets (and doesn't say it);
+#X obj 97 565 doc_m o0 inlets;
+#X obj 97 1197 doc_m o0 outlets;
+#X text 232 565 number of inlets of objects of that class. if the class
+has variable number of inlets \, this is the "initial" number of inlets
+\, which normally means the minimum possible number of inlets \, even
+though that case may not be the most useful nor the default.;
+#X text 232 1197 number of outlets of objects of that class. if the
+class has variable number of outlets \, this is the "initial" number
+of outlets \, which normally means the minimum possible number of outlets
+\, even though that case may not be the most useful nor the default.
+;
+#X text 232 639 if there CLASS_NOINLET \, GF's inlet 0 will not be
+visible in Pd \, therefore this number will be one more than reported.
+Furthermore \, signal inlets will never be reported because they are
+not supported by GF's C++ interface. Anything created using inlet_new
+will not be reported (but this only happens in [#from~] at the moment)
+;
+#X text 232 1271 signal outlets will never be reported because they
+are not supported by GF's C++ interface. Anything created using outlet_new
+will not be reported (but this only happens in [#to~] at the moment)
+;
 #X connect 1 1 3 0;
-#X connect 9 1 35 0;
-#X connect 10 1 17 0;
+#X connect 9 1 33 0;
+#X connect 10 1 41 0;
 #X connect 11 0 14 0;
 #X connect 12 0 11 0;
 #X connect 13 0 11 0;
 #X connect 16 0 15 0;
-#X connect 18 1 19 0;
-#X connect 18 1 25 0;
-#X connect 18 1 20 0;
-#X connect 18 1 21 0;
-#X connect 18 1 22 0;
-#X connect 18 1 23 0;
-#X connect 18 1 24 0;
-#X connect 18 1 26 0;
-#X connect 18 1 42 0;
+#X connect 17 1 18 0;
+#X connect 17 1 24 0;
+#X connect 17 1 19 0;
+#X connect 17 1 20 0;
+#X connect 17 1 21 0;
+#X connect 17 1 22 0;
+#X connect 17 1 23 0;
+#X connect 17 1 25 0;
+#X connect 17 1 40 0;
+#X connect 28 0 11 0;
 #X connect 29 0 11 0;
 #X connect 31 0 11 0;
-#X connect 33 0 11 0;
-#X connect 36 0 11 0;
-#X connect 39 1 40 0;
-#X connect 39 1 41 0;
+#X connect 34 0 11 0;
+#X connect 37 1 38 0;
+#X connect 37 1 39 0;
+#X connect 43 1 45 0;
+#X connect 43 1 47 0;
+#X connect 44 1 46 0;
+#X connect 44 1 48 0;

Modified: trunk/src/classes2.cxx
==============================================================================
--- trunk/src/classes2.cxx (original)
+++ trunk/src/classes2.cxx Sun Aug 15 13:53:49 2010
@@ -1179,10 +1179,11 @@
 	\decl 0 symbol (t_symbol *s) {
 		if (fclasses.find(s)==fclasses.end()) {out[0](); return;}
 		FClass *c = fclasses[s];
+		{t_atom2 a[] = {c->ninlets }; out[0](gensym("inlets" ),1,a);}
+		{t_atom2 a[] = {c->noutlets}; out[0](gensym("outlets"),1,a);}
 		foreach(m,c->methods) {t_atom2 a[] = {m->first.first,m->first.second}; out[0](gensym("method"),2,a);}
 		foreach(m,c->attrs)   {t_atom2 a[] = {m->first                      }; out[0](gensym("attr"  ),1,a);}
-		//t_class *qlass = c->bfclass;
-		
+		//t_class *qlass = c->bfclass;	
 	}
 };
 \end class {install("gf/class_info",1,1);}



More information about the Gridflow-cvs mailing list