Log in

No account? Create an account
Volume knobs: I hate. - brad's life — LiveJournal [entries|archive|friends|userinfo]
Brad Fitzpatrick

[ website | bradfitz.com ]
[ userinfo | livejournal userinfo ]
[ archive | journal archive ]

Volume knobs: I hate. [Jan. 27th, 2006|01:26 pm]
Brad Fitzpatrick
[Tags|, ]

To control the volume on a computer you typically have three knobs, and sometimes four:

-- your speakers have knobs
-- your master soundcard volume
-- your PCM soundcard volume
-- the application's volume, before it produces the PCM data


You never know which are line-level, which amplify, which attenuate.

Is there a guide or rules of thumb to setting your volume correctly?

[User Picture]From: hughe
2006-01-27 09:29 pm (UTC)
i would have thought everything digital can be up full without clipping...

so... probably only speakers would amplify and the rest would attenuate.. sortof.
(Reply) (Thread)
[User Picture]From: moonwick
2006-01-27 09:49 pm (UTC)
Yeah, that's the assumption I've always made as well.
(Reply) (Parent) (Thread)
[User Picture]From: avatraxiom
2006-01-28 07:04 am (UTC)
Yeah, that's what you'd think. On some cards, it's the case, but not on most consumer cards.

For example, on a Sound Blaster Live (emu10k1), it actually starts actually amplifying the signal at some unknown point on the slider. That is, I don't think that even 50% is actually unity. I think something like 70% is unity, but I can't even be certain about that.

And the best part is: Which knob controls the internal amplifer? All of them, as far as I can tell. That is, the resultant amplification seems to be a combination of the "Wave" "PCM" and "Master" sliders, on my emu10k1, although I think it's possible that PCM can be at 100% without clipping.

