This is a simple granulator for Max for Live. It's very much inspired by Robert Henke's excellent granulator. In particular, the extra audio unit for grabbing source material. I've used the GMEM GMU granulator as the basis, as a relatively modern and fast granulation external.
To use it, you'll need Live 8.2.x, Max and Max for Live. Save the attached devices into your library - the Grabber is an Audio Effect, and the GrainPlayer is a Midi Instrument. When installed, you can play the GrainPlayer using a keyboard etc, and drop files on the waveform view, or grab audio by putting the Grabber on any audio track.
(this is the first m4l device I've shared, so it may not work perfectly out of the box!)
Comments welcome! Quick demo here - note it's just percussive sounds going in, so it's fairly harsh overall!
The main differences between mine and Henke's (to my mind) are:
- I have a lot of tempo based stuff - you can grab a set number of bars/beats (and quantize the grab start point), you can scan through the file in a set number of beats, and grains can be triggered on beats/notes. This makes it lots of fun for rhythmic stuff!
- my version uses an external, which should be more CPU friendly, but gives slightly less control (and less pretty pictures)
- my version allows for multiple audio grabbers, and keeps lists of those available. Also, mine starts grabbing when a button is pressed, rather than keeping track of a buffer of audio constantly (although I'll add this as an option in the future)
- Henke's sounds nicer out of the box, for at least two reasons: nice grain envelopes, and there's a slightly detuned stereo copy which adds a nice comb filtery metallic smoothness, particularly nice for textures.
- I don't have any: filters, FM modulation, envelope shaping.
- 29-05-2011 Fixed some trigger setting issues. Added grain size link. Fixed all instances starting in ON mode. Interface tweaks
How the grains are triggers. This can either be Free (which uses an oscillator with the given frequency), Random (as before, but doesn't always play), or Sync, where the start of grains is sync'd to Live, at the given note value (e.g. 4n is one per beat). Rand allows for randomisation of the phase of each instance (e.g. if several notes are played at once).
This is a simple ADSR envelope, applied to each note.
Select the region of the file to work with (used by the sweep) and the base start point within the file.
Randomise the position from which grains are taken, either for all instances at the same time, or on a per-note basis.
Scan through the file. With a short grain size, this can be used for vocoder/time strech style effects. Sync takes a set number of beats/bars to sweep through an amount of the selected region of the file. "Free" uses an LFO, which can be set either by Frequency, or by speed relative to the original speed of the audio.
Length of grains, randomisation of grain length (as a proportion of length) and gain applied (although I think it might only work up to 1). Also, selection of envelope, whether to loop round the buffer when playing grains (i.e. asking for a grain at the end of the file includes looped audio from the beginning), and a control to play forwards/backwards (which doesn't seem to work at the moment - the underlying granulator doesn't seem to do it).
Fundamental transpose, plus base note and scaling settings. Pitch Spray randomises the pitch of each grain, up to the given number of semitones.
Pan and "Distance". Distance should make the grains sound further away, and pan moves them around. They are dependent, and pan seems to only work with high distances. Both parameters have a spray, to randomise their effects per grain.
Grabbing Audio - this will get a list of all available grabbers to select from. You can then set either a time in seconds or beats/bars to grab, and choose whether the grab point is synchronised to bars/beats. This allows for fairly precise grabbing of exactly amounts of audio, which can then be played back in time before being mangled. The big red button starts grabbing, the bar below shows how close to finishing it is.