WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 97050
Add Web Audio support for deprecated/legacy APIs
https://bugs.webkit.org/show_bug.cgi?id=97050
Summary
Add Web Audio support for deprecated/legacy APIs
Chris Rogers
Reported
2012-09-18 15:24:23 PDT
Add Web Audio support for deprecated/legacy APIs
Attachments
Patch
(34.86 KB, patch)
2012-09-18 15:31 PDT
,
Chris Rogers
no flags
Details
Formatted Diff
Diff
GTK build fix
(2.10 KB, patch)
2012-09-19 00:21 PDT
,
Philippe Normand
no flags
Details
Formatted Diff
Diff
Patch
(34.95 KB, patch)
2012-09-20 16:43 PDT
,
Chris Rogers
no flags
Details
Formatted Diff
Diff
Patch
(35.15 KB, patch)
2012-09-20 17:12 PDT
,
Chris Rogers
no flags
Details
Formatted Diff
Diff
Patch
(38.62 KB, patch)
2012-09-21 13:15 PDT
,
Chris Rogers
eric.carlson
: review+
Details
Formatted Diff
Diff
Show Obsolete
(4)
View All
Add attachment
proposed patch, testcase, etc.
Chris Rogers
Comment 1
2012-09-18 15:31:33 PDT
Created
attachment 164630
[details]
Patch
kov's GTK+ EWS bot
Comment 2
2012-09-18 15:37:48 PDT
Comment on
attachment 164630
[details]
Patch
Attachment 164630
[details]
did not pass gtk-ews (gtk): Output:
http://queues.webkit.org/results/13892338
Philippe Normand
Comment 3
2012-09-18 23:19:25 PDT
I'll have a look at the GTK failure.
Adam Barth
Comment 4
2012-09-18 23:27:28 PDT
Comment on
attachment 164630
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=164630&action=review
Any chance of renaming JavaScriptAudioNode to ScriptAudioNode / createJavaScriptNode to createScriptNode ?
> Source/WebCore/Modules/webaudio/Oscillator.idl:59 > +#if defined(ENABLE_LEGACY_WEB_AUDIO) && ENABLE_LEGACY_WEB_AUDIO > void noteOn(in double when); > void noteOff(in double when); > +#endif
Do you want to add a V8MeasureAs IDL attribute to measure how often these old APIs are used? See
http://lists.webkit.org/pipermail/webkit-dev/2012-September/022239.html
Chris Rogers
Comment 5
2012-09-18 23:45:48 PDT
Adam, thanks for having such a quick look: (In reply to
comment #4
)
> (From update of
attachment 164630
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=164630&action=review
> > Any chance of renaming JavaScriptAudioNode to ScriptAudioNode / createJavaScriptNode to createScriptNode ?
Yes, there is a good chance now with this deprecation path.
> > > Source/WebCore/Modules/webaudio/Oscillator.idl:59 > > +#if defined(ENABLE_LEGACY_WEB_AUDIO) && ENABLE_LEGACY_WEB_AUDIO > > void noteOn(in double when); > > void noteOff(in double when); > > +#endif > > Do you want to add a V8MeasureAs IDL attribute to measure how often these old APIs are used? See
http://lists.webkit.org/pipermail/webkit-dev/2012-September/022239.html
I think we already know the answer: noteOn()/noteOff() are effectively always going to be used, So this would add little value.
Philippe Normand
Comment 6
2012-09-19 00:21:36 PDT
Created
attachment 164676
[details]
GTK build fix
Philippe Normand
Comment 7
2012-09-19 00:22:22 PDT
+Zan in CC because he works on the GTK build system these days.
Zan Dobersek
Comment 8
2012-09-19 05:00:54 PDT
Comment on
attachment 164676
[details]
GTK build fix View in context:
https://bugs.webkit.org/attachment.cgi?id=164676&action=review
> configure.ac:714 > +AC_MSG_CHECKING([whether to enable legacy Web Audio support])
I'd say the configuration option isn't required. The feature define seems to be enabled by default, so I'd say add it to GNUmakefile.features.am (as done in this patch) and override it with 0 value in GNUmakefile.am if Web Audio is not enabled. I can upload that patch after we get to consensus on whether the configuration option should be present or not.
Philippe Normand
Comment 9
2012-09-19 05:38:06 PDT
Comment on
attachment 164676
[details]
GTK build fix View in context:
https://bugs.webkit.org/attachment.cgi?id=164676&action=review
>> configure.ac:714 >> +AC_MSG_CHECKING([whether to enable legacy Web Audio support]) > > I'd say the configuration option isn't required. The feature define seems to be enabled by default, so I'd say add it to GNUmakefile.features.am (as done in this patch) and override it with 0 value in GNUmakefile.am if Web Audio is not enabled. I can upload that patch after we get to consensus on whether the configuration option should be present or not.
Well it depends if we'll ever build with webaudio on and legacy off I guess. No strong opinion on the command line switch. About setting the define to 0 if webaudio is disabled I think it's not needed because the code in ENABLE_LEGACY_WEB_AUDIO is protected by ENABLE_WEB_AUDIO already.
Zan Dobersek
Comment 10
2012-09-19 06:11:02 PDT
Comment on
attachment 164676
[details]
GTK build fix View in context:
https://bugs.webkit.org/attachment.cgi?id=164676&action=review
>>> configure.ac:714 >>> +AC_MSG_CHECKING([whether to enable legacy Web Audio support]) >> >> I'd say the configuration option isn't required. The feature define seems to be enabled by default, so I'd say add it to GNUmakefile.features.am (as done in this patch) and override it with 0 value in GNUmakefile.am if Web Audio is not enabled. I can upload that patch after we get to consensus on whether the configuration option should be present or not. > > Well it depends if we'll ever build with webaudio on and legacy off I guess. No strong opinion on the command line switch. About setting the define to 0 if webaudio is disabled I think it's not needed because the code in ENABLE_LEGACY_WEB_AUDIO is protected by ENABLE_WEB_AUDIO already.
I'd then recommend not using the configuration option and having ENABLE_LEGACY_WEB_AUDIO default to 0. The issue should be revisited when Web Audio is enabled by default for the GTK port. I'd recommend overriding the feature define with 0 just for sanity and in case in the future there are changes made that are guarded by this define but not the ENABLE_WEB_AUDIO define.
Zan Dobersek
Comment 11
2012-09-19 06:24:05 PDT
(In reply to
comment #10
)
> > I'd recommend overriding the feature define with 0 just for sanity and in case in the future there are changes made that are guarded by this define but not the ENABLE_WEB_AUDIO define.
After looking at the patch more closely I believe the feature define should be enabled by default, but no configuration option is necessary. Basically, this means that the GTK port only requires Source/WebCore/GNUmakefile.features.am to be modified in the same way as Philippe had done it in
attachment #164676
[details]
.
Adam Barth
Comment 12
2012-09-19 11:49:14 PDT
> > (From update of
attachment 164630
[details]
[details]) > > View in context:
https://bugs.webkit.org/attachment.cgi?id=164630&action=review
> > > > > Source/WebCore/Modules/webaudio/Oscillator.idl:59 > > > +#if defined(ENABLE_LEGACY_WEB_AUDIO) && ENABLE_LEGACY_WEB_AUDIO > > > void noteOn(in double when); > > > void noteOff(in double when); > > > +#endif > > > > Do you want to add a V8MeasureAs IDL attribute to measure how often these old APIs are used? See
http://lists.webkit.org/pipermail/webkit-dev/2012-September/022239.html
> > I think we already know the answer: noteOn()/noteOff() are effectively always going to be used, So this would add little value.
Today, perhaps, but we'll eventually want to be able to delete these functions. To do that, won't we want to know when their usage drops below a certain level?
Chris Rogers
Comment 13
2012-09-20 16:43:17 PDT
Created
attachment 165011
[details]
Patch
Chris Rogers
Comment 14
2012-09-20 17:12:16 PDT
Created
attachment 165017
[details]
Patch
Chris Rogers
Comment 15
2012-09-20 18:29:43 PDT
abarth: I added V8MeasureAs I've simplified the GTK changes - did I get that part right?
Philippe Normand
Comment 16
2012-09-20 23:19:06 PDT
(In reply to
comment #15
)
> > I've simplified the GTK changes - did I get that part right?
Yes!
Adam Barth
Comment 17
2012-09-21 09:07:27 PDT
Comment on
attachment 165017
[details]
Patch V8MeasureAs part looks great!
Eric Carlson
Comment 18
2012-09-21 09:42:41 PDT
Comment on
attachment 165017
[details]
Patch What is the plan for updating tests? It seems like it would be a good idea to update at least a few now to verify the name changes.
Chris Rogers
Comment 19
2012-09-21 13:15:31 PDT
Created
attachment 165177
[details]
Patch
Chris Rogers
Comment 20
2012-09-21 13:16:50 PDT
(In reply to
comment #18
)
> (From update of
attachment 165017
[details]
) > What is the plan for updating tests? It seems like it would be a good idea to update at least a few now to verify the name changes.
Eric, good point. I updated a few of the tests to use the new names. I think fairly soon we should switch all of the tests to use the new names.
Eric Carlson
Comment 21
2012-09-21 13:22:13 PDT
Comment on
attachment 165177
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=165177&action=review
> Source/WebCore/ChangeLog:12 > + Reviewed by NOBODY (OOPS!). > + > + The Web Audio API specification has undergone much review and some small API changes > + have been made (mostly naming-related changes). This patch adds an ENABLE_LEGACY_WEB_AUDIO > + build option to allow ports to support the old names. > + > + * Configurations/FeatureDefines.xcconfig:
Please make a note of the tests you updated.
Chris Rogers
Comment 22
2012-09-21 15:12:20 PDT
Committed
r129260
: <
http://trac.webkit.org/changeset/129260
>
Pavel Podivilov
Comment 23
2012-09-25 08:44:50 PDT
Comment on
attachment 165177
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=165177&action=review
> Source/WebCore/Modules/webaudio/AudioBufferSourceNode.idl:48 > + [V8MeasureAs=WebAudioStart] [ImplementedAs=startGrain] void start(in double when, in double grainOffset, in double grainDuration);
It should be [V8MeasureAs=WebAudioStart, ImplementedAs=startGrain] according to web idl syntax. See
http://dev.w3.org/2006/webapi/WebIDL/#idl-extended-attributes
.
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