From reading some of the docs, I got the impression that it is NOT
possible to have any subsequent inlets allow for list input? Is this correct? Do you know why this is? I have some ideas that I would like to implement with lists on the second and third inlets...
Thanks,
Mike
On Mon, 12 Nov 2007, Mike McGonagle wrote:
From reading some of the docs, I got the impression that it is NOT possible to have any subsequent inlets allow for list input? Is this correct? Do you know why this is? I have some ideas that I would like to implement with lists on the second and third inlets...
You need to make "proxy inlets", which use extra objects that are t_pd but not t_gobj (there's no interdiction, but there's no point). Those objects are not considered as part of the patch, as each of them is hidden behind the inlet that it represents. Those objects normally keep a pointer to the master object, which owns the first inlet. If you want all inlets to behave the same, you can avoid some duplication by using CLASS_NOINLET.
If you think you can, or you think you can't, you are probably right. ?Mark Twain
I think it would be appropriate to limit yourself to one quote per email.
_ _ __ ___ _____ ________ _____________ _____________________ ... | Mathieu Bouchard - tél:+1.514.383.3801, Montréal QC Canada
Mike McGonagle wrote:
From reading some of the docs, I got the impression that it is NOT possible to have any subsequent inlets allow for list input?
there is no such limit for a list in the strict sense. things are different with arbitrary messages, but would you want to do such a thing?
fgmasdr. IOhannes
Mike McGonagle schrieb:
From reading some of the docs, I got the impression that it is NOT
possible to have any subsequent inlets allow for list input? Is this correct? Do you know why this is? I have some ideas that I would like to implement with lists on the second and third inlets...
You could use flext where this is automatically dealt with.
gr~~~
On Mon, 12 Nov 2007 13:50:17 -0600 "Mike McGonagle" mjmogo@gmail.com wrote:
From reading some of the docs, I got the impression that it is NOT possible to have any subsequent inlets allow for list input? Is this correct? Do you know why this is? I have some ideas that I would like to implement with lists on the second and third inlets...
Because of the distribution behaviour? A param list {p1, p2, p3} on the leftmost gets distributed over inlets {i1, i2, i3}. If you sent a list to i2 then how would it map? p1->i2, p2->i3... No doubt you could make your object treat lists as you like, but it would have to break this established behaviour I guess.
Thanks,
Mike
-- Help the Environment, Plant a Bush back in Texas!
"I place economy among the first and most important republican virtues, and public debt as the greatest of the dangers to be feared. To preserve our independence, we must not let our rulers load us with perpetual debt." -- Thomas Jefferson, third US president, architect and author (1743-1826)
"Give Peace a Chance" -- John Lennon (9 October 1940 _ 8 December 1980)
Peace may sound simple_one beautiful word_ but it requires everything we have, every quality, every strength, every dream, every high ideal. _Yehudi Menuhin (1916_1999), musician
If you think you can, or you think you can't, you are probably right. _Mark Twain
"Art may imitate life, but life imitates TV." Ani DiFranco
PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
On Tue, 13 Nov 2007, Andy Farnell wrote:
Because of the distribution behaviour? A param list {p1, p2, p3} on the leftmost gets distributed over inlets {i1, i2, i3}. If you sent a list to i2 then how would it map? p1->i2, p2->i3... No doubt you could make your object treat lists as you like, but it would have to break this established behaviour I guess.
Not all built-in classes follow the protocol of distributing over inlets. [list] objects don't. By making [list] objects different than the others, pd becomes less consistent, but Pd's API is not designed to accept the new atom type that would allow distinguishing between a list of arguments and a list that works like an atom (which could distribute over inlets if there were two atomic lists passed in one argument list).
_ _ __ ___ _____ ________ _____________ _____________________ ... | Mathieu Bouchard - tél:+1.514.383.3801, Montréal QC Canada
Andy Farnell schrieb:
On Mon, 12 Nov 2007 13:50:17 -0600 "Mike McGonagle" mjmogo@gmail.com wrote:
From reading some of the docs, I got the impression that it is NOT possible to have any subsequent inlets allow for list input? Is this correct? Do you know why this is? I have some ideas that I would like to implement with lists on the second and third inlets...
You can do that too - look in example in the source of h_map.cpp in PDContainer ... (pd-cvs/externals/grh/PDContainer/src/h_map.cpp)
LG Georg