Granular patch won't calculate total number of voices in the poly~

    May 25 2013 | 9:01 am
    Recently, I've been trying to reverse engineer the sugarsynth implementation of granular synthesis and I've basically cloned it outright with only one or two minor changes, yet I'm having a problem I can't figure out. In the sugarsynth's [x_sugar~] patch for the [poly~] object, it uses a few number boxes and a send receive pair in conjunction with[thispoly~] & [peak] to calculate how many voices there are and then equally scale the phase of each instance's phasor object.
    As far as I can tell I've copied this part of the patch near identically, yet no matter how many voices the peak object is out putting a 1. I can't tell why this is. Can anyone help me trouble shoot? Sorry in advance for my rainbow eyesore style of commenting, but it helps me to analyse each part of the patch and separate them visually.
    I also have one related and one unrelated question: How do I change my profile image? What is the reasoning behind the amplitude scaling at the end of the patch? It's the total voices to the power of a half and then multiplied by the square root of 2. I don't understand the significance of these choices.

    • May 26 2013 | 11:17 am
      I had a quick glance - try removing the #0 from your send/receive. You want the total number of voices, so peak must receive a voice number from every instance.
      I used gravatar for my "klaatu" profile image; as for the amplitude scaling, erm. I just scale my output by 1/totalVoices.
    • May 26 2013 | 11:25 am
      sugarsynth is cool! Have you tried "grainstretch" by Timo Rozendal? Very tasty indeed.
    • May 26 2013 | 11:32 am
      Thanks for the advice! I managed to figure it out last night, when I was opening each instance and it suddenly hit me that the send/receives were all different. Bit of a bummer though, I had wanted to be able to run more than one at a time using different buffers and voice numbers but now the voice number has to be the same on each instance.
      I had looked at grainstretch before and it sound super nice. I wanted to build something from the ground up though cause I wanted to handle pitch modulation a bit differently to most granular synth engines. No internal randomness, but sending signal rate arpeggios in so that I can get a chord out of one granular synth.
    • May 26 2013 | 12:16 pm
      btw, recently iw antd to do a grnaulator kinda similar of this, but using gen~,  and having phasor inside gen (for numerous reasons). The problems was that then, i could not initialise the phase of the phasor inside gen~, cause the gen phasor operator has no phase inlet... does anyone have a solution for this ?
    • May 26 2013 | 12:54 pm
      use [accum] in gen~ instead?
    • May 26 2013 | 12:56 pm
      Hi vichug
      can you simply add [+ 0.5]  ->  [% 1] to your phasor in gen?
    • May 26 2013 | 11:26 pm
      Hey, thanks, both solutions would work it seems. For some reasons i thought it could not be as simple as that ! but the output of a phasor~ is indeed completely equal to its current phase...
    • Jun 01 2013 | 12:53 am
      Thanks to the [+ 0.5]  ->  [% 1], :) here is a little granular resynthesis patch that i partially made for school exercise. So we did the basics with our teacher M. Tadini, then i thought i should all translate into the gen~ domain for a reason that seemed obvious at the time (maybe it was impossible to simply make random variations of grain size without clicks with this method in a non-gen domain, because of synchronization between the max and msp domains, maybe it could have been solved outise of gen~ more easily, who knows), also ideas taken from the Nobuyasu Sakonda's sugarSynth. It comes with annotations in a subtle mix between french and english (sorry, don't have time to translate correctly right now, but i guess most of things should be not too hard to understand) and no documentation at all, and patching style is a subtle mix between chaotic and very tedious, so i don't know if someone at all can try to use what's inside wihtout headache. Nothing too exotic though, apart from those KEY FEATURES ! :
      *grain engine in gen~ domain
      *stretch, pitch, random at will, without quirks, using sah~ -like technic
      *chord transposition
      *a cool fx that is due to previous mistake.
      it's all a matter of subtle mix.
    • Jun 01 2013 | 12:53 am
      i forgot the patch
    • Jun 01 2013 | 12:54 am