I would be interested in it too.
The things I don’t really know for doing it are :
1) How should the current playing position be calculated? I assume you have to buffer some VU values, and the buffered values will play at Now + StreamBufferLength or at Now + StreamBufferLength + FMod_BufferLength?
2)How to calculate the VU dB based. I think it has something to do with change in amplitude instead of just max amplitude?

Guys. I guess that getting the current VU and multiplying it with the current panorama settings, as suggested by Brett, would yield in wrong result.

As I see, a VU meter should show the strength of a signal of a channel you play. Now, take a stereo song. Usually there are different signal strengths on the left and right side of the music at a given time, as mixed by the sound engineer. If I get only one volume and calculate “pseudo-levels” based on pan, I’m not right, ‘cuse why would it be equal to the factual signal strength of a channel?

What if I make a stereo record in which my silent voice can be heard on the left channel and a loud drum on the right? If I can get only the aggregated volume of the two channels and calculate left and right volume levels by the panorama, it just won’t be real, ‘cuse on the left, there will be always a low volume level (my silent voice), however the method Brett suggested would give me the volume level of the drum (originally recorded to the right channel) if the pan is currently set to the left.

I’m not quite sure I understood the formula you gave brett.. I’m also interested in a stereo L/R VU. Right now I just use GetCurrentVU with scale 0-255 for integer values, and copy for L and R so they at least show up.

But whats this you say how to get 2 values? I dont have any panning control in my player (I just assume center) – keeps things less complicated for my already crowded GUI hehe. Mind spelling out the two formulas for turning the GetCurrentVU result to L and R values. Please?

I’m just lost, my brain isnt working too well tonight, finally got my app to behave with all the new API-driven code. Next stop is using the Winsock API instead of M$ .ocx

Yeah, I’m more interested in doing the stereo VU for streams. My current development isnt anything to do with modules.

Anon: thats what a VU meter is essentially. The technical definition is Voltage Units, which measure the strength of the electrical current into the meter. For the casual listener, this is equivalent to the “volume” or amplitude of the input signal, which determines how “loud” something sounds at a given volume. For us sound gurus and techy geeks, accurate VUs and sound levels are important 😉