AudioPlayer is a simple Rust-based application for playing .wav audio files from a specified folder. It supports playback controls such as play/pause, skip to the next track, and return to the previous track using keyboard inputs.
- Play
.wavfiles: Automatically scans a folder and loads.wavfiles into a playlist. - Playback controls:
p: Toggle play/pause.j: Play the previous track.k: Play the next track.
- Sample playback: Uses CPAL for audio output and supports
.wavfiles with matching sample rates. - Error handling: Ensures that the files match the expected sample rate and channels.
- Clone this repository or copy the source code into your Rust project.
- Build the project:
cargo build --release
- Compile and run the application, passing the folder containing .wav files as an argument:
cargo run --release -- <folder_path>