I'm trying to generate objects within a subpatch using [obj( messages, and I want those generated objects to have $0 as one of their arguments, e.g. [myobject $0]. Using [obj x y myobject $0( gives [myobject 0] (I know $0 is not for messages, just thought I'd give that a try), and of course [list append $0] to the object message just adds the interpreted $0 of the parent patch. I'd like to preserve the "$0". Anyone know of a way to do it?
Yes. Either use [f $0], or a [makefilename %s-%s] or [makesymbol %s-%s] with a [f $0] as argument. I think that [makesymbol] is supposed to be deprecated, but I prefer its behaviour to the one of [makefilename], and its name is clearer.
Hallo, Alexandre Quessy hat gesagt: // Alexandre Quessy wrote:
Yes. Either use [f $0], or a [makefilename %s-%s] or [makesymbol %s-%s] with a [f $0] as argument. I think that [makesymbol] is supposed to be deprecated, but I prefer its behaviour to the one of [makefilename], and its name is clearer.
makesymbol is an external in zexy and will not be available on plain Pd without zexy.
Frank Barknecht _ ______footils.org_ __goto10.org__
On Wed, Feb 07, 2007 at 07:54:40PM -0700, Luke Iannini (pd) wrote:
I'm trying to generate objects within a subpatch using [obj( messages, and I want those generated objects to have $0 as one of their arguments, e.g. [myobject $0]. Using [obj x y myobject $0( gives [myobject 0] (I know $0 is not for messages, just thought I'd give that a try), and of course [list append $0] to the object message just adds the interpreted $0 of the parent patch. I'd like to preserve the "$0". Anyone know of a way to do it?
Hi,
I think the attached patch demonstrates what you mean.
Best,
Chris.
chris@mccormick.cx http://mccormick.cx
Hm... I'm not sure if your patch was supposed to "work" or demonstrate my issue, Chris... thanks for making it regardless : ).
Alexandre, not sure what you're suggesting either since [f $0] would output the "value" of $0 rather than the actual characters "$0", which is what I'm after.
Either way,Chris's patch has lead me to the solution, which is:
[symbol $( | [makefilename %s0] | [; pd-mySubpatch obj 10 10 myObject $1(
Thanks to both of yas! Should probably add this to puredata.org or something for posterity. Or a bug report since it's obviously a kludge.
On 2/7/07, Chris McCormick chris@mccormick.cx wrote:
On Wed, Feb 07, 2007 at 07:54:40PM -0700, Luke Iannini (pd) wrote:
I'm trying to generate objects within a subpatch using [obj( messages, and I want those generated objects to have $0 as one of their arguments, e.g. [myobject $0]. Using [obj x y myobject $0( gives [myobject 0] (I know $0 is not for messages, just thought I'd give that a try), and of course [list append $0] to the object message just adds the interpreted $0 of the parent patch. I'd like to preserve the "$0". Anyone know of a way to do it?
Hi,
I think the attached patch demonstrates what you mean.
Best,
Chris.
chris@mccormick.cx http://mccormick.cx
On Thu, Feb 08, 2007 at 12:16:02AM -0700, Luke Iannini (pd) wrote:
Hm... I'm not sure if your patch was supposed to "work" or demonstrate my issue, Chris... thanks for making it regardless : ).
It was supposed to solve your problem.
Thanks to both of yas! Should probably add this to puredata.org or something for posterity. Or a bug report since it's obviously a kludge.
If you consider it a kludge, then most of Pd is a kludge. ;)
I don't think it's that bad, or at least no worse than any of the other dynamic patching stuff. Maybe slightly better would be a character escaping mechanism like [$0(
Best,
Chris.
chris@mccormick.cx http://mccormick.cx
Hahaha : ).
It was generating odd messages here, like [test $-7614554]. But I'm on an intel mac using Pd-Extended autobuilds, so that's probably normal.
Yes, I think a character escaping mechanism would be a good thing, though of course escaping is already used in the pd-fileformat so who knows what madness it would require.
Thanks again!
On 2/8/07, Chris McCormick chris@mccormick.cx wrote:
On Thu, Feb 08, 2007 at 12:16:02AM -0700, Luke Iannini (pd) wrote:
Hm... I'm not sure if your patch was supposed to "work" or demonstrate my issue, Chris... thanks for making it regardless : ).
It was supposed to solve your problem.
Thanks to both of yas! Should probably add this to puredata.org or something for posterity. Or a bug report since it's obviously a kludge.
If you consider it a kludge, then most of Pd is a kludge. ;)
I don't think it's that bad, or at least no worse than any of the other dynamic patching stuff. Maybe slightly better would be a character escaping mechanism like [$0(
Best,
Chris.
chris@mccormick.cx http://mccormick.cx
Luke Iannini (pd) a écrit :
Hm... I'm not sure if your patch was supposed to "work" or demonstrate my issue, Chris... thanks for making it regardless : ).
Alexandre, not sure what you're suggesting either since [f $0] would output the "value" of $0 rather than the actual characters "$0"
hello, there something I don't understand, why do you absolutely want to get the characters "$0" when it's for 'dynamic patching' at the moment the $0 value is for the current instance of a patch, the target subpatch only need the $0 value, and it doesn't matter if it's the value or the characters, unless this dynamical patching is for building subpatches that will be saved into the current patch, so I don't understand why building dynamically subpatches in patches that will be saved in the current state. Usually, dynamical patching is usefull for attributing provisional states into a patch. Is there another way to use dynamic patching?
___________________________________________________________________________ Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire. http://fr.mail.yahoo.com
hi luke
On Thu, 2007-02-08 at 00:16 -0700, Luke Iannini (pd) wrote:
Thanks to both of yas! Should probably add this to puredata.org or something for posterity. Or a bug report since it's obviously a kludge.
a kludge? why?
anyway, why do you want to have a litteral '$0' in the abstraction argument and not the value, that it represents, since it is actually the same? if i am not totally mistaken, this would only make sense, when you plan to save the patch with all the dynamically generated stuff, whereas saving dynamically generated stuff does not make sense at all, as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
roman
On 2/7/07, Chris McCormick chris@mccormick.cx wrote:
On Wed, Feb 07, 2007 at 07:54:40PM -0700, Luke Iannini (pd) wrote:
I'm trying to generate objects within a subpatch using [obj( messages, and I want those generated objects to have $0 as one of their arguments, e.g. [myobject $0]. Using [obj x y myobject $0( gives [myobject 0] (I know $0 is not for messages, just thought I'd give that a try), and of course [list append $0] to the object message just adds the interpreted $0 of the parent patch. I'd like to preserve the "$0". Anyone know of a way to do it?
Hi,
I think the attached patch demonstrates what you mean.
Best,
Chris.
chris@mccormick.cx http://mccormick.cx
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
Roman Haefeli a écrit :
hi luke
On Thu, 2007-02-08 at 00:16 -0700, Luke Iannini (pd) wrote:
Thanks to both of yas! Should probably add this to puredata.org or something for posterity. Or a bug report since it's obviously a kludge.
a kludge? why?
anyway, why do you want to have a litteral '$0' in the abstraction argument and not the value,
...snip ...
great minds think alike :)
___________________________________________________________________________ Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire. http://fr.mail.yahoo.com
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
anyway, why do you want to have a litteral '$0' in the abstraction argument and not the value, that it represents, since it is actually the same? if i am not totally mistaken, this would only make sense, when you plan to save the patch with all the dynamically generated stuff, whereas saving dynamically generated stuff does not make sense at all, as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
Frank Barknecht _ ______footils.org_ __goto10.org__
On Thu, 2007-02-08 at 13:35 +0100, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
anyway, why do you want to have a litteral '$0' in the abstraction argument and not the value, that it represents, since it is actually the same? if i am not totally mistaken, this would only make sense, when you plan to save the patch with all the dynamically generated stuff, whereas saving dynamically generated stuff does not make sense at all, as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
that's why i am mentioning it, though i've never patched like that yet and i wonder, if this is, what luke is doing.
roman
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
On 08/02/2007, at 13.35, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
[...] as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
In terms of state-saving?
On Thu, 2007-02-08 at 14:21 +0100, Steffen wrote:
On 08/02/2007, at 13.35, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
[...] as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
In terms of state-saving?
normally state saving is used to set variable controllers of a 'hardwired' patch/synth/hardware to a specific state, without changing the patch/synth/hardware itself. that is why i'd say, that when a dynamically created patch (more accurate: a patch, that contains dynamically created parts) is saved, this shouldn't be considered as a state-saving mechanism.
what frank and i have been talking about, is rather that dynamic creation could also be used to speed up patching progress, so that dynamic creation is used as long the patch is not finished and when the patch is finished, no dynamic creation is involved anymore. such a scenario would require the ability to create abstractions with litteral '$0's as arguments dynamically.
roman
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de
On 08/02/2007, at 14.45, Roman Haefeli wrote:
On Thu, 2007-02-08 at 14:21 +0100, Steffen wrote:
On 08/02/2007, at 13.35, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
[...] as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
In terms of state-saving?
normally state saving is used to set variable controllers of a 'hardwired' patch/synth/hardware to a specific state, without changing the patch/synth/hardware itself. that is why i'd say, that when a dynamically created patch (more accurate: a patch, that contains dynamically created parts) is saved, this shouldn't be considered as a state-saving mechanism.
what frank and i have been talking about, is rather that dynamic creation could also be used to speed up patching progress, so that dynamic creation is used as long the patch is not finished and when
the patch is finished, no dynamic creation is involved anymore. such a scenario would require the ability to create abstractions with
litteral '$0's as arguments dynamically.
The later part i understand. But i was thinking that some clever
algorithmic scoring could use dynamical patching in which case the
saving of the patch - with the dynamically crated parts - would be
state saving of the score. I might be out deep, as I'm not sure it
makes sense in Pd.
Yes, you are correct that I was using it to speed normal patching, in this case I was generating patch-matrix toggle elements in a grid that communicated with a matrix object via $0 (the details of that are discussed in a previous thread of mine). I was cut-and-pasting them to other patches, so the interpreted $0 was not useful to me. Typically, I ended up circumventing the issue while waiting for a response, but I can still see the use of this. I think it's perhaps more apparent in generating $1-$n as arguments.
I say it is a kludge because makefilename is essentially a wrapper, and moving things to be more pd-like consistently reduces kludginess. Just like the ability of 0.40 to use dollar-args anywhere within a symbol rather than just at the beginning, and the re-assignability of [send]; both reduce countless "kludges" of [list2symbol] or [makefilename]... perhaps it was "pd-like" to have 8 objects creating a single dynamic send but I prefer the... new pd-likeness : ) (though it's a few months before I'll be using it).
Luke
On 2/8/07, Roman Haefeli reduzierer@yahoo.de wrote:
On Thu, 2007-02-08 at 14:21 +0100, Steffen wrote:
On 08/02/2007, at 13.35, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
[...] as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
In terms of state-saving?
normally state saving is used to set variable controllers of a 'hardwired' patch/synth/hardware to a specific state, without changing the patch/synth/hardware itself. that is why i'd say, that when a dynamically created patch (more accurate: a patch, that contains dynamically created parts) is saved, this shouldn't be considered as a state-saving mechanism.
what frank and i have been talking about, is rather that dynamic creation could also be used to speed up patching progress, so that dynamic creation is used as long the patch is not finished and when the patch is finished, no dynamic creation is involved anymore. such a scenario would require the ability to create abstractions with litteral '$0's as arguments dynamically.
roman
Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
this thread is brought to you by the letter [$0] and the word [kludge]
(i promise no more jokes for the next few weeks. my pd tracker is starting to make sounds, so i have some drumloops to cut.)
On Fri, 2007-02-09 at 02:12 +0900, hard off wrote:
this thread is brought to you by the letter [$0] and the word [kludge]
(i promise no more jokes for the next few weeks. my pd tracker is starting to make sounds, so i have some drumloops to cut.)
i am very ok with your jokes :-)
btw, i sometimes read in this list about the projects you're working on, e.g. something like a filter-shaper based synth and now you are talking about a tracker. it would be nice, if these projects would find their way also into netpd. i hope there will be more happen in netpd in the next days (at least i will have more time again).
cheers roman
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de
Hallo, Steffen hat gesagt: // Steffen wrote:
On 08/02/2007, at 13.35, Frank Barknecht wrote:
Hallo, Roman Haefeli hat gesagt: // Roman Haefeli wrote:
[...] as far as i can see it. the only case i could think of, that would require litteral '$0's as abstraction arguments, would be, if you would use dynamic patching just as a quicker way of patching.
... which actually is a very sensible usecase!
In terms of state-saving?
Yes, for example.
I was using CVS/abstractions/rradical/control/commun-builder.pd to build a lot of RRADical's [commun /s? $0] objects to control 32 sliders in a step sequencer.
However at that time I didn't implement the solution Chris suggested, instead I just used "dollar0-" as a dummy and changed that to "$0-" with a text editor later.
Frank Barknecht _ ______footils.org_ __goto10.org__