| Crates.io | horizontal_mixer |
| lib.rs | horizontal_mixer |
| version | 0.1.3 |
| created_at | 2023-10-07 14:39:25.203014+00 |
| updated_at | 2023-10-07 15:20:19.475658+00 |
| description | horizontal mixer in Rust using Kira for audio playback |
| homepage | |
| repository | https://github.com/TheBlueRuby/rust_horizontal_mixer |
| max_upload_size | |
| id | 996379 |
| size | 6,505 |
Simple horizontal mixer in Rust using Kira for audio playback.
Mixing between track_1.mp3 and track_2.mp3 with a fade time of 0.15s every 2 seconds, looping
use horizontal_mixer::HorizontalMixer;
use std::{thread, time::Duration};
fn main() {
let mut horizontal_mixer = HorizontalMixer::new(
"track_1.mp3",
"track_2.mp3",
Duration::from_secs_f32(0.15),
true,
);
horizontal_mixer.play();
for _ in 0..16 {
thread::sleep(Duration::from_secs(2));
horizontal_mixer.toggle_track();
}
}
This project is licensed under the MIT license.
Kira, the library this is based on, is licensed under either: