diff --git a/CHANGELOG.md b/CHANGELOG.md index 2899389..9eb785d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Unreleased +# Version 0.9.0 (2019-06-06) + +- Better buffer handling +- Fix logic error in frame/sample size +- Added error handling for unknown ALSA device errors - Fix resuming a paused stream on Windows (wasapi). - Implement `default_output_format` for emscripten backend. diff --git a/Cargo.toml b/Cargo.toml index 4a91a4f..0b9dfc6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "cpal" -version = "0.8.2" +version = "0.9.0" authors = ["The CPAL contributors", "Pierre Krieger "] description = "Low-level cross-platform audio playing library in pure Rust." repository = "https://github.com/tomaka/cpal" @@ -9,10 +9,10 @@ license = "Apache-2.0" keywords = ["audio", "sound"] [dependencies] -lazy_static = "1.0" +lazy_static = "1.3" [dev-dependencies] -hound = "3.0" +hound = "3.4" [target.'cfg(target_os = "windows")'.dependencies] winapi = { version = "0.3", features = ["audiosessiontypes", "audioclient", "coml2api", "combaseapi", "debug", "devpkey", "handleapi", "ksmedia", "mmdeviceapi", "objbase", "std", "synchapi", "winuser"] } diff --git a/src/wasapi/device.rs b/src/wasapi/device.rs index 3ba7dd2..9913f2a 100644 --- a/src/wasapi/device.rs +++ b/src/wasapi/device.rs @@ -234,7 +234,7 @@ pub unsafe fn is_format_supported( match (*waveformatex_ptr).wFormatTag { mmreg::WAVE_FORMAT_PCM | mmreg::WAVE_FORMAT_IEEE_FLOAT => { let mut closest_waveformatex = *waveformatex_ptr; - let mut closest_waveformatex_ptr = &mut closest_waveformatex as *mut _; + let closest_waveformatex_ptr = &mut closest_waveformatex as *mut _; is_supported(waveformatex_ptr, closest_waveformatex_ptr) }, mmreg::WAVE_FORMAT_EXTENSIBLE => { @@ -243,7 +243,7 @@ pub unsafe fn is_format_supported( let mut closest_waveformatextensible = *waveformatextensible_ptr; let closest_waveformatextensible_ptr = &mut closest_waveformatextensible as *mut _; - let mut closest_waveformatex_ptr = + let closest_waveformatex_ptr = closest_waveformatextensible_ptr as *mut mmreg::WAVEFORMATEX; is_supported(waveformatex_ptr, closest_waveformatex_ptr) }, diff --git a/src/wasapi/stream.rs b/src/wasapi/stream.rs index a6564ca..0442008 100644 --- a/src/wasapi/stream.rs +++ b/src/wasapi/stream.rs @@ -12,7 +12,6 @@ use super::winapi::um::synchapi; use super::winapi::um::winbase; use super::winapi::um::winnt; -use std::marker::PhantomData; use std::mem; use std::ptr; use std::slice;