Jump to content


Photo

Generating own IRs for the convolver from plugins in renoise


  • Please log in to reply
9 replies to this topic

#1 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 17 January 2018 - 19:02

I want to share a little nice trick with you.

 

It is about generating impulse responses (IR) of reverb plugins, so you can use them in the convolver.

 

This might be useful to get rid of plugin dependencies in collab tunes, or if you want to share a clean .xrns that needs as little 3rd party plugins for good sound as possible.

 

Tech talk: You can also try other plugins than reverbs, or even whole plugin chains. But you will have to know that the capturing is linear in a mathematical sense. Only frequency balance and -delays will be captured, as well as most spatial effects, any distortions will just shift the frequency balanceof the result but it will still be clean. So you supercool analog EQ curve will be kind of captured, as will be the way it messes with phase. But coloring in terms of generating extra harmonics won't work - the harmonics will just be added to the frequency balance of the IR.

 

So - some plugins will sound different. Algorithmic reverb for example will lack any variations but become discrete and deterministic like other reverb IRs. You can try to resample a chorus, flanger, phaser, but any LFO action will be frozen to the moment when the click hit the effect.

 

I know there are probably pro solutions for this, like IR grabbers or so. Those will also work, maybe even better than the trick written down here. But for my simple method you won't need plugins, it works in renoise straight away.

 

 

How it works?

 

 

A) Prepare the impulse sample

 

1) "Create" an empty mono sample in the sample editor, at the same rate your project is running at. So if you're running renoise at 44.1 khz, choose the same rate for that sample. Set its length to the length of the reverb tail, plus maybe some extra. So 44100 samples will be one second at 44.1khz, 88200 samples will be 2 seconds, etc. Choose 32 bit, this is important for quality.

 

2) Zoom in into the beginning of the sample, so you can see/select the indivdual values. Use the draw tool to make only the very first sample the most high (upward) value. Yes, your sample should begin with a single peak and then only silence. If your hand was unsteady with the draw tool, don't try to draw the silence, select the whole sample but the single value spike, and hit the silence button to make sure.

 

3) Hit the "Adjust" button, and convert the sample to stereo, but leave all the rest as it is. You now have a silence sample with a spike at the first values for l and r. Save this sample as preset, you might want to use it again, and you can easily adjust length to what you need by copy/pasting/cutting the silence in it, just make sure you don't duplicate the spikes or silence them by accident. You will need to recreate the spikes for each sample rate you want to capture in, adjusting the sample type will destroy the cleanness of the spike.

 

4) for the 2nd Method you will need to turn off all sample changing options, so you want no "AA" you want no ramping, you don't want "cubic" or any other resampling but you have to set resampling to "none", you want to disable key/pitch and vel/vol options, no modulations, no bullshit no nothing just the spike and then silence as direct and clean as possible.

 

 

B) 1st method, in the sample editor

 

1) Get your reverb (or other...or chain...called "FX" now) plugin ready with the settings you want to capture. Load the spike/silence sample, make sure it is a bit longer than the tail or the FX you want to capture.

 

2) Place the FX in the same instrument, in some instrument fx chain by itself. Route the spike sample to that fc chain.

 

3) You might want to disable/mute the "dry" factor of the FX, later when you use the convolver it will have its own dry value, so you can still mess with dry/wet ratios. Also if you keep the dry, you cannot gain the IR any more as renoise will clip samples above 100% in the sample editor and this will mean turning down the dry level by the ratio that was clipped.

 

4) In the sample editor select the spike sample. Look below the waveform, there is a button "SFX" and a hamburger menu button to the right of it. Click the hamburger and select "Render Sample DSP chain". Click on the "SFX" Button

 

5) You should now have something that sounds like a very feeble click through your FX. If you had a dry level active despite my suggestion to turn it down, or the effect is passing sound direct by default, there also will still be the spike in the beginning. For effects passing some dry unchanged, it should look like in the original sample. For effects like EQs or Filters or such, the spike will have been transformed to something  That is the desired sound for an IR. You might want to amplify it, but only if it doesn't clip that way. You could also normalize, but then take great care that it won't get too loud within the convolver.

 

6) Save that sample. Load a convolver device somewhere where you want the effect (or so you can test first), load the sample into the convolver. I advise you to turn down completely both dry and wet first, and after loading the sample into the convolver, cautiously turn up the wet to see what you have.

 

7) If things went right, you will now have a very good simulation of the FX, inside your convolver. I found reverbs will need a boost of about 6db, with the convolver gain to -0.0db, to sound about the same LVL as the original with wet being at 100%. Resample with higher wet level than intended, to have some room for adjustments.

 

