Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upAdd AudioListener/AudioPanner DOM interfaces #21502
Conversation
highfive
commented
Aug 23, 2018
|
Heads up! This PR modifies the following files:
|
highfive
commented
Aug 23, 2018
35b8104
to
9a52aac
|
Tested, the following example works: <script type="text/javascript">
let ctx = new AudioContext();
let osc = ctx.createOscillator();
let panner = new PannerNode(ctx, {"coneOuterAngle": 0, "positionX": 100, "positionY": 0, "positionZ": 100, "refDistance": 100, "rolloffFactor": 0.01});
osc.connect(panner);
panner.connect(ctx.destination);
osc.start();
panner.positionX.linearRampToValueAtTime(-100, 0.2);
panner.positionX.linearRampToValueAtTime(100, 0.2);
panner.positionX.linearRampToValueAtTime(-100, 0.4);
panner.positionX.linearRampToValueAtTime(-100, 0.4);
panner.positionX.linearRampToValueAtTime(100, 0.6);
panner.positionX.linearRampToValueAtTime(-100, 0.6);
panner.positionX.linearRampToValueAtTime(100, 0.8);
panner.positionX.linearRampToValueAtTime(100, 0.8);
panner.positionX.linearRampToValueAtTime(-100, 1.0);
panner.positionX.linearRampToValueAtTime(100, 1.0);
panner.positionX.linearRampToValueAtTime(-100, 1.2);
panner.positionX.linearRampToValueAtTime(-100, 1.2);
panner.positionX.linearRampToValueAtTime(100, 1.4);
panner.positionX.linearRampToValueAtTime(-100, 1.4);
panner.positionX.linearRampToValueAtTime(100, 1.6);
panner.positionX.linearRampToValueAtTime(100, 1.6);
</script>(should I check this in to tests/html?) |
|
@bors-servo try=wpt |
Add AudioListener/AudioPanner DOM interfaces Seems to work. I'll need some changes to the servo-media side to support the panner node getters as well as the older `setPosition()`/etc APIs. I'll get to those later. r? @ferjm <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21502) <!-- Reviewable:end -->
|
|
|
Looks good! We need to add the channelCount and channelCountMode constraints for Likewise, even though we do not support HRTF yet, we should also add the Thanks! |
| window, | ||
| context, | ||
| node, | ||
| ParamType::Position(ParamDir::Y), |
This comment has been minimized.
This comment has been minimized.
| window, | ||
| context, | ||
| node, | ||
| ParamType::Forward(ParamDir::Y), |
This comment has been minimized.
This comment has been minimized.
| window, | ||
| context, | ||
| node, | ||
| ParamType::Up(ParamDir::Y), |
This comment has been minimized.
This comment has been minimized.
| @@ -297,6 +304,15 @@ impl BaseAudioContextMethods for BaseAudioContext { | |||
| }) | |||
| } | |||
|
|
|||
| /// https://webaudio.github.io/web-audio-api/#dom-baseaudiocontext-destination | |||
This comment has been minimized.
This comment has been minimized.
ferjm
Aug 24, 2018
Member
Change link to https://webaudio.github.io/web-audio-api/#dom-baseaudiocontext-listener, please
|
We don't have autiomationrate constraints, the automationrate is simply ignored (this code already exists in the media crate) |
|
@bors-servo try=wpt |
Add AudioListener/AudioPanner DOM interfaces Seems to work. I'll need some changes to the servo-media side to support the panner node getters as well as the older `setPosition()`/etc APIs. I'll get to those later. r? @ferjm <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21502) <!-- Reviewable:end -->
|
This should cause a bunch of new WPT failures since previously some tests didn't fully run at all, but that's okay. At some point we need to switch gears to WPT and whittle those down, most of them aren't much work. |
|
|
|
@bors-servo r=ferjm |
|
|
Add AudioListener/AudioPanner DOM interfaces Seems to work. I'll need some changes to the servo-media side to support the panner node getters as well as the older `setPosition()`/etc APIs. I'll get to those later. r? @ferjm <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21502) <!-- Reviewable:end -->
|
|
|
@bors-servo r=ferjm
|
|
|
Add AudioListener/AudioPanner DOM interfaces Seems to work. I'll need some changes to the servo-media side to support the panner node getters as well as the older `setPosition()`/etc APIs. I'll get to those later. r? @ferjm <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21502) <!-- Reviewable:end -->
|
|
|
@bors-servo retry
seems intermittent, let's find out |
|
|
|
|
Manishearth commentedAug 23, 2018
•
edited by SimonSapin
Seems to work.
I'll need some changes to the servo-media side to support the panner
node getters as well as the older
setPosition()/etc APIs. I'll get tothose later.
r? @ferjm
This change is