GoogleChromeLabs / audioworklet-polyfill

🔊 Polyfill AudioWorklet using the legacy ScriptProcessor API.
https://googlechromelabs.github.io/audioworklet-polyfill/
Apache License 2.0
196 stars 20 forks source link

'currentTime' and 'sampleRate' remain 0 in simulated AudioWorkletGlobalScope #7

Closed JohnWeisz closed 6 years ago

JohnWeisz commented 6 years ago

These lines don't do anything, because the fake AudioContext properties are copied into global scope once on initialization.

developit commented 6 years ago

Ah - good catch, I should have exempted them to avoid that shadowing.

developit commented 6 years ago

Thanks John - it looks like I'd only tested property access, which was working (self.currentTime, old lint habits). This issue is now fixed in 1.1.0.