game is now independent of hexodsp/cpal

This commit is contained in:
Nixon 2022-08-28 15:28:08 +08:00 committed by tuxmain
commit 5b22e84952
17 changed files with 79 additions and 200 deletions

View file

@ -1,5 +1,6 @@
// https://github.com/WeirdConstructor/HexoDSP/blob/master/examples/cpal_demo_node_api.rs
// use bevy::{prelude::*, asset::HandleId};
use crate::game::AudioMsg;
use cpal::traits::{DeviceTrait, HostTrait, StreamTrait};
@ -163,4 +164,4 @@ fn start_backend<F: FnMut()>(node_exec: NodeExecutor, frontend_loop: F) {
cpal::SampleFormat::I16 => run::<i16, F>(&device, &config.into(), node_exec, frontend_loop),
cpal::SampleFormat::U16 => run::<u16, F>(&device, &config.into(), node_exec, frontend_loop),
};
}
}