Feat/rnaa 243 pannernode - #1227
Conversation
|
|
||
| ### Not yet implemented ❌ | ||
| `AudioSinkInfo`, `AudioWorklet`, `AudioWorkletGlobalScope`, `AudioWorkletNode`, `AudioWorkletProcessor`, `DynamicsCompressorNode`, `MediaStreamAudioDestinationNode`, `MediaStreamAudioSourceNode`, `PannerNode` | ||
| `AudioSinkInfo`, `AudioWorklet`, `AudioWorkletGlobalScope`, `AudioWorkletNode`, `AudioWorkletProcessor`, `DynamicsCompressorNode`, `MediaStreamAudioDestinationNode`, `MediaStreamAudioSourceNode` |
There was a problem hiding this comment.
Isn't AudioWorklet and AudioWorkletNode implemented?
There was a problem hiding this comment.
similar behavior, different interface, so for now no, will need to decide how to approach that in the future if we would like to merge the interface or split it between web and native
WPT non-regression comparisonPASS — no regressions · 3 improved section(s) · overall 2589 → 3227 (+638)
Unchanged sections (25)
Baseline: Workflow run · this comment is updated on every push. |
mdydek
left a comment
There was a problem hiding this comment.
run wpt tests for panner node and try to bring the pass rate as high as you can
|
|
||
| ### Not yet implemented ❌ | ||
| `AudioSinkInfo`, `AudioWorklet`, `AudioWorkletGlobalScope`, `AudioWorkletNode`, `AudioWorkletProcessor`, `DynamicsCompressorNode`, `MediaStreamAudioDestinationNode`, `MediaStreamAudioSourceNode`, `PannerNode` | ||
| `AudioSinkInfo`, `AudioWorklet`, `AudioWorkletGlobalScope`, `AudioWorkletNode`, `AudioWorkletProcessor`, `DynamicsCompressorNode`, `MediaStreamAudioDestinationNode`, `MediaStreamAudioSourceNode` |
There was a problem hiding this comment.
similar behavior, different interface, so for now no, will need to decide how to approach that in the future if we would like to merge the interface or split it between web and native
|
|
||
| # PannerNode | ||
|
|
||
| The [`PannerNode`](https://developer.mozilla.org/en-US/docs/Web/API/PannerNode) interface positions an audio source in 3D space relative to the context's [`AudioListener`](/docs/core/audio-listener). |
There was a problem hiding this comment.
let's stick to the convention in the docs, we do not mention mozilla docs as reference
| | AudioContext | 🚧 | Available props and methods: `baseLatency`, `outputLatency`, `close`, `suspend`, `resume` | | ||
| | BaseAudioContext | 🚧 | Available props and methods: `currentTime`, `destination`, `listener`, `sampleRate`, `state`, `decodeAudioData`, all create methods for available or partially implemented nodes | | ||
| | AudioListener | 🚧 | No effect until PannerNode. | | ||
| | AudioListener | ✅ | Used by PannerNode for 3D spatialization, in the equal-power model. | |
There was a problem hiding this comment.
move it to the green ticks section
| | MediaStreamAudioDestinationNode | ❌ | | ||
| | MediaStreamAudioSourceNode | ❌ | | ||
| | PannerNode | ❌ | | ||
| | PannerNode | 🚧 | Equal-power spatialization, distance models, and cone gain are implemented. `'HRTF'` throws `NotSupportedError` on native (supported on web via the browser). | |
| std::shared_ptr<AudioParam> upYParam_; | ||
| std::shared_ptr<AudioParam> upZParam_; | ||
|
|
||
| std::optional<std::size_t> lastProcessedSampleFrame_; |
There was a problem hiding this comment.
| std::optional<std::size_t> lastProcessedSampleFrame_; | |
| std::optional<size_t> lastProcessedSampleFrame_; |
| #include <audioapi/core/types/OscillatorType.h> | ||
| #include <audioapi/core/types/OverSampleType.h> | ||
| #include <audioapi/events/AudioEvent.h> | ||
| #include <audioapi/types/NodeOptions.h> |
There was a problem hiding this comment.
move the panner types to the different file so we do not include huge file just for two oneline enums
Closes the first part of rnaa-243: the equal-power model. HRTF to come in the next PR.
Closes #
Introduced changes
PannerNodein the equal-power mode, with the geometric logic inPannerSpatialization.PannerTestandPannerSpatializationTest.Checklist