[PD-dev] getting the classname in an class
Hans-Christoph Steiner
hans at eds.org
Sun Oct 28 23:45:48 CET 2007
On Oct 26, 2007, at 3:38 PM, IOhannes m zmoelnig wrote:
> Hans-Christoph Steiner wrote:
>> On Oct 26, 2007, at 2:13 PM, Martin Peach wrote:
>>
>> Any specific suggestions? You mean casting as (entry_class) or
>> something like that?
>
> you have to copy the struct definitions from whereever to your file.
> look at "iem/iemguts/src/saveargs.c"
>
> fmasdr
> IOhannes
I tried this in entry_new() and entry_save(), and in both, "binbuf"
ends being nothing useful (i.e. segfault):
t_glist *glist = (t_glist *) canvas_getcurrent();
t_canvas *canvas = (t_canvas*) glist_getcanvas(glist);
t_binbuf *binbuf = canvas->gl_obj.te_binbuf;
t_atom *ap = binbuf_getvec(binbuf);
t_symbol *classname = atom_getsymbol(ap);
What's going on here? Am I doing something wrong?
.hc
------------------------------------------------------------------------
----
Looking at things from a more basic level, you can come up with a
more direct solution... It may sound small in theory, but it in
practice, it can change entire economies. - Amy Smith
More information about the Pd-dev
mailing list