8) You could also use the "SFX" Option "Render Track DSP Chain", and put your FX into a track & select it before resampling...then you will have to watch for the track headroom settings for gaining your samples.

 

9) Maybe you will want to keep gain very low (lower than usual...) while rendering/resampling the click, and gain the result in another external sample editor that can gain more than 0dbfs when the renoise sample editor would clip and destroy the impulse response. It is normal for impulse responses, that seemingly very quiet and subtle data in the tail of the IR sample can have quite some big impact to the final sound. Also the renoise convolver is not 100% direct sounding but seems to include a DC filter that will change the sound in a subtle way.

 

 

C) 2nd Method. Resampling the click in a track TODO

 

1) TODO I will write about this soon, it features setting the click as a note in a track/pattern with the FX and then resampling it as selection to get the sample.

 

 

 

 

End of the story:

 

Use at own risk - unsuitable samples in the convolver have potential to generate very LOUD clipping sounds, that could destroy your hardware and hearing, so take care and touch the convolver wet slider with maximum care the first time you use a new IR sample...

 

I know it is most often better, to use sine sweep samples to excite any reverb plugin, and then convolve the result with the inverse sweep. I have tried this, but the single spike seems to work well enough with most plugs as long as you stay in the digital domain. For sampling analog/outboard gear you will most probably have to do a sweep or else your sounds will drown in noise.

 

Please add comments and experiences with this Method in this Thread! I will try to integrate nice tips and new findings into this first post, so all relevant info of this technique will stay condensed. Sorry if this technique had been brought up before, I am so forgetful, I will link to those posts from this thread if you point me to them, so all info on this topic can be found at a single place.

 

Have fun with your IRs....

 

 

 

 


  • Ledger, pat and beublo like this

#2 pat

pat

    Big GrandDaddy Member

  • Normal Members
  • PipPipPipPipPipPipPipPip
  • 480 posts
  • Gender:Male

Posted 17 January 2018 - 23:12

Cool technique!

 

I thought of something similar (and I think this is what your second method is all about). It sounds good, there's a technical aspect that I don't understand though. Anyway, here's what I did:

  1. Create a new sample with a length of 1
  2. Draw the maximum value for that one sample
  3. Disable AA, resampling, and loop
  4. Play that sample from a track with effects, render to sample
  5. Save the rendered sample to disk, load into convolver

Here's the technical aspect I don't get... I would expect that, if I play the impulse through the convolver (dry=0, wet=100, gain=0, resample=1x) and render that to a sample then I should get something that matches the original impulse response exactly. It doesn't though. Here's an example where I passed the impulse through a delay and rendered the result:

 

1_ir.png

 

Close-up of the IR beginning:

 

3_ir_close.png

 

I saved that result to disk and loaded it into the convolver. Then I played the impulse on the track with the convolver and rendered it:

 

2_convolved.png

 

Close-up of the convolved beginning:

 

4_convolved_close.png

 

I don't know much about convolution... my naive expectation is that the convolved version would match the impulse response exactly – it's convolving the impulse with the impulse response. But that doesn't seem to be the case. I'm wondering if that's a matter of sample format / settings, or maybe the convolver has an internal filter? The over all technique is cool, and I'm just curious what's going on under the hood...



#3 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 18 January 2018 - 16:25

Hi!

 

Yes you are right, the 2nd technique will be about placing a note of a click sample in a track and resampling it through dsp. I take some time with describing it, because it has an extra twist I want to mention, you can actually use instead of the click (which is basically also an "identity" impulse response), another IR you wish to modify, and you can mix and convolve IRs with each other while resampling, to combine their characteristics. I'm not sure yet whether describing the techniques might blow the thread with too much info, it already suffers from my inability to describe things in simple words.

 

The point about the different results of IRs is due to technical aspects of the renoise convolver, I think. The convolver will do rate conversion to match the sample rate of the IR to the current project sample rate, we even have this little slider that will let you up/downsample the IR which is pretty cool. The screenshot from you looks kind of like the response of a bandlimiting filter as used in resampling, especially the nyquist freq oscillations are characteristical. Maybe the renoise convolver also will apply a highpass filter, so that malformed impulse responses don't generate DC offset to the result that easily, I think a user of this forum already described the effect. Convolution is a bit like a very delicate equilibrium to get well formed results, any slight step away from that balance can cause undesired effects.

 

