R
-oscillator drum examples collectionHere's the larger drum sound collection for the R
oscillator. This is not exhaustive, but there's enough simple combinations of basic features to give it its own page.
You can use these examples freely; the public domain dedication for all scripts and rendered audio files on the main examples page also applies to this subpage.
R
There's several ways to use R
instances for drumming, but the main possibilities come from using it for modulation. In particular, using an Rxpe
PM modulator to make a carrier "beat" like a drum is a key ingredient in a range of simple recipes; apart from that modulator, the sound greatly depends on the choice of carrier. A more polished sound also usually depends on adding modulation of the amplitude to the carrier – for example using another R
instance.
Looking first at the Rxpe
PM modulator, intensity and pace of drumming can be constant or be psuedo-randomly varied, by tweaking its mode, frequecy, and amplitude. For a fixed-pace drumbeat, fixed cycle mode mf
or ternary smooth mode mt
can be used – otherwise it will be pseudo-random drumming, which can be given a variety of simple patterns (varying the brightness or intensity, the timing, or both). More variations are also possible by using several PM modulators with different settings for the same drum.
Technically, these drum sounds contain two different types of drum beat events which sound the same or similar. The PM modulator may rise (sharply at first), or it may fall (sharply at first) – and both will brighten the carrier's sound in the same way. If a W
wave oscillator is used as the carrier, with its frequency set to 0 Hz, it will sound the same – but with an R
oscillator as the carrier, it will normally sound a bit different, because R
is pseudo-periodic and each part of its signal makes for a somewhat different drum hit.
For a start, here's a simple drum script with named variables for quantities like bpm and for "strength" (intensity and brightness) of the drum sound. The carrier has a very low frequency, rather than a frequency of 0 Hz – this helps vary the sound a little over time, instead of making it alternate between the exact same back-and-forth beats all the time. Otherwise, the f$bpm/(60*2)
could be moved in to the modulator, with f0
added to the carrier. (A somewhat higher carrier frequency can also be used to produce a background hum or bassy noise which alternates with the drumbeats. For example, reusing the 'strength' variable, as in f$strength
.)
$bpm=240 $strength=100 Rlin f$bpm/120 p[ Rxpe mf a$strength*(120/$bpm) ] t30
It's a start, but without more it sounds a little rough in several ways. The subjective audio quality can be improved, among possibly other and much larger changes, by tweaking the carrier. Even then, without also adding amplitude modulation, such drum sounds have flat peak amplitude, the sense of intensity change coming from frequency change only – which usually sounds too soft or flat to be musically nice.
Below is a randomized version, with a little rumble in-between beats. Switching the R
modulator to its default uniform random function mode, on average drumbeats seem to come less often – because beat intensity is sometimes too low to sound like a beat. Going beyond compensating for that, the 'bpm' numbers are doubled below, the bpm always reflecting the maximum rate (disregarding any missing beats, which also vary between the randomness modes which can be used).
With this randomization, there's little gaps between the drum "hits" that stand out, adding to a weak or empty sound – but as one way to change that, below these gaps are filled using a background bassy noise, by setting a higher frequency for the carrier derived from the "strength" variable. (The modulator now has its frequency set directly, instead of implicitly based on that of the carrier.)
$bpm=480 $strength=100 Rlin mt f$strength/2 p[ Rxpe f$bpm/120 a$strength*(240/$bpm) ] t30
This version also sounds less grainy; this is improved by using the ternary smooth random (mt
) mode for the R
carrier. Otherwise this randomized version would sound more, rather than less, rough.
The more grainy-sounding default random mode for the carrier is possible without making it sound terribly grainy if choosing a very smooth line type – cos
– as in the below. The "strength" is boosted to compensate for the mellower sound of that line type. (More generally, moderate graininess is also possible by using the mt
mode with a shaping level for a cross between it and uniform randomness.)
$bpm=480 $strength=150 Rcos f$strength/3 p[ Rxpe mv f$bpm/120 a$strength*(240/$bpm) ] t30
Here the modulator also uses the basic violet random mode (by adding mv
) – a somewhat smoother drumming pattern (reducing occasional "gaps" from very-low intensity hits) based on violet noise, compared to the default uniform random mode (which is based on white noise). The underlying randomness used determines the pattern. (Differences are even larger between the binary, ternary smooth, and uniform variations of white noise random as underlying noise.)
Back to clean sounds, here's a sine-wave based chirp drum variation – too rudimentary a drum for use in a trance track, but thanks to the random pattern, not boring.
$bpm=480 $strength=100 Wsin f$strength/3 p[ Rxpe mv f$bpm/120 a$strength*(240/$bpm) ] t30
For a richer and messier, yet fairly gentle sound, here's a variation which uses a half-rectified sine (Whsi
) for the carrier, and makes the modulator follow a random pattern based on Gaussian white noise (mg
).
$bpm=480 $strength=75 Whsi f$strength/2 p1/12[ Rxpe mg f$bpm/120 a$strength*(240/$bpm) ] t30
Finally – for now – let's go for one of the most intense and noisy drum sounds R
can offer through a simple script. The line type sah
produces a squarish wave, and both the tempo and the strength have been cranked up; the carrier again uses mt
to keep the sound reasonably clear (as opposed to more distorted and crackly). The modulator uses the violet binary mode mvb
, and so shifts rapidly and chaotically between two paces (half and full) while keeping each beat equally strong.
$bpm=600 $strength=125 Rsah mt f$strength*(2/7) p[ Rxpe mvb f$bpm/120 a$strength*(240/$bpm) ] t30
Different and more numerous variations to the carrier can sound decent when also shaping the amplitude, as in the below.
With amplitude shaping, simple drum sounds without randomization can sound good to listen to. The various wave types available for the W
oscillator then make for interesting variations for the carrier. These sounds are more intense and use lower "strength" values to compensate, compared to those above. There's also less of a background rumble, as the amplitude shaping consists in sucking down the level in some way to create peaks.
The Rsqe
amplitude modulator below is used in a way that makes for a "ducking" sound similar to that from compression, for pairs of strong and weak beats – the second sub-beat fading in from a low amplitude – like in some prominent 1990s techno and trance. But the carrier's evenangle wave type is an unusual choice. (Music I've listened to has often had drums with the sound of sine or triangle waves.) Note that with these strong–weak beat pairs, the pace sounds like half the bpm technically used.
$bpm=120*2 $strength=20 Wean f$strength/3 p6/93[ Rxpe mf f$bpm/120 a$strength*(240/$bpm) ] a1/8.r1[ Rsqe mf f$bpm/120 ] t30
With such strong–weak beat pairs, it's often nice to vary the frequency used for each beat in the pair. This can be done by adding another inner modulator for the PM modulator that does the "beating", to vary its amplitude. Here's an example of a triangle wave-based drum, where the first sub-beat has a lower frequency than the second – the p1/2
phase offset of the new inner Rcos
modulator, if changed, moves the frequency top and bottom within each beat-pair. (Why a sinuous inner modulator? It's a smooth way to step between two values; a squarish jump wouldn't sound clean here.)
$bpm=120*2 $strength=30 Wtri f0 p[ Rxpe mf f$bpm/120 a$strength*(240/$bpm)/2.r$strength*(240/$bpm)[ Rcos mf p1/2 ] ] a1/8.r1[ Rsqe mf f$bpm/120 ] t30
Beyond this, for each choice of carrier, additional variation to color and brightness can be created e.g. by adding an extra LFO to tweak the carrier frequency value. A sawtooth LFO (as below) gives a straightforward effect that often sounds nice, though other wave types can create different effects.
For more "bright" or intense carrier waveform choices, the simply emulated compression "sound" can become a bit too much, a bit annoying – this can be avoided by either just reducing the AM depth, by making the main a
value closer to 1, or by setting the line type of the amplitude modulator to cub
instead. Compared to the sqe
line, cub
makes the level spend more time in the middle of the range instead of just going up and down.
Here's a script with those changes, using the medium-bright square root of sine wave type for the carrier – for a brighter, harder drum in-between triangle and square-based sounds – and at a higher pace. This script is good for a start in experimenting with simple drum patterns. The carrier wave type can also simply be changed and it'll sound pretty good for other types, too.
$bpm=150*2 $strength=30 Wsrs f0[ Wsaw f$bpm/240 a$strength*2 ] p[ Rxpe mf f$bpm/120 a$strength*(240/$bpm)/2.r$strength*(240/$bpm)[ Rcos mf p1/2 ] ] a1/8.r1[ Rcub mf f$bpm/120 ] t30
It's possible to change things up in more ways. Above, a sinuous transition was used to vary the frequency reached by beats, to set apart the low and high sub-beats, by using an inner Rcos
oscillator – but more sounds are possible using various waveforms in the role of that modulator. A W
oscillator can be used just as well (and if phase is lined up with a cosine wave by adding p1/4
, the phase will match that of an Rcos
oscillator).
Here's another variation – this time with a catear medium-bright wave type for the carrier – where different amplitude shaping combines with swapping in an evenangle inner modulator for the varying of the frequencies the two sub-beats reach, giving the beats another sound. An eventooth LFO is also used alongside the sawtooth to glide around the pitch a little differently; varying their parameters further can be interesting. This one also sounds nice for other carrier wave types.
$bpm=150*2 $strength=30 Wcat f0[ Wsaw f$bpm/240 a$strength p1/2 Weto f$bpm/240 a$strength ] p[ Rxpe mf f$bpm/120 a$strength*(240/$bpm)/2.r$strength*(240/$bpm)[ Wean p3/4 ] ] a1/4.r1[ Rsqe mf f$bpm/120 ] t30