Respect Opus fmtp parameter maxplaybackrate

NEW
Unassigned

Status

()

P5
normal
Rank:
45
4 years ago
7 months ago

People

(Reporter: derf, Unassigned)

Tracking

(Blocks: 1 bug, {parity-chrome})

Trunk
x86_64
Linux
parity-chrome
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

4 years ago
For sendonly or sendrecv Opus streams, we should respect the value of maxplaybackrate provided by the other side.

This is a request to us not to encode audio with a sampling rate higher than the given playback rate, since the receiver will not use it, and the bandwidth we spend on it will be wasted.

We should get the GIPS code to call opus_encoder_ctl(...,OPUS_SET_MAX_BANDIWDTH(x)) on its encoder based on the value of maxplaybackrate:

maxplaybackrate <= 8000:  x = OPUS_BANDWIDTH_NARROWBAND
maxplaybackrate <= 12000: x = OPUS_BANDWIDTH_MEDIUMBAND
maxplaybackrate <= 16000: x = OPUS_BANDWIDTH_WIDEBAND
maxplaybackrate <= 24000: x = OPUS_BANDWIDTH_SUPERWIDEBAND
maxplaybackrate > 24000:  x = OPUS_BANDWIDTH_FULLBAND

This may require some plumbing to get the information on the bandwidth the receiver wants to the GIPS encoder. I know the GIPS folks planned to implement that plumbing so Chrome could also respect these parameters, but I have lost track of the status of that work. It may already be done. We may have to do it ourselves.
(Reporter)

Comment 1

4 years ago
Looks like it is in progress: <https://webrtc-codereview.appspot.com/13099004/>.
We'll need SDP, and we'll need to cherry-pick the patch for webrtc/trunk or wait for it to be in a stable branch we import.  Derf: any reason to cherry-pick?  I'm guessing not...
Flags: needinfo?(tterribe)
(Reporter)

Comment 4

4 years ago
I don't see a problem with waiting for the next import.
Flags: needinfo?(tterribe)
backlog: --- → webRTC+
Rank: 45
Priority: -- → P4
Mass change P4->P5 to align with new Mozilla triage process.
Priority: P4 → P5
Mass bug change to replace various 'parity' whiteboard flags with the new canonical keywords. (See bug 1443764 comment 13.)
Keywords: parity-chrome
Whiteboard: [parity-chrome]
You need to log in before you can comment on or make changes to this bug.