Skip to main content

sim_lib_sound_bridge/
error.rs

1use thiserror::Error;
2
3/// Error raised by the MIDI-to-sound bridge and its voice pool.
4#[derive(Debug, Error, Clone, PartialEq, Eq)]
5pub enum SoundBridgeError {
6    /// The configured polyphony limit was zero.
7    #[error("polyphony must be positive")]
8    ZeroPolyphony,
9    /// An event arrived with a tick earlier than the last processed event.
10    #[error("bridge clock moved backwards")]
11    NonMonotonicTime,
12}