ChartTiming
namespace Griff.Modules.Rhythm;
public struct ChartTimingWhen a chart’s beats are: the tempo in beats a minute, the beats in a bar and how many seconds into the song its first beat (beat 0) is, as the lanes’ BeatClock counts them.
Properties
Section titled “Properties”BeatsPerBar
Section titled “BeatsPerBar”public int BeatsPerBar { get; init; }Default
Section titled “Default”public static ChartTiming Default { get; }120 beats a minute in 4/4 from the very start.
Offset
Section titled “Offset”public double Offset { get; init; }PerBar
Section titled “PerBar”public int PerBar { get; }Beats in a bar, at least 1.
SecondsPerBeat
Section titled “SecondsPerBeat”public double SecondsPerBeat { get; }Seconds a beat lasts.
public double Tempo { get; init; }Methods
Section titled “Methods”BeatAt
Section titled “BeatAt”public double BeatAt(double seconds)The beat (with its fraction) seconds into the song.
Deconstruct
Section titled “Deconstruct”public void Deconstruct(out double Tempo, out int BeatsPerBar, out double Offset)Equals
Section titled “Equals”public override bool Equals(object obj)Equals
Section titled “Equals”public bool Equals(ChartTiming other)GetHashCode
Section titled “GetHashCode”public override int GetHashCode()SecondsAt
Section titled “SecondsAt”public double SecondsAt(double beat)How many seconds into the song beat is.
ToString
Section titled “ToString”public override string ToString()