Fix volume scaling for mono inputs, etc.

Fixes #4423.
Merge pull request #4427 from unknownbrackets/volume-fix

Fix volume scaling for mono inputs, etc.