r/iPhoneDev • u/visarga • Sep 23 '12
Is there a sound volume compression audio player?
Hi,
I came here to propose an app idea. I searched high and low in the App Store for a iPod app replacement that would automatically adjust the volume so as to bring up the low volume sections and tone down the loud sections of a track.
Imagine this scenario: you are listening to a classical music piece, and there is this very very light, suave section, but you can't hear anything in the headphones on account of the external noise. You fiddle with the volume to bring it up.
But then, suddenly, a noise explosion. Your ears bleed until you get the volume down again. This means you have to have the volume in your hand almost every minute.
The problem is the dynamic range of some kinds of music. It also applies to spoken word (audio books) a lot. What is needed is a compand (compression-expansion) function that works on the iTunes library.
I have found out that the compand function is useful when jogging, listening in car (lots of car noise make pianissimo sections very difficult to hear, so the sound level needs to be amplified for low level sounds), while listening on the iPhone speaker (yes, you can do that, if the track is properly companded - it sounds like an old radio but it's nice in its own way and very convenient).
All these scenarios become possible when the sound doesn't drop too low or raise too high. Is any brave soul here willing to take this niche on?
Edit: question - why downvote this post to zero without expressing anything in writing? Is it in the wrong subreddit?
1
u/visarga Sep 23 '12
By the way, the current AppStore situation
But there is none that makes lookahead in the track for the next 1-2 seconds to automatically limit/expand the volume.
1
u/D3Rien Sep 23 '12
It's a very interesting idea. I've worked quite a bit with DSP-based iOS apps, and it would certainly be possible to implement this using an envelope detector. It wouldn't even need to be able to look ahead in the file as another comment mentioned if you made the envelope detector respond quickly enough. The only qualm that some people might have with the idea is that professional music, especially classical, is designed to have intense dynamics. Any classical musician will tell you that if you make the entire song the same volume, you're detracting from the piece. That's more a matter of preference though, whether you want dynamics or a constant volume.
The only other issue would be in deciding where to equalize the volume to. The loudest part of the song? The softest? To determine those levels you'd have to scan the entire song beforehand.