pub struct TimingPoint { /* private fields */ }
Expand description

Struct representing a timing point. Each timing point influences a specified portion of the map, commonly called a timing section. The .osu file format requires these to be sorted in chronological order.

Implementations

Converts beat duration in milliseconds to BPM.

Converts BPM to beat duration in milliseconds.

New instance of TimingPoint that is inherited.

New instance of TimingPoint that is uninherited.

Calculates BPM using the beatLength field when unherited.

  • Returns None if the timing point is inherited or beat_length isn’t a valid decimal.

Calculates the slider velocity multiplier when the timing point is inherited.

  • Returns None if the timing point is uninherited or beat_length isn’t a valid decimal.

Start time of the timing section, in milliseconds from the beginning of the beatmap’s audio. The end of the timing section is the next timing point’s time (or never, if this is the last timing point).

Set the timing point’s start time.

Amount of beats in a measure. Inherited timing points ignore this property.

Set the timing point’s meter field.

Default sample set for hit objects

Set the timing point’s sample set.

Custom sample index for hit objects.

Get a mutable reference to the timing point’s sample index.

Volume percentage for hit objects.

Set the timing point’s volume.

Get the timing point’s uninherited.

Set the timing point’s uninherited.

Get the timing point’s effects.

Get a mutable reference to the timing point’s effects.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Feeds this value into the given Hasher. Read more

Feeds a slice of this type into the given Hasher. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Parses a string into an object. Read more

Returns a string representation of the object. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.