Oeyvind Brandtsegg, 2007
obrandts@gmail.com
PartikkelExplorer is a python gui for experimenting with the csound
partikkel opcode.
This document contains a few references to the code, should you need to
make changes to the application.
However, it should be possible for inexperienced users to just have a go
at experimenting with partikkel as it is.
Selecting an audio output device:
The csound commandline
parameters can be found in the file csoundCommandLine.py,
this is the only part of the code
that you probably will have to edit.
For details on the csound command line
parameters, refer to the csound manual.
Run the file PartikkelExplorer.py
Here's a brief introduction to what the GUI does:
Starts the csound
partikkel instrument.
These select the audio waveforms to be used as source for grains.
To add your own samples, edit the file ftables_samples.inc,
adding your sample like this:
giZyne
ftgen 0, 0, 262144, 1,
"Zyne1.wav", 0, 0, 1
You will also need to write the ftable number to a csound
chn string channel, so that Python can refer to the
table number by name.
Like this:
chnset giZyne, "giZyne"
; makes ftable number accessible via string channel
Finally, you must add your sample name to the dropdown menu controls in
the Python GUI,
this is done in line 110 of PartikkelExplorer.py:
soundlist =
['giZyne','giFlyndrSand','giVib_Eb','giVok1']
Many of the sliders correspond directly to partikkel parameters (see
partikkel manual page). However, the wxPython sliders
does not work with floats so I've scaled the (integer) output of the sliders
where needed. See line 124 of PartikkelExplorer.py if
you need to check the scaling of each parameter.
Grain Amp : The master amplitude.
Grain Rate : Number of grains per second.
GrFmIndx
: Frequency modulation index, modulating the grain rate.
GrFmFqRat
: Frequency modulation frequency, as percentage of the grain rate.
GrDist
: Grain distribution.
GrTransp
: Transposition (pitch) scaling of all grains.
SweepShape
: Shape of the curve for transposition sweeps (depends on the setting of StartFreq and EndFreq in the multislider windows)
FmIndex
: FM Modulation index, modulating the pitch of source waveforms.
FmFreq
: Frequency of the FM oscillator, modulating the pitch of source
waveforms. If Frequency is set to zero, audio feedback is used instead of an
oscillator for the FM modulator signal.
GrDur
: Grain duration, in percent of 1/grainrate, so e.g. a value of 400 gives
a grain overlap of 4.
GrAttack: Balance between attack time
and decay time for grain enveloping, 0 = zero attack time and full decay time.
GrShape: Amount of grain (attack and
decay) enveloping. This can also be described as balance between enveloped time(attack+decay) and sustain
level time, 0 = no time at sustain level.
GrEnv2: Amount of secondary enveloping. A secondary envelope shape can
be applied to the whole grain, currently a falling
sigmoid envelope is used. This can be changed by editing ftables_envelopes.inc
(line 5) and/or partikkel_instr.inc (line 39). The
attack and decay envelopes can be edited in a similar way.
TimLfoFq
: LFO frequency, modulating the time pointer
offset (see TimPosOff).
TimLfoAmt
: LFO amount, modulating the time pointer
offset (see TimPosOff).
TimPosOff
: Time position offset, reading of source grain waveforms start from this
position in the waveform. Scaled as percentage of the
waveform length. For example, setting this to 50 will let new grains
start reading from halfway through the source waveform. For single cycle
waveforms it would make sense to call this "phase", but for sampled
sounds it makes more sens to name it "time
position".
RandMask
: Amount of random masking (muting) of grains.
ChnWidth
: Stereo spread of partikkel audio outputs 1 and 2.
d2Dly : Delay time for partikkel
audio output
chorusAmt
: Chorus effect send amount for partikkel audio output 3.
reverbAmt
: Reverb effect send amount for partikkel audio output 4.
ChnRewrit
: Rewrite LFO speed. This controls a continuous
rewriting of the channel masks ftable, similar to a panning LFO.
Since some partikkel audio outs are used for stereo positioning and other outputs
are used for effect sends, this control enables a sort of sonic animation. When
setting the control to zero, the original contents of the channel mask table is
restored.
TrnAmp
: Amplitude for trainlets. This is implemented
so that increasing trainlet amplitude automatically
decreases amplitude for waveform grains. The resulting wave mix values are
written to the wave mix ftable at the index currently selected in the GUI
control WavMaskEdit.
TrnCps
: The fundamental frequency of the trainlets.
TrnHarm
: Number of harmonics for the trainlets.
TrnChrom
: Trainlet chroma. Harmonic balance of the trainlets.
nFmIndx
: Frequency modulation index for a noise modulator signal added to the FM
modulator (FmIndex,FmFreq controls) modulating the
pitch of source waveforms.
nFmDist
: Random distribution for the noise FM modulator signal. See csound opcode rnd31. Gui values
are scaled * 0.01.
nFmFreq
: Lowpass filter frequency for the noise FM
modulator signal.
ChMaskStart
: Start (loop start) index for reading channel mask values. Channel masks
specify which audio output grains are routed to, per grain.
ChMaskEnd
: End (loop end) index for reading channel mask values.
GnMaskStart
: Start (loop start) index for reading gain mask values. Gain masks
specify gain per grain.
GnMaskEnd
: End (loop end) index for reading gain mask values.
FmMaskStart
: Start (loop start) index for reading FM mask values. FM masks specify
modulation index per grain.
FmMaskEnd
: End (loop end) index for reading FM mask values.
Fq1MaskStart : Start (loop start) index for
reading pitch sweep start values. Transposition at start of
grain, per grain.
Fq1MaskEnd : End (loop end) index for
reading pitch sweep start values.
Fq2MaskStart : Start (loop start) index for
reading pitch sweep end values. Transposition at end of
grain, per grain.
Fq2MaskEnd : End (loop end) index for
reading pitch sweep end values.
WavMaskStart
: Start (loop start) index for reading waveform mix values. Mix of 4
source waveforms per grain.
WavMaskEnd
: End (loop end) index for reading waveform mix values.
WavMaskEdit : The current waveform mix
index to edit by using the "WaveMix" (xyPlot or joystick) graphical editing window.
Each of these has 8 "sliders" representing indices for
"per grain" control parameters. You can set values for each index by
clicking or dragging with the mouse. Csound table values are updated
accordingly.
Channel Masks : Values representing output
routing per grain.
Gain Masks : Values representing gain per grain
FM Index Masks : Values representing FM
modulation index per grain
Start Freq Masks : Value representing
(transposition) pitch sweep start value per grain.
End Freq Masks : Value representing
(transposition) pitch sweep end value per grain.
WaveMix
: X and Y axis used to control the mix of 4 source waveforms per grain.