Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • gst-plugins-base gst-plugins-base
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 642
    • Issues 642
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 80
    • Merge requests 80
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GStreamerGStreamer
  • gst-plugins-basegst-plugins-base
  • Issues
  • #409
Closed
Open
Issue created Dec 19, 2017 by Bugzilla Migration User@bugzilla-migration

opusenc, opusdec: add option to disable phase inversion

Submitted by Hector Martin

Link to original bug (#791771)

Description

http://opus-codec.org/docs/opus_api-1.2/group__opus__genericctls.html#ga10fa1f6eab136baf83c232afa989b6a8

When downmixing stereo streams to mono, having phase inversion enabled produces terrible audio quality (it sounds like a low bitrate MP3), since frequency bands randomly cancel out. This should be exposed in the encoder (to produce bitstreams that always sound good when downmixed to mono, regardless of what the decoder does), and in the decoder (to allow any arbitrary bitstream to sound good when downmixed to mono, regardless of what the encoder did). On the decoder, additionally, it should probably default to disabled (i.e. OPUS_SET_PHASE_INVERSION_DISABLED(1)) when the output channel count is 1.

Here's a sample of just how bad decoding opus to mono without this enabled sounds: https://mrcn.st/t/opus_decoding_test.ogg . This is 6 seconds of stereo decoding, 3 seconds of mono decoding, repeatedly. The input bitstream is the same in both cases, with phase inversion enabled, as is the case right now in gstreamer. It gets really bad at 0:50 or so.

See also: https://tools.ietf.org/html/rfc8251#section-10

Assignee
Assign to
Time tracking