Welcome to %s forums

BrainModular Users Forum

Login Register

Audio to midi patch latency setting help

I need help on a Patch
Post Reply
RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 23 Aug 2008, 02:01

I've been following Usine vst since it was released, and I love the audio to midi patch, mostly because you can set the latency real low.

Now it seems to be set at 11ms, and I can't seem to change it, even by changing the script. Is it possible to make it lower, 11ms isn't fun on the low notes.

I pulled out an old version of Usine vst I had, and have been playing with 5ms.

Thanks!

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 23 Aug 2008, 23:36

the audio 2midi subpatch is made by compromise between latency and the precision of the detection.
It's probably easy to set the latency to a lower value. I'll try to take a look.

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 24 Aug 2008, 02:07

Cool, ever since the vst version was released, I've been using the audio to midi. Just recently I noticed after an update, that the box in the audio to midi patch that has latency on it, is at 11ms and it doesn't allow me to change it by dragging the mouse on it, like I did in the previous versions. Thanks.

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 24 Aug 2008, 09:54

Just recently I noticed after an update, that the box in the audio to midi patch that has latency on it, is at 11ms and it doesn't allow me to change it by dragging the mouse on it
?????
very strange cause i can move the fader without problem here and use 0 to 11 of latency...

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 24 Aug 2008, 18:33

yes you're right Yan.
Just verified, the latency can be changed with the fader from 0 to 200.

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 24 Aug 2008, 18:37

Well that's good news! I was 1 or 2 versions behind, I'll download the latest Usine and try it out.

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 24 Aug 2008, 22:35

I got the latest version of Usine, same as before. I open the audio to midi patch, and go over to the box marked "script filter" and I click on it. Now the script box opens on the right hand side, and latency is set at 11ms and dragging my mouse on it changes the parameter, but it always snaps back to 11ms.

But if I press show script, and go to "set min and set max", they by default are set to 0 and 200, change them both to 5, compile it, now it's set a 5ms latency. But I can't get it so dragging my mouse can change it otherwise.

Now on an older release, Usine vst3.62Beta8, if I drag the latency measurment, it changes and doesn't snap back to 11. I looked in the script, seems pretty much the same.

Is there any action I'm missing to change the latency faster than re-compiling the script?

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 24 Aug 2008, 23:15

oh yeah ! more easy !
there's a fader attached to the inlet named latency of the script module
move this one to change the value ...better and no need to recompile...
when there is a knob or fader to an inlet , it's become " as a master " for this value ( hope i'm clear enought )
as bonus you can affect a midi learn to this fader...
or second choice , if you don't need it , just delete it and now you can edit values directly in the script module...

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 25 Aug 2008, 01:29

Here's a pic: Image

Ok in this pic: the left side, is the script filter box, once I click on it the script module appears to the right of that. In the script module, at the bottom is latency, you can see it's set to 11ms. Now dragging on this with my mouse, changes it but it immediately snaps back to 11ms. There's no way to change it with my mouse. The older versions, you could drag your mouse there to change it.

Now I have to edit the script.

bsork
Site Admin
Posts: 1334
Location: Asker, Norway
Contact:

Unread post by bsork » 25 Aug 2008, 08:09

Hi RunBeerRun, you're problem stems from what nay-seven points out: There's a fader connected to the latency input of the script which makes the value jump back to 11ms. As he says, adjust the value on the fader module, or just delete the fader altogether and adjust the input of the script.
Bjørn S

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 25 Aug 2008, 17:43

I noticed that fader box attached to latency, changing the max on that to 5 affects the latency.

So all in all, setting latency isn't a problem anymore. But I'm still wondering, on previous releases, it looks the same in the audio to midi patch, but I can drag the latency on the module that I showed in the above pic, while with the latest release I can't, it snaps back to 11 unless I modify the latency fader box or the script.

It was definitely easier before.

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 25 Aug 2008, 18:37

just try on the 3.65 version...same for me..???
the only moment when you can do that is when audio is off on your track...
so are you sure you have test in same conditions...?

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 25 Aug 2008, 19:00

With the lastest version, if I turn the audio off I can change the latency with my mouse, but when I turn the audio back on it resets back to 11ms. Is there any way to have it stay where I set it?

With most of the earlier releases, I could set the latency with my mouse even with the audio on.

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 25 Aug 2008, 20:01

you have to change the latency directly on the sub-patch, not on the script.

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 25 Aug 2008, 20:08

Well I don't want to take up any more of your guys time....

I don't know what a sub-patch is, I do know what a Usine "patch" is.

On the old versions, you could change latency on the script though.

By sub-patch, is that meant the boxes inside the audio to midi patch, for example I know I can change it on the fader box attached to latency, all the way on the left side.

I'll probably stick with the old version of Usine.

bsork
Site Admin
Posts: 1334
Location: Asker, Norway
Contact:

Unread post by bsork » 26 Aug 2008, 08:21

Hi RunBeerRun.

A sub-patch is a "patch-within-a-patch". A patch can contain many sub-patches, and sub-patches can contain other sub-patches - as many as your computer can take. They're useful both for creating "super-modules" like eg. the counter and envelope patches found amongst the other modules in the browser, or just for making complex patches easier to deal with by separating parts of it and/or having the same functionality repeated.

