First time here? Check out the FAQ!
x

Frequency/phase modulate a sample with another sample

+3 votes
1,321 views
Hi

As the title says, after being inspired by the Rossum Electro Music Assimil8r eurorack modular, which claims to be the first to phase modulate a sample with a sample (not sure of this, I've read that the Roland V-Synth can do this) it's made me explore what can be done in Kyma.  

As a result I've then throuroughly fallen down the rabbit hole of the differences between phase modulation, frequency modulation and thru-zero frequency modulation (TZFM) - I'm still a little confused and the internet appears full of inconsist terminology!  One conclusion I seem to have reached (incorrectly?) is that Kyma is very capable when it comes to oscillators but less so with samples.  The 'frequency' parameter of sample is limited to capytalk rate only.  I've been exploring using two sample with timeindex - which is great fun (the output of the first sample controls scrubbing through the timeindex of the second) but I don't believe this is quite what I'm after.  I also understand I could use a frequency tracker after a sample and feed this into the frequency of another sample - but again this is capytalk rate and not quite what I'm looking for.  

How would others approach it?
asked Mar 21, 2019 in Sound Design by ghood (Master) (3,060 points)

2 Answers

+1 vote

You're on the right track by using SampleWithTimeIndex because the TimeIndex input is the phase. Maybe, instead of replacing the TimeIndex with another SampleWithTimeIndex, you could try adding the modulator (the second Sample) to the linear phase (the TimeIndex). Change the level on the modulator Sample to something like !ModIndex, so when !ModIndex is 0, you hear the normal sample, and as you gradually increase !ModIndex, you hear more and more modulation of the phase.

You could try modeling it after the Phase Modulation with oscillators example in the Prototypes. In that example an AddWrap is used instead of a Mixer for adding the modulator output to the linear phase. That way, if you are close to the end of the sample and the modulator makes the phase swing beyond the end, it will wrap around to the beginning of the sample.

You could also experiment with modulating the TimeIndex of your Sample by an Oscillator, or in fact by any other Sound in the Prototypes. There's no need to limit yourself to using other samples as the modulators; any Sound could be the modulator — including live input from the microphone!

Hoping you will post your results if you get something interesting. Thanks!

answered Mar 21, 2019 by ssc (Savant) (128,000 points)
Excellent! Yes I'd thought of adding a modindex but not got round to trying. Very glad I was on right path! Yep, I'll post some results of experimentation!
Thanks
0 votes

Ok, so i've been having great fun playing and trying to learn more about FM/PM in Kyma - it makes my heard hurt a little as i'm not a mathematician! 

Here is kyma file with a sample being modulated by another sample (with the modindex amount being controlled a spectral analysis of another file for good measure) - you'll need to replace the samples I think. 

There is also a file that attempts to pool together different approaches to frequency modulation/phase modulation in kyma. Within the file there are six approaches (Paths), although I think 1 to 4 and number 6 are actually all the same (phase modulation) with the differences being:

1) Phase modulation using oscillators with a max MI of 60

2) Phase modulation using oscillators with phase being controlled by Float Pi * 2

3) Phase modulation using oscillators with phase being controlled by Double Pi * 2 (appears same as above - confused what is difference in message).

4) Phase modulation using samples with timeindex (as oscillators) with a max MI of 60

6) Same as Path 3 except that the messages in frequency parameters for the mod and carrier are switched.

Path 5 is the FM example from the Kyma library (taken, along with Path 6).  

One thing i'm a bit confused about, even with studying the scopes etc., is which approach makes the three approaches outlined in this informative video: https://www.youtube.com/watch?v=zU-eDTntDA4&t=163s.  I think that 1, 2, 3, 4 and 6 are all PM and 5 is thru-zero fm.  How would i get analogue stype FM? 

Sorry, these are probably silly questions but any help appreciated :)

Thanks so much!

answered Mar 29, 2019 by ghood (Master) (3,060 points)
Did you also find this one in the Kyma Sound Library? Kyma/Kyma Sound Library/Synthesis/Synthesis-VCS control Sound file: Oscillators.kym, the Sound called 'analog style FM in pitch space'?
Analog VCOs operate in pitch space (log frequency) which is how this example interprets its modulator.
The "thru-zero" FM is classic frequency modulation. (If the sum of the carrier frequency plus the modulator is negative, you go through the waveform backward).
Double pi is an approximation of pi in double-precision. Float pi is just a floating point approximation of pi.
Fantastic, thank you SSC! I'd missed the analogue style fm in examples and will check that out!
...