Bug 234458

Summary: Don't pack audio samples with discontinuity together
Product: WebKit Reporter: Jean-Yves Avenard [:jya] <jean-yves.avenard>
Component: MediaAssignee: Jean-Yves Avenard [:jya] <jean-yves.avenard>
Status: RESOLVED FIXED    
Severity: Normal CC: eric.carlson, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
jean-yves.avenard: commit-queue+
Patch ews-feeder: commit-queue-

Description Jean-Yves Avenard [:jya] 2021-12-17 19:14:28 PST
When playing https://jyavenard.github.io/htmltests/tests/mse_webm/83910012/ at 2s we can hear a "chtook" kind of sound.

This stream has a 1ms discontinuity after the first opus packet (20ms), as 2s worth of samples are packed together that discontinuity can be heard at the 2s block boundary.

We shouldn't pack samples together if there's a discontinuity between them so that timestamps stay correct.
Comment 1 Radar WebKit Bug Importer 2021-12-17 19:14:48 PST
<rdar://problem/86659914>
Comment 2 Jean-Yves Avenard [:jya] 2021-12-17 19:38:45 PST
Created attachment 447505 [details]
Patch
Comment 3 Eric Carlson 2021-12-18 12:10:18 PST
Comment on attachment 447505 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=447505&action=review

> Source/WebCore/ChangeLog:18
> +        So w no longer pack samples with discontinuities so that the frame

s/So w/So we/

> Source/WebCore/ChangeLog:23
> +        in CoreMedia that insert very audible artifacts when there's a gap between

s/insert/inserts/
Comment 4 Jean-Yves Avenard [:jya] 2021-12-19 14:27:20 PST
Created attachment 447560 [details]
Patch

address comments
Comment 5 Jean-Yves Avenard [:jya] 2021-12-19 14:43:20 PST
Created attachment 447561 [details]
Patch

add reviewer name
Comment 6 EWS 2021-12-19 16:04:13 PST
Committed r287249 (245407@main): <https://commits.webkit.org/245407@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 447561 [details].