No devices on default host on WASM32, specifically Chromium
JohnDowson opened this issue · comments
I'm attempting to use cpal for a browser build of my sound synthesizer, but encountering an issue where cpal::default_host
has no output devices - host.devices()
iterator is empty.
host.id()
returns "WebAudio"
.
I want to note that I am trying to enumerate devices from a web worker used to emulate threads.
cpal 15.2
Chromium Version 118.0.5993.117 (Official Build) Arch Linux (64-bit)
Edit: still posting this for google-ability, but the issue is the web-worker. Moving to the main worker brings devices back, but results in issue #656 surfacing.
The workaround in #774 leads to another issue: waiting on a channel is not possible in the main worker, and so there isn't really a way to receive samples.