element-hq / element-ios

A glossy Matrix collaboration client for iOS
https://element.io
GNU Affero General Public License v3.0
1.73k stars 492 forks source link

Stereo opus files sound glitchy when playing back. #6603

Open pixlwave opened 2 years ago

pixlwave commented 2 years ago

Steps to reproduce

  1. Upload one of the sample files from https://filesamples.com/formats/opus to a room from web.
  2. Open the room on iOS
  3. Play the file back.

Outcome

What did you expect?

The file to sound the same as it does on desktop.

What happened instead?

It sounds very glitchy and reports as being twice the length it should be.

It looks like the SwiftOGG package is forcing kAudioChannelLayoutTag_Mono instead of reading this from the file.

Your phone model

iPhone 12

Operating system version

iOS 15.6.1

Application version

1.8.27

Homeserver

No response

Will you send logs?

No

langleyd commented 2 years ago

Tried a bunch of things to fix this including playing with channels and interleaving. Haven't found something that addresses the crackling.