The major problem is that an amplifer just can't be large enough on a sound card. That is, there physically isn't enough space to have a high-quality amplifier. Professional sound cards leave that up to the external amp, for the most part. (The A/D converter can frequently give off different signal levels, but that's a pretty minor sort of amplification.)

(Reply) (Parent) (Thread)
[User Picture]From: jwz
2006-01-27 09:31 pm (UTC)
Use S/PDIF and you reduce the number of volume knobs by 2...
(Reply) (Thread)
[User Picture]From: separated
2006-01-27 09:41 pm (UTC)
I get confused enough when I plug my ipod into my speakers. Why bring more into this?!

(Reply) (Thread)
[User Picture]From: nick
2006-01-27 09:47 pm (UTC)
Ok... pleading electical ignorance, but isn't to attenuate the opposite of to amplify?
(Reply) (Thread)
[User Picture]From: nick
2006-01-27 09:51 pm (UTC)
nevermind I'm not confused anymore, just retarded...
(Reply) (Parent) (Thread)
[User Picture]From: kvance
2006-01-27 09:49 pm (UTC)
I think it depends on the hardware. IIRC, the emu10k1 drivers use DSP effects to attenuate Master and PCM volume. That's the only driver I'm familiar with (..actually, I still have the source lying around. It pretty much does io = io*volume).

Every app should use the hardware mixer unless you tell it not to.

So at least in that configuration, proper listening should have hw mixer vols at 100% and you should use the speaker knobs to change the volume. That said, I just keep a bmp or xmms on the screen so I can roll my mouse into the corner and use the wheel as my volume knob :P
(Reply) (Thread)
[User Picture]From: gen_witt
2006-01-27 09:50 pm (UTC)
I think whats most rediculous is that if my master and PCM volumes are all the way up the line level amp on the soundcard goes into clipping. So I set all my software volumes to 70-80% of clipping, and then adjust my volume at the speaker.

Then again, I'm practically tone deaf, so I have no idea if this gives the best audio quality.
(Reply) (Thread)
From: evan
2006-01-27 09:57 pm (UTC)
Oh man, I have the exact same problem. And different programs tweak different settings (mplayer changes PCM, while something else I use just changes master).
(Reply) (Thread)
[User Picture]From: boggyb
2006-01-27 10:57 pm (UTC)
What's more fun is when you have a program which locks Wave and Master together, and adjusts both. This gives rise to all sorts of fun, especially when you realise that while appearing to be linear, the controls are actually logarithmic.

FYI, my current setting is DSP-level controls (individual programs) adjusted as needed for balance between programs (i.e. XMPlay is usually at max but dropped down to 30% when I'm playing a quiet game), Wave at 100%, Master at ~20% and speakers at 9-10 o'clock (on a scale of 7 o'clock to 5). Plenty of headroom for more power if I want it.
(Reply) (Parent) (Thread)
[User Picture]From: grumpy_sysadmin
2006-01-28 02:02 am (UTC)
"Open Source Software: your eardrums' stability is our learning experience!"
(Reply) (Parent) (Thread)
[User Picture]From: morallybass
2006-01-27 10:12 pm (UTC)
I would think you just want to ensure that you're not clipping anywhere. Make sure all of the levels in the chain are at 75% or so and only adjust up the final level above or below that.
(Reply) (Thread)
[User Picture]From: kuteluvr
2006-01-27 10:28 pm (UTC)
I've been through this already: http://www.kuteluvr.com/69778.html
(Reply) (Thread)
[User Picture]From: mendel
2006-01-28 01:12 am (UTC)
Only four?

(Reply) (Thread)
From: (Anonymous)
2006-01-28 03:22 am (UTC)

I can beat that!

But I don't have a screenshot...

I have my Mac server's audio out plugged to my linux box's line in.

So from the mac....

app -> system -> line in -> master -> stupid knob -> speakers

so iTunes goes through 6 volume controls before any air is moving.

The "stupid knob" is a volume knob on the front of the computer with a slot cover thing that has 2 1/8" stereo jacks. The PC soundcard output goes into that, then I can control my volume with a nice analog knob (which beats the hell out of using the mouse to drag a slider, and is way faster than banging on a volume key repeatedly, and (mosty importantly) doesn't depend on any software.

I've been having a bitch of a time trying to balance volumes between iTunes and xmms. I so wish iTunes music sharing didn't suck so much ass.
(Reply) (Parent) (Thread)
[User Picture]From: taral
2006-01-28 01:26 am (UTC)
Play a 100% sine wave and check for clipping at every level.
(Reply) (Thread)
[User Picture]From: grumpy_sysadmin
2006-01-28 02:05 am (UTC)
Right, because that makes more sense than the device giving a single soft...loud knob. We should clearly all just be audio engineers, and clearly the computer is doing us a favor by letting us tweak this configuration at each level.
(Reply) (Parent) (Thread)
[User Picture]From: taral
2006-01-28 02:18 am (UTC)
Nobody said the configuration was a good one. Brad asked for a way to tell how to set the levels. This is one.
(Reply) (Parent) (Thread)
[User Picture]From: grumpy_sysadmin
2006-01-28 02:43 am (UTC)
Right, well, I was laughing too hard by the actual question to notice that. I was laughing at the "no, really, I know computers, and they all suck" part.
(Reply) (Parent) (Thread)
[User Picture]From: taral
2006-01-28 08:02 pm (UTC)
Oh! Sorry, I saw "grumpy" and read it in a more grumpy tone. :)
(Reply) (Parent) (Thread)
[User Picture]From: loganb
2006-01-28 09:18 am (UTC)
In theory (and assuming you aren't using S/PDIF) you want to make your digital controls as loud as possible and your analog volume controls as soft as possible to maximize the SNR in the analog stage of your sound card (which is typically poor due to PCI/CPU bus noise in the machine). In fact, I only use USB sound cards these days if I'm listening with headphones since the added electrical sensitivity of the phones usually picks up additional noise; it really makes a difference.

But, obviously the gain on the digital controls must be <1 or else you will start to clip and distort. I find that you can get to roughly +3dB (x2 on a linear scale) before the clipping becomes apparent when listening to music (in case you really need it to be loud), but if the audio content contains remotely pure tones (read: synth), you'll notice.

I find the best way to tweak the digital controls is to play a full-scale sine wave (440Hz works well), crank up all the knobs all the way, recognize the harmonics from the clipping, and then back them off slowly until you hear just the pure tone again. By that point effects from clipping will be > ~12dB down and that's good enough for causal listening.

Then, always use your analog control to pick optimal listening volume. If you use the digital control instead, the analog noise floor will remain constant so your SNR will get worse when you turn the volume down. Then you'll eventually forget and crank it back up with the analog control and hear bus traffic on every god damn page scroll in your web browser.
(Reply) (Thread)
[User Picture]From: j7xz49br3m93xrr
2006-01-28 12:42 pm (UTC)
Don't forget the 'equalizer' functions in both applications AND on your amp!

The rule I've seen concerning equalizers is that no level should be above the midway point, and you should simply reduce the levels in the relevant places rather than increase them in others.
(Reply) (Parent) (Thread)
[User Picture]From: cyberpigue
2006-01-28 01:44 pm (UTC)
Agreed. I went to an external USB device for the computer in my car to loose lots of unwanted noise. I have individual sliders set for best quality on the mixer and the single mixer out slider set to give a clean strong signal to an input on the DVD head where I contol listening volume. I gave my GPS software's output a slight advantage over the others so it "interrupts" them with messages when necessary.
(Reply) (Parent) (Thread)
[User Picture]From: eli
2006-01-29 12:25 am (UTC)
Set them all to 11!
(Reply) (Thread)