Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

real-time volume auto adjusting

by aquarium (Curate)
on Jul 06, 2004 at 00:48 UTC ( #371997=perlquestion: print w/replies, xml ) Need Help??

aquarium has asked for the wisdom of the Perl Monks concerning the following question:

yahoo chat (and other voice chats) are a real pain....different ppl have setup their own recording level, and you hear some voices faintly, and some LOUD. i want a automatic volume/speaker adjuster thingy, to level out the volume of voice chats. i have found 0 utilities to do this (Windows platform), so i'll try in perl if i can. i've looked around and only found perl modules to play sounds or to play with mp3s etc. Is there any way (module?) to do this in real-time in perl?

Replies are listed 'Best First'.
Re: real-time volume auto adjusting
by theorbtwo (Prior) on Jul 06, 2004 at 02:47 UTC

    I'd suggest just asking your yahoo friends to run through the mic setup wizard, which is designed for exactly that problem.

    This problem is a lot harder then it sounds.

    If you really want to build something to do this, you're probably much better off trying to build a bit of hardware to do it (try gooling for something like stereo limiter project plan*).

Re: real-time volume auto adjusting
by bibo (Pilgrim) on Jul 06, 2004 at 03:49 UTC
    Umm, as was mentioned, this is a hard one. Didn't you ever wish your car radio would automatically adjust volume based on ambient cabin noise (going 65 with windows open vs parked in driveway)?? I also feel Perl is likely the wrong tool for this job. This sort of realtime stuff is usually done in C or assembly code (yikes!).

    good luck with this, aquarium!

      found something related....some winamp plug-ins that do exactly this...unfortunatelly, winamp doesn't control everything coming out the speakers, but only files/cd's it's playing
Re: real-time volume auto adjusting
by Joost (Canon) on Jul 06, 2004 at 08:34 UTC
    If you can find a way to route your chat program's audio through another program you can try running it through a software limiter or compressor (like a VST or Direct-X plugin on windows), that should take care of the problem.

    If you're feeling adventureous, try compiling my Audio::LADSPA modules and the CMT library . That should give you (amongst other things) a software compressor and audio out , now all you need is a way to route your chat program's audio into it. If you get it to work, let me know.

    Good luck,
    Joost.

Re: real-time volume auto adjusting
by zentara (Archbishop) on Jul 06, 2004 at 12:35 UTC
    One thing I thought I would mention is that people with digital speakers often can only adjust volume with the rotary volume knob on the digital speakers......that is "setting volume level" in the mixer SOMETIMES won't affect the output volume. Just another thing which makes this a hard task. I used to be an audio-visual equipment technician, and I'm sure there is a method for making an "automatic volume level" control circuit; but it would be tricky and you would need 2 different circuits...one for digital data and 1 for analog.

    I'm not really a human, but I play one on earth. flash japh

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://371997]
Approved by rupesh
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2022-06-30 16:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My most frequent journeys are powered by:









    Results (98 votes). Check out past polls.

    Notices?