PURE DATA forum~

...that deal with pure data

You are not logged in.

#1 2010-03-01 23:07:48

halflifebe
Member

A simple way to make a VU meter?

Hi everyone,

I would like to cotrol the output level of my patch.
I've try to use the VU (in the "put" menu) but I don't understand how it works.... :(
Is there a way to get my audio in this VU?

Thanks

Offline

 

#2 2010-03-01 23:22:38

slur
Member

Re: A simple way to make a VU meter?

go to help->browser

answer is you need a *~, something to give it a value and a dac~


pd redefining mathematics |expr fact(0)|==0

Offline

 

#3 2010-03-02 05:56:54

Maelstorm
Administrator

Re: A simple way to make a VU meter?

The [vu] only accepts messages, so you need use [env~] to get the rms dB level, then rescale it. [env~] uses 100 dB to represent full scale, but [vu] uses 0 dB.

Accurate peak metering is pretty bitchy, and I'm not aware of an external that does it well, but you can at least use [edge~] to detect if it's clipping.

[expr~ abs($v1)>1]
|
[edge~]
|
[bng] <-- will bang when out of -1 to 1 range

Last edited by Maelstorm (2010-03-02 05:57:11)


.mmb

Offline

 

#4 2010-03-02 12:50:07

slur
Member

Re: A simple way to make a VU meter?

oh i thought he just wanted a volume control
interestingly there isn't even a help patch for edge~


pd redefining mathematics |expr fact(0)|==0

Offline

 

#5 2010-03-02 17:45:18

Maelstorm
Administrator

Re: A simple way to make a VU meter?


.mmb

Offline

 

#6 2010-03-03 23:37:36

halflifebe
Member

Re: A simple way to make a VU meter?

Ok thanks I've made one but I think I didn't rescale the output of the env~ correctly...

Here's my patch. Is it OK?

Offline

 

#7 2010-03-03 23:56:52

slur
Member

Re: A simple way to make a VU meter?

so what about my quick idea?
but as mmb stated that's not accurate because of env~

Last edited by slur (2010-03-04 00:18:40)


pd redefining mathematics |expr fact(0)|==0

Offline

 

#8 2010-03-04 00:33:06

ledhed2222
Member

Re: A simple way to make a VU meter?

I've done this before without too much headache, and I don't see any problem with it.


(If you have more than output) connect all of your outputs to a [+~] object, connect this to a [env~] object, then to a [- 100] object, then to a number atom, finally send the output of the number atom to your VU meter.

Offline

 

#9 2010-03-04 00:53:40

ledhed2222
Member

Re: A simple way to make a VU meter?

I just took a look at that thing, your code should work (and you don't need a [+~] obj).  To make it look pretty, switch the [- 100] and number objects, then do a send from the number atom to the VU meter so that you don't see a patch cord going into the meter.

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson


pd.webring info