Regarding setting values - for instance a fader in the main patch connected to a fader or data input module within a sub-patch which in turn is connected to an input of a script - the value is governed by the fader in the main patch. The exception to this is when the "slave" inputs (in this case in the sub-patch or script) have min/max values not corresponding to the min/max value of the fader. If you want to try this, just create a handful of faders connected to each other with differing settings, and check the output of each.

Regarding the seemingly working update when the track is off: This happens because Usine doesn't do any calculations on the patch at all except updating the GUI with whatever you do with your mouse (hope I'm not lying here, Olivier?). When the track is turned on, calculations start and the fader is again updated by the connections to it.
Bjørn S

RunBeerRun
Member
Posts: 18
Contact:

Unread post by RunBeerRun » 26 Aug 2008, 17:10

OK, thanks for the reply, I understand partially.

I'm going to poke around the latest version of Usine today.

komuso
Member
Posts: 20
Location: Tokyo
Contact:

Unread post by komuso » 14 Sep 2008, 09:25

Hi,
I've just downloaded usine to have a look and see if I can use it for my project.

Is there an audio2midi cc patch readily available? I can only find an audio2pitch, and I want to test driving some cc controls with audio input.

Cheers,
komuso

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 15 Sep 2008, 11:03

s there an audio2midi cc patch readily available? I can only find an audio2pitch, and I want to test driving some cc controls with audio input.
the Audio to midi patch can be adapted to send CC: all you need is to transform NOTE ON events into CC events.
add a 'Create Midi Msg' module in the audio2midi sub patch.

then connect

Midi filter-send --> Create Midi - create
Midi filter - data 1 to ---> Create Midi - data 2
then
set Create midi - msg = CONTROL CHANGE
Create midi -data1 = n° of CC you want

now add a MIDI out module and connect
create midi msg- out --> Midi out - midi

I hope it will help!

komuso
Member
Posts: 20
Location: Tokyo
Contact:

Unread post by komuso » 15 Sep 2008, 11:52

ty. I'll give it a try!

bsork
Site Admin
Posts: 1334
Location: Asker, Norway
Contact:

Unread post by bsork » 15 Sep 2008, 11:54

Or if you only want to use level - not pitch - to create CCs, you can use the Envelope Follower or Peak Follower modules.

Use the Create Midi set to the controller number of choice together with some math etc.

Example of continuous controller:
EnvelopeFollower.out -> A.A*B (set B=127) -> CreateMidi.data2
EnvelopeFollower.out -> HasChanged -> CreateMidi.create

Changing the Envelope Follower with the Peak Follower in the above would create CCs values of only 0 and 127 and nothing inbetween.

You can also create toggle-type message if you want to with the Peak Follower:
PeakFollower.out -> Toggle.in
Toggle.out -> A.A*B (set B=127 or whatever) -> CreateMidi.data2
Toggle.out -> HasChanged -> CreateMidi.create
This would alternate between CC values of 0 and 127 for each time a transient/peak is detected.
Bjørn S

komuso
Member
Posts: 20
Location: Tokyo
Contact:

Unread post by komuso » 15 Sep 2008, 13:29

ah, ty..yes it was level not pitch I was after...dynamics envelope follower -> cc

komuso
Member
Posts: 20
Location: Tokyo
Contact:

Unread post by komuso » 24 Sep 2008, 12:12

Hi, ty for the tips. I've got it working, also with some smoothing on the output.

http://www.sensomusic.com/download.php? ... wer2CC.pat

I'm using it to test by driving track master volume, but when I use heavy input it's peaking above 12db causing ugly clipping. What's the best way of limiting it from spiking the track volume above certain max peak? I have a limiter on the audio output but it's not working in this case...keeps spiking into the redzone.

Cheers, kt

bsork
Site Admin
Posts: 1334
Location: Asker, Norway
Contact:

Unread post by bsork » 24 Sep 2008, 12:21

I'm not sure if you mean clipping on the input or output? The gain can as you know be set various places, and you can use the soft clipper module to keep things within 0dB. I don't know how "soft" the clipping is with a very heavy input though. Could you be more specific about how you've set up things?
Bjørn S

komuso
Member
Posts: 20
Location: Tokyo
Contact:

Unread post by komuso » 24 Sep 2008, 12:53

envelope follower 2 cc on track 2 -> Midi out 1

Track 1 has a piano roll, track volume controlled by midi cc from the envelope follower.
Track 1 vol is therefore peaking when driven too hard.

Limiter/clipper won't work as it is driving the master output into overload it seems.
I guess I should control the volume of the piano roller directly, and a limiter after that should take care of it, but I can't find a simple mixer module with volume control to do it.

edit: ah...I see, stereo volume....search for names in the modules would be nice! doh!

edit2: works ok now, ty! Gain control via cc before limiter, not track vol does the trick.

Just finding my way round!

bsork
Site Admin
Posts: 1334
Location: Asker, Norway
Contact:

Unread post by bsork » 24 Sep 2008, 13:36

Good you found a solution!

Another tip would be to scale the volume control one way or another to "tame" it, either if possible on how the VSTi reacts to the CCs, or for example using the mapper curve module. Or perhaps just divide the control with 2 or something like that?
Bjørn S

Post Reply

Who is online

Users browsing this forum: No registered users and 77 guests