WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
303790
AudioBufferSourceNode's start()'s duration broken with loop=true
https://bugs.webkit.org/show_bug.cgi?id=303790
Summary
AudioBufferSourceNode's start()'s duration broken with loop=true
Kaiido
Reported
2025-12-08 17:13:33 PST
1. Open
https://jsfiddle.net/ftwyoxh2/
2. Click the "start test" button. 3. Listen to how many beeps you hear (expected is 3) The test case is made of a looping `AudioBufferSourceNode`, pointing to a 6s `AudioBuffer` of an audio count-down where each second a new beep is heard. We set the source's `playbackRate` to `2` and start it by calling `start(0, 0, 3)`. Since
https://github.com/WebAudio/web-audio-api/pull/1681
it is specced that the `duration` param is supposed to be independent of the `playbackRate`, and that it should represent the time of the source data, not the time of the `AudioContext`, whether the source node loops or not. This works well for non-looping sources, but when `loop` is set to `true`, the duration falls back to represent the time relative to the `AudioContext` clock. This works as expected in Firefox. Chrome has the same issue:
https://issues.chromium.org/issues/467103139
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2025-12-09 13:02:52 PST
<
rdar://problem/166168368
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug