Should I use poly~, polybuffer~, or just copy and paste?!

    Apr 15 2012 | 1:38 pm
    I'm attempting to work with sampling and sequencing but I've run into a bit of trouble with it. My problem is that I need several individual buffers, waveforms, and other items, each with different names (buffer~ test, buffer~ testtwo, for example). I will probably need over 100 of these to start off with.
    I'm thinking of using the poly~ object but I'm not sure if it will work for me. If I create a poly~ with over 100 instances, is there an easy way to rename each individual buffer? Should I send a target message to each instance of poly with the message [name example_buffer_one] for example?
    This will also be the case when coming out of the poly~. I will need to have each external (by external, I mean not inside poly) waveform~ receive the [set/name] message which corresponds with the selected buffer~ from inside poly~.
    There are other problems but I'll try to tackle this one for now!
    I understand how poly~ works but I've never dealt with it outside the realm of polyphonic synthesis and midi.
    Can someone help me please?
    : )

    • Apr 15 2012 | 3:00 pm
      polybuffer~ and poly~ work great together. Just use thispatcher~, make him send its instance number, and as each of your polybuffer's buffer have a name which is constituted with : [nameofyoupolybuffer].[indexofoneparticularbufferinsidethepolybuffer] you just have to use a sprintf to format the name of each buffer, and the number index is the only thing that needs to be changed, adn how convenient ! that's something you can have easily with the instance index coming from thispatcher~. it's like they were designed to work together :) As for your outs : do you want each instance send its signal to a particular waveform~, at the same time ? In this case, you can use send~ form inside your poly, and set message, which can be depending of the instance as explained above. if you don't need this, but rather one instance selected at a time, it's not that complicated : you just need to save "set [thisinstancebuffername]" message inside the poly, and output it when it's selected, and send it to your waveform~. Alternatively you could have a waveform inside each poly instance, maybe computer expensive. And if the overall process is too expensive, you can mute each unused instance of poly with thispatcher~.
    • Apr 15 2012 | 6:06 pm
      Great. Thanks for the tip! I've been working on this and I have made a lot of progress! And I shall be displaying each waveform~ separately! So that makes things easier too.
      : )
      I have another question though...
      I am also using [sprintf], [mousestate], and [thispatcher] (plus many more objects) combined to report the position of ubuttons on my home patch. The only problem is, I need a 'polyphonic' way of working with this too.
      For example, when I drag a specific textbutton over a specific ubutton which is in a certain place (let's say patching rectangle 0. 585. 45. 45.) I get a bang once I release the mouse, which consequently loads a waveform, etc, etc.
      How can I do this in polyphony? Because each ubutton is in a different location, is this impossible (or incredibly complicated)?
      Without using 100s of [split] and/or [if] objects...
      It's driving me insane!
      Thanks again!
    • Apr 16 2012 | 5:38 pm
      Anyone? : /
      I'm going mad!
    • Apr 17 2012 | 5:34 pm
      I guess [copy and paste] it is!
    • Apr 17 2012 | 5:36 pm
      i don't really see what you want to do, but maybe using [hover] with script-named objects will help you ?
    • Apr 17 2012 | 6:20 pm
      Sorry. Maybe I wasn't clear enough.
      For example, I have 100 ubuttons, each in different locations on my patch. When I scroll the mouse over each one, something happens... something unique to each ubutton. I am using mousestate, hover, etc. etc. to make something happen each time I hover over the specific ubuttons.
      Here's the problem:
      Instead of saying (for example) if mouse is over ubutton 1, do this, and if mouse is over ubutton 2, do something else, etc., etc., can I use poly~ in any way to help me avoid the monotony of copy and pasting, ultimately requiring less processing power too.
      Even if I do use scripting names, won't I still have to create an independent [if] statement for each ubutton?
      Maybe I'm wrong!
      Thanks for listening!
      : )
    • Apr 18 2012 | 5:45 pm
      bpatcher perhaps?
    • Apr 18 2012 | 7:26 pm
      Thanks for your help, but I think Javascript/scripting, etc. is what I'm looking for.
      It's time to refresh my JS skills!
      : )