use mp3rgain::Channel;
use std::path::PathBuf;
#[derive(Debug, Default, Clone, Copy, PartialEq, Eq)]
pub enum OutputFormat {
#[default]
Text,
Json,
Tsv, }
#[derive(Debug, Default, Clone, Copy, PartialEq, Eq)]
pub enum StoredTagMode {
#[default]
None, Check, Delete, Skip, Recalc, UseApev2, }
pub struct AacAlbumInfo {
pub album_gain_db: f64,
pub album_peak: f64,
}
#[derive(Default)]
pub struct Options {
pub gain_steps: Option<i32>, pub gain_modifier_db: f64, pub channel_gain: Option<(Channel, i32)>, pub gain_modifier: i32,
pub undo: bool, pub stored_tag_mode: StoredTagMode, pub use_id3v2: bool, pub track_gain: bool, pub album_gain: bool, pub skip_album: bool, pub max_amplitude_only: bool, pub track_index: Option<u32>,
pub preserve_timestamp: bool, pub ignore_clipping: bool, pub prevent_clipping: bool, pub quiet: bool, pub recursive: bool, pub dry_run: bool, pub output_format: OutputFormat, pub wrap_gain: bool, pub use_temp_file: bool, pub assume_mpeg2: bool,
pub threads: Option<usize>,
pub files: Vec<PathBuf>,
}
impl Options {
pub fn dry_run_prefix(&self) -> &'static str {
if self.dry_run {
"[DRY RUN] "
} else {
""
}
}
}