Hacker News new | ask | show | jobs
by lxgr 786 days ago
How old of a landline are you talking about here?

Anything newer than (heavily depending on the country, probably) the 70s or 80s or so would have been very likely PCM u-law or a-law at 64 kbps (i.e. 4 kHz audio bandwidth at 8 bit), which is literally a mandatory codec in WebRTC.

It would have to be a really old, purely analog baseband line without filters (maybe a local call between offices), frequency modulation etc. to preserve more than the typical 4 kHz of audio bandwidth you'd get on these. Inter-trunk connections were often frequency multiplexed to fit more channels onto a physical wire, which also limited them to 4 kHz.

Today, 64 kbps gets you much farther using a modern codec like Opus. WhatsApp sounds better than any landline or native mobile phone connection I've ever used in my life.

> (or centralized chat servers e.g. whatsapp) trying to save some data/money

WhatsApp uses P2P for (non-group) calls if at all possible.

There's also a "save data for calls" option in the settings which is off by default.

Modern codecs are so good, adding even more data would literally not make any discernible difference. A sizable fraction of all data transmitted/received by modern VoIP is IP and UDP framing overhead.

1 comments

Mobile connections are often especially crap, using something much lower bit rate than G.711 µlaw. Even modern landlines use voice activity detection and comfort noise generation instead of just passing through the background sounds.

I've never used WhatsApp to call. I have used decent SIP connections with G.722 Wideband or OPUS. They sound better than the old landlines. Discord sounds better too. Signal, much worse.

I think often the problem is that cell phones really have crappy speaker and microphone placement for calls, as basically nobody actually makes calls on them anymore.

These days, unless you're on 2G or 3G (if they're even still available in your country), mobile phones will often use AMR-WB or EVS when calling over IMS (i.e. VoIP over LTE or 5G), which are both wideband and considerably better than G.711 (and probably even G.722; while they have lower bitrates, they're also considerably more modern).

The problem is that when calling across networks, the connection might still go over a legacy circuit-switched exchange, and that compresses everything down to narrowband again.

I hope that whoever regulates the PSTN in the US will force a switch to all-IP interconnects at some point, since now we get the worst of both worlds (often somewhat lower reliability due to badly managed VoIP services, combined with potato quality because of a legacy interconnect somewhere between VoIP networks).

All IP could also provide much more efficient routing: Right now, as I understand it, if you're calling somebody with a 212 area code and both you and the callee are physically in San Francisco, your connection might still be routed through some circuit-switched exchange in Manhattan, which isn't great for latency or high availability.