[macos] Implement Endpoint and Format Enumeration

Based on #195.

Also implements proper handling of the given `Endpoint` in the
macos implementation of the `build_voice` method.

Updates to the latest coreaudio-sys and coreaudio-rs which include the
additional necessary frameworks.

Also adds a line that prints the name of the default device in the
`enumeration.rs` example.

Updates the CHANGELOG for this PR.

Closes #194.
Related to #180.

Related external issues:

- RustAudio/coreaudio-sys#4
- RustAudio/coreaudio-rs#57
This commit is contained in:
mitchmindtree 2018-01-26 23:49:47 +11:00
parent 091798ac5a
commit 3952c44c63
5 changed files with 294 additions and 31 deletions

View file

@ -1,8 +1,9 @@
extern crate cpal;
fn main() {
let endpoints = cpal::endpoints();
println!("Default Endpoint:\n {:?}", cpal::default_endpoint().map(|e| e.name()));
let endpoints = cpal::endpoints();
println!("Endpoints: ");
for (endpoint_index, endpoint) in endpoints.enumerate() {
println!("{}. Endpoint \"{}\" Audio formats: ",