[PD-cvs] pd/src builtins.c,1.1.2.62,1.1.2.63
chunlee
chunlee at users.sourceforge.net
Sun Aug 19 09:28:21 CEST 2007
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22194
Modified Files:
Tag: desiredata
builtins.c
Log Message:
display
Index: builtins.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/builtins.c,v
retrieving revision 1.1.2.62
retrieving revision 1.1.2.63
diff -C2 -d -r1.1.2.62 -r1.1.2.63
*** builtins.c 17 Aug 2007 04:44:33 -0000 1.1.2.62
--- builtins.c 19 Aug 2007 07:28:19 -0000 1.1.2.63
***************
*** 1041,1044 ****
--- 1041,1066 ----
}
+ /*---- Display ----*/
+ static t_class *display_class;
+ struct t_display : t_object {
+ };
+
+ static void *display_new(t_symbol *s) {
+ t_display *x = (t_display *)pd_new(display_class);
+ return x;
+ }
+
+ static void display_send(t_display *x, t_symbol *s, int argc, t_atom *argv) {
+ std::ostringstream t;
+ t << s->name;
+ for (int i=0; i<argc; i++) {t << " " << &argv[i];}
+ sys_mgui(x, "dis", "S", t.str().data());
+ }
+ static void display_setup() {
+ t_class *c = display_class = class_new2("display",display_new,0,sizeof(t_display),0,"S");
+ class_addanything(c, display_send);
+ }
+
+
/* MSW and OSX don't appear to have single-precision ANSI math */
#if defined(MSW) || defined(__APPLE__)
***************
*** 2925,2928 ****
--- 2947,2951 ----
print_setup();
macro_setup();
+ display_setup();
clipboard_setup();
delay_setup();
More information about the Pd-cvs
mailing list