pub struct ReplayGain {
pub track_gain_db: Option<f32>,
pub album_gain_db: Option<f32>,
pub track_peak: Option<f32>,
pub album_peak: Option<f32>,
pub raw_track_gain: i64,
pub raw_album_gain: i64,
pub raw_track_peak: i64,
pub raw_album_peak: i64,
}Expand description
ReplayGain values parsed from the file’s tags.
The *_db / *_peak fields are user-friendly conversions; the raw_*
fields keep Rockbox’s native fixed-point encoding — linear scale
factors in Q7.24, exactly what rockbox-dsp’s
set_replaygain_gains_raw() expects.
Fields§
§track_gain_db: Option<f32>Track gain in dB (e.g. -6.5), if the tag is present.
album_gain_db: Option<f32>Album gain in dB, if the tag is present.
track_peak: Option<f32>Track peak amplitude, 1.0 = full scale.
album_peak: Option<f32>Album peak amplitude, 1.0 = full scale.
raw_track_gain: i64Track gain as a linear Q7.24 scale factor (0 = tag absent).
raw_album_gain: i64Album gain as a linear Q7.24 scale factor (0 = tag absent).
raw_track_peak: i64Track peak in Q7.24 (0 = tag absent).
raw_album_peak: i64Album peak in Q7.24 (0 = tag absent).
Implementations§
Trait Implementations§
Source§impl Clone for ReplayGain
impl Clone for ReplayGain
Source§fn clone(&self) -> ReplayGain
fn clone(&self) -> ReplayGain
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ReplayGain
Source§impl Debug for ReplayGain
impl Debug for ReplayGain
Source§impl Default for ReplayGain
impl Default for ReplayGain
Source§fn default() -> ReplayGain
fn default() -> ReplayGain
Returns the “default value” for a type. Read more
Source§impl PartialEq for ReplayGain
impl PartialEq for ReplayGain
Source§fn eq(&self, other: &ReplayGain) -> bool
fn eq(&self, other: &ReplayGain) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ReplayGain
Auto Trait Implementations§
impl Freeze for ReplayGain
impl RefUnwindSafe for ReplayGain
impl Send for ReplayGain
impl Sync for ReplayGain
impl Unpin for ReplayGain
impl UnsafeUnpin for ReplayGain
impl UnwindSafe for ReplayGain
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more