=D I know how to equalize/tweak alsa system-wide; but few probs
Linux - DesktopThis forum is for the discussion of all Linux Software used in a desktop context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
"How to make ALSA use an equalizer...?" I asked myself. In short, the CAPS LADSPA plugins must be installed and the file ~/.asoundrc must be created with the content in the "code" block below (say, you can copy+paste). To tweak the frequecies, the numbers in the file where it says "control" have to be modified (use negative values for quiet bands, so the sound won't be trashed).
Here's the complete story (well, at least almost complete):
After googling and trying things like a maniac, I finally found out how to use LADSPA sound plugins for the entire sound output. On forums, this subject never is solved, so here is something hopefully to link to...
I installed the CAPS plugins via Debian repos, so they (the *.so files) are in /usr/lib/ladspa.
I created a file ~/.asoundrc which overrides ALSA options (most important of which is that the default playback device is "dmixed" with manual arguments):
(See below for example file)
For all users, this should be /etc/asound.conf.
The id 1773 means a specific LADSPA plugin from CAPS, an equalizer, and input->controls tweaks the frequencies. (I chose mainly minus values because it would clip too much otherwise). Period and buffer size are low so there is few lag. pcm.!default overrides the default dmix, so "dmixing" must be provided after passing the plugin.
And then I had a nice ALSA EQ! (newly started alsa-apps) Other LADSPA plugins can be processed like this either by ID or "label" (I didn't look up others, though).
8 bits per sample was not played, though, so please contribute if you know how to solve this! I'm sure this is becoming an interesting thread!
Update: Here's a file for ~/.asoundrc or /etc/asound.conf that enables recording and includes the declip plugin, as well as modifying the amplitude (=volume).
Also note again that the CAPS-plugins are needed.
It seems that the SWH project no longer contains the 1773 (equalizer) plugin.
If you replace the id "1773" with "1197" in the above code block, everything works beautifully.
PROBLEM WITH 64-BIT SYSTEMS: 32-bit ALSA applications can't output sound that is tweaked by LADSPA plugins. But there is a way for those to output normal (or amplified) sound.
Now, as an example, wine and sauerbraten are 32-bit applications (except if you recompile sauerbraten). I run 'wine' like this:
Code:
ALSA_PCM_DEFAULT=noeq wine /some/win/app.exe
Setting the variable ALSA_PCM_DEFAULT to "noeq" instructs ALSA to use the virtual device "noeq" as the default output because the config file tells it to use the device defined by the variable; if the variable isn't set, the device "_default" will be used (this is what I use for 64-bit applications, say most of the software that I use). The "default" device plugs into equalized output and the usual input.
When the "noeq" device is used, I found that it should have half the volume. This is because I can't equalize the standart ouput without either making it more quiet (and turn my speakers louder ), or make the sound clip and have real bad sound. Of course, I chose to make the sound more quiet. But that means that unequalized sound (I do need it, see below why) would be relatively loud, which would be annoying. So I found a way to adapt its volume to the equalized sound ouput: You can do that by "routing" the sound (although I don't really "route" it, I just use the aplification option). Voilą, the "noeq-out" device makes unequalized sound fit into my concept.
Why unequalized sound? 32-bit applications can't load 64-bit libraries. But the LADSPA plugins on a 64-bit system (note again, this is for 64-bit systems) are 64-bit.
I was trying to find out how to set up the systemwide equalizer in Jaunty. If not atleast I want to set up a custom equalizer for vlc player.
I could set up the equalizer in my vlc player but the problem I am facing is I cannot name it or save it as 'mine' or whatever name I want as one can do it in xmms (save as 'mine' or 'mine1' and then load 'mine' or 'mine1' etc whenever I want)
Secondly whenever I open a song to play in vls it starts with default 'flat' equalizer configuration. Even if I set up my own equalizer settings it changes to default when the next track begins.
In one sentence what I want is how to make the vlc player equalizer work similar to 'xmms'
PS: Why I want to do it is the default settings of xmms frequency bands are not good as compared to vlc player equilizer frequency settings (or tone quality)
I guess the approach with the file /etc/asound.conf isn't suitable for most end-users. I don't know about the problem in VLC as I rarely use its equalizer. But you could start another thread, with a title like "How do I save equalizer settings in VLC?", so people will see your question in the "Zero Reply Threads" list. That way you will get a helpful answer more likely. Also copy+paste can be useful so you don't have to write the whole post again .
If it doesn't work, make sure the LADSPA plugins are installed (I think they're from the CAPS set). When you have, play a .wav sound file with "aplay" (from the commandline) and post the output. Then we'll see what's wrong (hopefully).
Another way of doing that is with alsaequal *a guide can be found here* which can be used with the alsamixer gui (a graphical representation instead numbers) for adjusting the values.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.