I have another point that poppep up in me about this whole technique, well it is a bit unfortunate, I am not sure how to properly handle it. Maybe it would be advisable to add silence before the spike, to capture any pre-ringing of certain plugins. Those plugins would normally add pdc/latency to compensate the pre-ringing, and quasi cutting it off with this method might change the sound of filters or EQs in the equation.

 

Still the whole method is a good one when it comes to replacing 3rd party reverb plugins, or also to craft complex IRs from plugins and even other convolvers.



#4 pat

pat

    Big GrandDaddy Member

  • Normal Members
  • PipPipPipPipPipPipPipPip
  • 480 posts
  • Gender:Male

Posted 18 January 2018 - 17:14

The point about the different results of IRs is due to technical aspects of the renoise convolver, I think. The convolver will do rate conversion to match the sample rate of the IR to the current project sample rate

 

 

That's what I thought, but I'm doing everything at 48khz – the impulse, IR, and project sampling rate are all 48khz. Maybe the convolver operates at 44.1? I saw something recently about the reverb being tuned specifically for 44.1, maybe the convolver is similar.

 

I have another point that poppep up in me about this whole technique, well it is a bit unfortunate, I am not sure how to properly handle it. Maybe it would be advisable to add silence before the spike, to capture any pre-ringing of certain plugins. Those plugins would normally add pdc/latency to compensate the pre-ringing, and quasi cutting it off with this method might change the sound of filters or EQs in the equation.

 

Ah yeah I've read a bit about that, that there should be silence before the impulse but I didn't know why. Pre-ringing makes sense. How would you trim the resulting IR sample then? Just find the first zero crossing and delete any silence at the beginning?



#5 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 18 January 2018 - 19:41

http://forum.renoise...ing-to-impulse/

 

Here is a thread with discussion regarding certain characteristics of the convolver. Seems like you've discovered another quirk loading the exact impulse into the convolver as IR :-) nice idea to come up with... To me it looks like some minimum phase filtering happening, maybe DC filter, and resampling filter also, then the convolver has this crappy tone control that maybe also has its impact in center position. You know...the 1 sample spike is kind of a very perfect theoretical impulse, containing components that aren't audible, DC and very high freq components - if that stuff was removed with filters, and also phases of frequency components moved by these filters, the result can look like what we get here. It should sound right about the same though, unless you modify it in certain ways. Maybe it is one thing to watch for when convolving IRs multiple times with each other, to use a convolver with direct throughput for the task, to evade possible degradations of the data?

 

As for the pre-ringing, I have not thought much about that yet, I mostly use the convolver for reverbs and delay like effects, maybe sometimes to simulate resonance of a body with my sounds inside it, so organic sounds rather... I'm rather excited by these techniques as they allow to craft such impulses, and tune them to the liking, I have not much tried to conserve certain plugins trying to be exact. Maybe the "best" way to handle pre ringing DSP would be to know the exact PDC of a plugin (there's plugins that can measure I think) and add just as much silence, and adding the right artificial PDC (yep there's also plugins that can do this) to a track doing only the convolver wet. To cut the ringing would always mean changing the sound, even if you use the standard optimal windowing functions to try to lessen the effect...as you cannot really window the tail of the starting impulse for more complex effects at the same time, it would change the sound even more than normal "windowing" operations that usually operate on both sides in symmetry. There are also mathematical ways of creating "minimum phase" versions of FIR filter kernels (an IR is just that), by shifting phase and eleminating any preringing, fucking up the IR even more while doing this...but I think those only would make sense on very simple filter kernel.

 

I don't know if there's actually many plugins, that add PDC and at the same time use the headroom for linear FIR filter pre-ringing. Maybe those linear phase mastering EQs do that by default, there it is to be expected. Then cutting away the ringing should have rather drastic effects on the tonal ballance.



#6 pat

pat

    Big GrandDaddy Member

  • Normal Members
  • PipPipPipPipPipPipPipPip
  • 480 posts
  • Gender:Male

Posted 18 January 2018 - 20:49

http://forum.renoise...ing-to-impulse/

 

Here is a thread with discussion regarding certain characteristics of the convolver. Seems like you've discovered another quirk loading the exact impulse into the convolver as IR :-) nice idea to come up with... To me it looks like some minimum phase filtering happening, maybe DC filter, and resampling filter also, then the convolver has this crappy tone control that maybe also has its impact in center position. You know...the 1 sample spike is kind of a very perfect theoretical impulse, containing components that aren't audible, DC and very high freq components - if that stuff was removed with filters, and also phases of frequency components moved by these filters, the result can look like what we get here. It should sound right about the same though, unless you modify it in certain ways. Maybe it is one thing to watch for when convolving IRs multiple times with each other, to use a convolver with direct throughput for the task, to evade possible degradations of the data?

 

 

Thanks for the link. Looks like we're not the first to try to understand what processing is happening inside of the Convolver :)

 

I've done a bit of online research and... this stuff is way above my head!

 

BUT here's something that may be totally wrong but makes sense to me: if you load an impulse file as the impulse response, and play the same impulse through it and render the result to a new sample, what you get is...

 

 the impulse response of Convolver itself?

 

giphy.gif


Edited by pat, 18 January 2018 - 22:43.

  • OopsIFly likes this

#7 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 18 January 2018 - 21:12

Yeah, kind of, and letting your head explode vigorously in a golden fountain just by the thought of that fact ist quite the appropriate reaction to deal with it.

 

heh, we can now use the crappy tone control filters, by resampling the IR of the...convolver twice, once with high tone, once with low tone, and then loading it into another convolver, singing while dancing around the old oak at new moon:

 

neeenerneener neeener,

 

1st blow: uppercut,

2nd blow lowercut,

3rd convolver in the hut!

 

Just load the crap, no dial touch,

but filter had still cut too much...

 

...but please don't cite me with that in public, and don't tell my GF else I would have lots of weird stuff to explain that could potentially put strain on our relationship...


  • pat likes this

#8 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 19 January 2018 - 15:19

Another interesting thought, after all the dancing had made me very thirsty, and I've had a glass of water in lack of beer...

 

It might be possible to inverse the IR of the convolver, to potentially counteract the convolver's processing? I mean if there's a possible inverse, you could apply it to your reverb IR (with some clean convolution algo) before loading it into the renoise convolver. I doubt the different being worth the hassle or audible at all, and maybe the correction filter will just mess up things even more...



#9 gentleclockdivider

gentleclockdivider

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2654 posts
  • Gender:Male
  • Location:something like a sea or a river...just moving
  • Interests:slacking

Posted 19 January 2018 - 19:26

Nothing new here   ;) ( been doing this stuff for a while ) 

