Replace assert in WASAPI WAVEFORMTEX supported format check with bubbled error message.
For our use case, this stops a crash that pops up for some users who encounter this path and allows us to gracefully just not play audio and log a message elsewhere.
when main(or other) thread(s) try to drop the Stream object, they would panic at host/wasapi/stream.rs Stream::drop() if the wasapi thread is dead. this occurs when the user wants to do something after all the cpal objects have been dropped.
Fixes#721
Changes to a dependency library broke compilation of the example. Changes needed to get the example working and warning-free include:
1. specifying additional type constraints in local implementations
2. using the `FromSample` trait to convert samples in the handler
3. adding a default matcher in response to the non-exhaustive attribute on `SampleFormat`
Also adds a github action to ensure the wasm-beep example compiles.
* Add rustdoc links in most of the documentation
Additionally, fix a couple of references to old
renamed types still lingering in the docs :)
Fixes#650
* Rustfmt on documentation changes
* Make docs for impl_platform_host not build example
* bump linux dependencies, dev-dependencies, anyhow, hound, ringbuf
* update to clap v4 and simplify examples with clap_derive
* have libjack installed when running with --all-features
* don't force the patch version for libc
* allow room for version resolution with nix
* nix dependency not used anymore, remove it
* add timeout paramter to DeviceTrait stream builders
This makes it possible for the library client to handle situations where the host
takes too long to respond or even blocks forever, eg. a retry can be applied.
if the timeout passed is "None" the current behaviour is applied, eg. blocking forever.
if the timeout passed is a Duration then it will be applied to the Device Streams.
This is only implemented for ALSA, the other hosts will ignore the parameter for now.
Signed-off-by: Marc Bodmer <marc.bodmer@securiton.ch>