General question about granular synthesis

I’m trying to roll my own version of a granular synthesizer and after having read various differents aproaches and code I have still some important doubts about grain arrange/rendering.

Afaik most synth’s grain density parameter refer to the number of grains rendered, but some use it as “grains played at once” whereas others use it as “grains placed in the buffer” (does the first correspond with synchronous granular synthesis, and the latter with asynchronous one?). For instance with this latter version, with only 1-2 grains you hear a rythmic sound that goes on and off and that becomes filled and texture-like sounding the more grains you play since the grains fill the whole buffer to say something. But what happens when you fill the whole buffer, the extra grains are added to the already sounding ones or the all grain lenght shortens to let the extra grains fit in?

I think it must be an easy concept but I can’t seem to get it.

In my granulator, I have a “grain rate” parameter which determines how many grains will start within a second. There is a separate concept of “voices”. More voices will be used as the rate and length of the grains increases. (However, this has been a bit problematic once I started thinking about MIDI note control, as that requires another voices concept on top, to divide note polyphony…)

Then I guess your “grain rate” is a bit like the “interonset times: the time between the onset of successive grains” Ross Bencina describes in his famous paper about real time granular synth, that distributes the grains across the output, taking the aproach of Granulab.
By the first voices concept you mention, you mean strictly implementing them JUCE-alike (hence the double layer of voices problem) or just consider a 2nd voice like a 2n layer on top with the remaining grains to be played?

I am working with my legacy code, so the Juce synthesiser classes like SynthesiserVoice are not (yet) used.

Okay thanks for the clarification, gonna try to get it done and see how well it works since the grain and envelope parts are kinda easy.