The convolver has a high pass filter inside to prevent dc off set .( that's one of the reasons it sounds different to other I.R. reverbs )

I did a lot of testing in the past .

here the's thread , and yeah dev's don't give a damn ( or don't have enough time maybe ;)

http://forum.renoise...ing-to-impulse/


Edited by gentleclockdivider, 19 January 2018 - 19:30.

  • oneunkind and OopsIFly like this

THERE IS NO RELIGION SUPERIOR TO THE TRUTH


THERE IS NO TRUTH SUPERIOR TO THE ONE I CHOOSE

C'EST MIEUX D'ETRE BELLE ET REBELLE


QUE MOCHE ET REMOCHE



RUBIO RABIA

 


#10 OopsIFly

OopsIFly

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1117 posts
  • Gender:Male
  • Location:dislocated
  • Interests:durch sein

Posted 19 January 2018 - 20:10

Yes I already linked your thread here! :walkman:

 

Still in this context it seems a tempting idea, to use the IR of the convolver itself (like pat found how to get it), and try to invert it with math tools to compensate what the device does. Maybe inversion will counteract the effects of the highpass filter a bit, or smoothen the jaggieness of the resampling filter that also seems to be going on. But maybe it will just smear the stuff even more. It might correct phase shifts by the HP filter inside the convolver, but might mean that you have to bear with some extra delay for the resutling IR, as a phase correcting filter most probably won't be minimum phase but will need some pre-ringing. Well, you can kind of invert filter action with IRs, though the more the filter blocks in a frequency range, the uglier the results might become, and filtering close to or below noise floor is quasi impossible to reverse. The wobbling of the highpass filter you noticed in your thread might be correctable though.

 

At least we now have data at hand that can be analysed with math tools. It might be interesting, as you mentioned different sound, to analyse how exactly it is broken. I.e. run a freqz in a math prog on the convolver IR to see the freq and phase response shifts happening.

 

Is the effect of the highpass filter on the spatialness of the sound very strong? Or maybe it isn't the DC filter as you thought, but the resampling that will blur higher frequency information, as this can dull out a sound and potentially destroy spatial cues in much stronger ways? How have you noticed, with HQ headphones, or on studio monitors? I think, from my experience with experimenting with hrtf IRs, that even small phase shifts on something acting psychoaccoustically, can alter or destroy spatial impressions to a certain, sometimes very strong degree when using headphones, but on speakers this effect is not so noticeable.