| Summary: | [WebAudio/WebM] Incorrect number of frames returned if decoding frame rate doesn't match original | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Jean-Yves Avenard [:jya] <jean-yves.avenard> | ||||||
| Component: | Web Audio | Assignee: | Jean-Yves Avenard [:jya] <jean-yves.avenard> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | cdumez, eric.carlson, ews-watchlist, glenn, jer.noble, philipj, sergio, webkit-bug-importer | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | Other | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Bug Depends on: | |||||||||
| Bug Blocks: | 227111 | ||||||||
| Attachments: |
|
||||||||
|
Description
Jean-Yves Avenard [:jya]
2021-08-18 14:56:04 PDT
Created attachment 437617 [details]
Patch
Comment on attachment 437617 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=437617&action=review > Source/WebCore/platform/audio/cocoa/AudioFileReaderCocoa.cpp:339 > + uint32_t leadingTrim = m_webmData->m_track->codecDelay().value_or(MediaTime()).toDouble() * outFormat.mSampleRate; `MediaTime::zeroTime()` should be cheaper than `MediaTime()` > Source/WebCore/platform/audio/cocoa/AudioFileReaderCocoa.cpp:341 > + uint32_t trailingTrim = (m_webmData->m_track->codecDelay().value_or(MediaTime()) + m_webmData->m_track->discardPadding().value_or(MediaTime())).toDouble() * outFormat.mSampleRate - leadingTrim + 0.5; Ditto Created attachment 437698 [details]
Patch
Committed r282196 (241483@main): <https://commits.webkit.org/241483@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 437698 [details]. |