Class DoubleToMusicalTimeSpanSettings
Settings which control the process of conversion a double number to an instance
of the
MusicalTimeSpan.
Inheritance
DoubleToMusicalTimeSpanSettings
Assembly: Melanchall.DryWetMidi.dll
Syntax
public sealed class DoubleToMusicalTimeSpanSettings
Fields
DefaultFractionalPartEpsilon
Represents the default maximum fractional part value to consider a number as integer during the
rationalization process (see
FractionalPartEpsilon).
Declaration
public const double DefaultFractionalPartEpsilon = 1E-07
Field Value
DefaultMaxIterationsCount
Represents the default maximum count of iterations the rationalization process
should take before stop (see
MaxIterationsCount).
Declaration
public const int DefaultMaxIterationsCount = 20
Field Value
DefaultPrecision
Represents the default maximum difference between an input double number and the calculated
MusicalTimeSpan (see
Precision).
Declaration
public const double DefaultPrecision = 1E-05
Field Value
Properties
FractionalPartEpsilon
Gets or sets a maximum fractional part value to consider a number as integer during the
rationalization process. For example,
1.001
will be considered as just
1.0
if
FractionalPartEpsilon is
0.001
or greater.
Declaration
public double FractionalPartEpsilon { get; set; }
Property Value
Exceptions
MaxIterationsCount
Gets or sets the maximum count of iterations the rationalization process
should take before stop. The default value is 20
.
Declaration
public int MaxIterationsCount { get; set; }
Property Value
Exceptions
Precision
Gets or sets the maximum difference between an input double number and the calculated
MusicalTimeSpan. For example,
3/2
will be returned as the result for
the input number of
1.5001
if
Precision is
0.0001
or greater.
Declaration
public double Precision { get; set; }
Property Value
Exceptions
See Also