Closed
Bug 1025864
Opened 11 years ago
Closed 7 years ago
Node parameters in the inspector are not updated often enough
Categories
(DevTools Graveyard :: Web Audio Editor, defect)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: sole, Unassigned)
References
Details
Attachments
(1 file, 5 obsolete files)
38.19 KB,
patch
|
jsantell
:
review+
|
Details | Diff | Splinter Review |
It might be interesting to implement some sort of "Observe" in nodes to keep track of actual parameter values when a given node is being inspected.
Currently when a node is being inspected its values are "static" so if they are changed via code they are not updated in the inspector until the node is clicked again (which I guess prompts a refresh on the properties inspector)
Suppose I am inspecting an oscillator and its frequency is 440.
If I then go to the console and change its frequency to 220 the value will transition to that and the effects will be audible, but the inspector will still show 440.
Only if I click again over the node I'll get the new value 220.
Comment 1•11 years ago
|
||
Ah good idea, one of the reasons for moving to only being able to see one node at a time was this -- this should be relatively straight forward!
Updated•11 years ago
|
Assignee: nobody → jsantell
Comment 2•11 years ago
|
||
After playing with this for a bit, the call-watcher instrumentation won't work for AudioParam (and escalated properties like `frequency`) and implementing an instrumenter in audionodeactors won't work as these don't have built in setters, unless we proxy the entire object, which sounds scary. Still thinking about possible solutions that don't have unintended side effects
Comment 3•11 years ago
|
||
Some progress I've made.
Since AudioParams can be changed via automation, a setter would not capture these values, and observer/proxies would be too cludgey to continue to support things like automation as well, so the only other option (AFAICT) is polling.
This provides AudioNodeActor methods to decide whether or not we should be polling on the server for changes, emitting to the actor fronts. The devtool GUI turns on polling for the active nodes, and turns the previously selected node off, so we're only polling for the node of interest (on the server, minimizing RDP/x-boundary calls), and emitting to the front if a change was detected.
Problem with this currently is this fails for GC (only in e10s), when we have a node selected (so polling is on), this node will never get GC'd, due to accessing the underlying audio node's WeakRef in any capacity, within a timer.
Comment 4•11 years ago
|
||
This got larger than expected. Lots of edge cases to test. Polling most performant option. Had to do some magic to have it work in e10s.
Attachment #8468099 -
Attachment is obsolete: true
Attachment #8469664 -
Flags: review?(vporof)
Comment 5•11 years ago
|
||
Comment 6•11 years ago
|
||
Fixed the nullifying protocol.js Option issue, r?ing dcamp as well
Attachment #8469664 -
Attachment is obsolete: true
Attachment #8469664 -
Flags: review?(vporof)
Attachment #8470997 -
Flags: review?(vporof)
Attachment #8470997 -
Flags: review?(dcamp)
Comment 7•11 years ago
|
||
Comment 8•11 years ago
|
||
Comment on attachment 8470997 [details] [diff] [review]
1025864-observe-audioparams.patch
Review of attachment 8470997 [details] [diff] [review]:
-----------------------------------------------------------------
::: toolkit/devtools/server/protocol.js
@@ +447,5 @@
> Arg.prototype.initialize.call(this, index, type)
> },
>
> write: function(arg, ctx, name) {
> + let v = arg[name];
Will this generate an exception if arg is actually undefined? It's usually ok to not provide an options object at all.
Comment 9•11 years ago
|
||
Yup, you are right -- I jumped the gun. Should be fixed here.
Attachment #8470997 -
Attachment is obsolete: true
Attachment #8470997 -
Flags: review?(vporof)
Attachment #8470997 -
Flags: review?(dcamp)
Attachment #8471016 -
Flags: review?(vporof)
Attachment #8471016 -
Flags: review?(dcamp)
Comment 10•11 years ago
|
||
Comment on attachment 8471016 [details] [diff] [review]
1025864-observe-audioparams.patch
Review of attachment 8471016 [details] [diff] [review]:
-----------------------------------------------------------------
r+ for protocol.js change.
Attachment #8471016 -
Flags: review?(dcamp) → review+
Comment 11•11 years ago
|
||
Comment 12•11 years ago
|
||
handling protocol.js changes in bug 1052118
Comment 13•11 years ago
|
||
Removed protocol.js changes here
Attachment #8471016 -
Attachment is obsolete: true
Attachment #8471016 -
Flags: review?(vporof)
Attachment #8471198 -
Flags: review?(vporof)
Comment 14•11 years ago
|
||
Try, now with protocol changes landed in m-c https://tbpl.mozilla.org/?tree=Try&rev=ca469d95440d
Comment 15•11 years ago
|
||
Comment 16•11 years ago
|
||
Try up and running: https://tbpl.mozilla.org/?tree=Try&rev=4fc314f9b661
Comment 17•11 years ago
|
||
Comment on attachment 8471198 [details] [diff] [review]
1025864-observe-audioparams.patch
Review of attachment 8471198 [details] [diff] [review]:
-----------------------------------------------------------------
Lot of code to digest, but pretty.
::: toolkit/devtools/server/actors/webaudio.js
@@ +263,5 @@
> }, {
> response: { params: RetVal("json") }
> + }),
> +
> + isAlive: function () {
Nit: maybe comment this function? When is this dead? (I know, GC, CC etc., but readers of this code may be confused).
Attachment #8471198 -
Flags: review?(vporof) → review+
Comment 18•11 years ago
|
||
new try to fix bug 1035820: https://tbpl.mozilla.org/?tree=Try&rev=745f83ec7ca0
Comment 19•11 years ago
|
||
i am a bad fixer https://tbpl.mozilla.org/?tree=Try&rev=a769e9499acc
Comment 20•11 years ago
|
||
Attachment #8471198 -
Attachment is obsolete: true
Attachment #8475240 -
Flags: review+
Updated•11 years ago
|
Keywords: checkin-needed
Comment 21•11 years ago
|
||
Comment 22•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 34
Comment 23•11 years ago
|
||
Backed out for causing bug 1035820 with no end in sight.
https://hg.mozilla.org/integration/fx-team/rev/10346f72cdcb
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Target Milestone: Firefox 34 → ---
Comment 24•11 years ago
|
||
Merge of backout:
https://hg.mozilla.org/mozilla-central/rev/10346f72cdcb
Updated•11 years ago
|
Updated•10 years ago
|
Assignee: jsantell → nobody
Comment 25•7 years ago
|
||
Mass-closing inactive (2 years+) bugs on unmaintained devtools components.
Status: REOPENED → RESOLVED
Closed: 11 years ago → 7 years ago
Resolution: --- → WONTFIX
Updated•7 years ago
|
Product: Firefox → DevTools
Updated•6 years ago
|
Product: DevTools → DevTools Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•