| Summary: | Add stubs for AudioWorkletProcessor and AudioWorkletGlobalScope | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||||||
| Component: | Web Audio | Assignee: | Chris Dumez <cdumez> | ||||||||
| Status: | RESOLVED FIXED | ||||||||||
| Severity: | Normal | CC: | alecflett, annulen, beidson, darin, eric.carlson, esprehn+autocc, ews-watchlist, ggaren, glenn, gyuyoung.kim, jer.noble, jsbell, kondapallykalyan, philipj, ryuan.choi, sam, sergio, webkit-bug-importer | ||||||||
| Priority: | P2 | Keywords: | InRadar | ||||||||
| Version: | WebKit Nightly Build | ||||||||||
| Hardware: | Unspecified | ||||||||||
| OS: | Unspecified | ||||||||||
| Bug Depends on: | 217153 | ||||||||||
| Bug Blocks: | 217058, 217242 | ||||||||||
| Attachments: |
|
||||||||||
|
Description
Chris Dumez
2020-10-01 16:07:05 PDT
Created attachment 410280 [details]
Patch
Created attachment 410296 [details]
Patch
Created attachment 410298 [details]
Patch
Comment on attachment 410298 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=410298&action=review What's the deal with all the extra "DOM"s added to the generated code? Name conflict? Can you add an explanation to the changelog? > Source/WebCore/Modules/webaudio/AudioWorkletGlobalScope.h:53 > + float sampleRate() const { return 44100; } This number should probably be in its own constexpr with a clear name to explain it (unless you expect this to go away real soon). > Source/WebCore/Modules/webaudio/AudioWorkletProcessorConstructor.idl:31 > +]callback AudioWorkletProcessorConstructor = AudioWorkletProcessor (object options); Please add a space after the closing ]. Comment on attachment 410298 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=410298&action=review >> Source/WebCore/Modules/webaudio/AudioWorkletGlobalScope.h:53 >> + float sampleRate() const { return 44100; } > > This number should probably be in its own constexpr with a clear name to explain it (unless you expect this to go away real soon). If they were going to stay like this for a long time we could use static constexpr. Comment on attachment 410298 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=410298&action=review >>> Source/WebCore/Modules/webaudio/AudioWorkletGlobalScope.h:53 >>> + float sampleRate() const { return 44100; } >> >> This number should probably be in its own constexpr with a clear name to explain it (unless you expect this to go away real soon). > > If they were going to stay like this for a long time we could use static constexpr. This is going to go away real soon to return the actual context sample rate. I could have returned 0 here but I figured I would return a realistic sample rate. (In reply to Sam Weinig from comment #4) > Comment on attachment 410298 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=410298&action=review > > What's the deal with all the extra "DOM"s added to the generated code? Name > conflict? Can you add an explanation to the changelog? Yes, there was a name conflict since we now have both JSAudioWorkletProcessor and JSAudioWorkletProcessorConstructor classes (Due to having AudioWorkletProcessor.idl and AudioWorkletProcessorConstructor.idl). The issue was that the DOMConstructor for JSAudioWorkletProcessor was named JSAudioWorkletProcessorConstructor too. So I renamed it to JSAudioWorkletProcessorDOMConstructor. > > > Source/WebCore/Modules/webaudio/AudioWorkletGlobalScope.h:53 > > + float sampleRate() const { return 44100; } > > This number should probably be in its own constexpr with a clear name to > explain it (unless you expect this to go away real soon). > > > Source/WebCore/Modules/webaudio/AudioWorkletProcessorConstructor.idl:31 > > +]callback AudioWorkletProcessorConstructor = AudioWorkletProcessor (object options); > > Please add a space after the closing ]. Will fix. Committed r267891: <https://trac.webkit.org/changeset/267891> |