Bug 218265

Summary: AudioBuffer.getChannelData(x) should keep returning the same JS wrapper for a given channel
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: Web AudioAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, darin, eric.carlson, esprehn+autocc, ews-watchlist, ggaren, glenn, jer.noble, kondapallykalyan, philipj, sam, sergio, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 212611, 218286    
Attachments:
Description Flags
Patch
ews-feeder: commit-queue-
Patch
none
Patch
none
Patch
none
Patch none

Description Chris Dumez 2020-10-27 15:42:23 PDT
AudioBuffer.getChannelData(x) should keep returning the same JS wrapper for a given channel. This is the behavior of Blink / Gecko and is covered by Web-Platform-Tests.
Comment 1 Chris Dumez 2020-10-27 15:44:40 PDT
Created attachment 412469 [details]
Patch
Comment 2 Chris Dumez 2020-10-27 15:46:00 PDT
Comment on attachment 412469 [details]
Patch

Build errors.
Comment 3 Chris Dumez 2020-10-27 15:47:13 PDT
Created attachment 412470 [details]
Patch
Comment 4 Chris Dumez 2020-10-27 15:59:27 PDT
Created attachment 412473 [details]
Patch
Comment 5 Geoffrey Garen 2020-10-27 16:13:20 PDT
Comment on attachment 412473 [details]
Patch

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

r=me

> Source/WebCore/Modules/webaudio/AudioBuffer.cpp:156
> +void AudioBuffer::visitChannelsWrappers(JSC::SlotVisitor& visitor)

Also visitChannelWrappers

> Source/WebCore/Modules/webaudio/AudioBuffer.h:82
> +    Vector<JSValueInWrappedObject> m_channelsWrappers;

I would call this m_channelWrappers. Each wrapper wraps one channel.
Comment 6 Chris Dumez 2020-10-27 16:24:40 PDT
Created attachment 412475 [details]
Patch
Comment 7 EWS 2020-10-27 16:25:47 PDT
Geoff Garren found in /Volumes/Data/worker/Commit-Queue/build/Source/WebCore/ChangeLog does not appear to be a valid reviewer according to contributors.json.
/Volumes/Data/worker/Commit-Queue/build/Source/WebCore/ChangeLog neither lists a valid reviewer nor contains the string "Unreviewed" or "Rubber stamp" (case insensitive).
Comment 8 Chris Dumez 2020-10-27 16:27:19 PDT
Created attachment 412476 [details]
Patch
Comment 9 EWS 2020-10-27 17:06:08 PDT
Committed r269081: <https://trac.webkit.org/changeset/269081>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 412476 [details].
Comment 10 Radar WebKit Bug Importer 2020-10-27 17:09:51 PDT
<rdar://problem/70745174>