[PD] External with custom gui

Hans-Christoph Steiner hans at eds.org
Mon Jul 9 21:53:28 CEST 2007


Writing GUI objects is black magic, from what I have tried.  It would  
be great if you could document anything that you have discovered so  
far, I made a wiki page a while back for this:

http://puredata.org/docs/developer/PdAPI

Add and edit as much as you want.  It seems like it should have a  
page for each function really, but right now it's just a long list.

.hc


On Jun 30, 2007, at 8:53 PM, Carlos Pita wrote:

> Hi all,
>
> please anyone experienced with pd internals could give a quick look  
> to the attached external to help me get it working? There is a  
> makefile there and a simple test patch. The external is as simple  
> as it can be, having just a label and a border box. There is some  
> debugging stuff here and there, mainly calls to sys_vgui are  
> wrapped by the macro sys_vguid which prints the tk command to  
> stdout before delegating to sys_vgui. The object is initialized  
> fine, but the first command passed to tk hangs pd. Maybe I'm  
> missing some compilation flags (the makefile works fine for  
> externals without custom gui). To test it just change PD_INC in the  
> makefile to point to pd source directory and run make, this will  
> build the library and invoke pd passing it the test patch. I'm  
> compiling against pd-0.40-2. If you could give me some hint on pd  
> debugging or to point me to the error I would be very thankful.
>
> The debugging output I get is:
>
> carlos at monad:~/dev/sound/pd-ext$ make
> pd -lib ext test-ext.pd
> args accepted    <- arguments to the object are fine
> ext_draw           <- draw rutine is called (with  
> IEM_GUI_DRAW_MODE_NEW)
> ext_draw_new   <- draw_new rutine is called
> .x70b470.c create rectangle 59 101 69 111 -fill #fcfcfc - 
> tags .x70b470.c.base
>
> and here pd gets stuck.
>
> TIA
> Cheers,
> Carlos
>
> On 6/30/07, Frank Barknecht <fbar at footils.org> wrote:
> Hallo,
> Carlos Pita hat gesagt: // Carlos Pita wrote:
>
> > I've written a tiny external with a custom gui following g_canvas  
> and
> > g_bang. But I don't know how to create a new object of this  
> class. Should I
> > add a menu entry? How can I do this? Or can my object be created  
> without
> > adding menu entries and or shortcuts?
>
> Yes, by typing. It's also possible for inlcuded guis: Try objects
> named "bng", "tgl", "vsl" etc.
>
> Ciao
> --
> Frank Barknecht                 _ ______footils.org_ __goto10.org__
>
> _______________________________________________
> PD-list at iem.at mailing list
> UNSUBSCRIBE and account-management -> http://lists.puredata.info/ 
> listinfo/pd-list
>
> <pd-ext.tgz>
> _______________________________________________
> PD-list at iem.at mailing list
> UNSUBSCRIBE and account-management -> http://lists.puredata.info/ 
> listinfo/pd-list



------------------------------------------------------------------------ 
----

Computer science is no more related to the computer than astronomy is  
related to the telescope.      -Edsger Dykstra


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20070709/b656f2d1/attachment.htm>


More information about the Pd-list mailing list