howdy, can you code an object that prevents a secondary audio inlet from accepting float?
maybe this relates to a different question already posted here, where we needed an object with a float method for a secondary audio inlet, by the way, we just hit a wall there and got nowhere.
The suggestion was to use a "proxy inlet" - but if the right/proxy inlet has a signal input it overrides the other declared methods. Declaring the proxy inlet as a non signal inlet would make it allow the new methods, but it wouldn't be a signal inlet... maybe something was done wrong? With this idea working, guess it's easy to create a float method just to filter out float input and print an error.
cheers
On 05/17/2016 04:04 PM, Alexandre Torres Porres wrote:
The suggestion was to use a "proxy inlet" - but if the right/proxy inlet has a signal input it overrides the other declared methods.
it only does when using the CLASS_MAINSIGNALIN() to declare a class as accepting signals. when using class_addmethod("dsp"), you can differentiate between signals and floats.
fgmards IOhannes
2016-05-17 11:16 GMT-03:00 IOhannes m zmölnig zmoelnig@iem.at:
it only does when using the CLASS_MAINSIGNALIN() to declare a class as accepting signals. when using class_addmethod("dsp"), you can differentiate between signals and floats.
sure, but this is for the main inlet, in the 2nd inlet this happens automatically, right?
but do you mean you can do this with a proxy inlet, given the right declaration of classes? Coz I wasn't doing that, Derek was, so i copied him in the thread.
cheers
well, in regards to the proxy inlet with both signal and float input, still no dice.
I've tried myself now the codes, and tried all options, using CLASS_MAINSIGNALIN or class_domainsignalin, or just ""class_addmethod(proxy_class, nullfn, gensym("signal"), 0);"
The only thing accomplished is that the float input is filtered out, but no method for it is happening.
So, questions: A) is this the only way to filter out floats from a second signal inlet???
B) it possible to get a float (and other) method(s) from the second signal inlet?
attached, the code, a test patch and a compiled object for mac
thanks
2016-05-17 11:53 GMT-03:00 Alexandre Torres Porres porres@gmail.com:
2016-05-17 11:16 GMT-03:00 IOhannes m zmölnig zmoelnig@iem.at:
it only does when using the CLASS_MAINSIGNALIN() to declare a class as accepting signals. when using class_addmethod("dsp"), you can differentiate between signals and floats.
sure, but this is for the main inlet, in the 2nd inlet this happens automatically, right?
but do you mean you can do this with a proxy inlet, given the right declaration of classes? Coz I wasn't doing that, Derek was, so i copied him in the thread.
cheers