pub struct Notes { /* private fields */ }
Expand description
The objects set for querying by lane or time.
Implementations§
source§impl Notes
impl Notes
sourcepub fn into_all_notes(self) -> Vec<Obj>
pub fn into_all_notes(self) -> Vec<Obj>
Converts into the notes sorted by time.
sourcepub fn all_notes(&self) -> impl Iterator<Item = &Obj>
pub fn all_notes(&self) -> impl Iterator<Item = &Obj>
Returns the iterator having all of the notes sorted by time.
sourcepub fn bpm_changes(&self) -> &BTreeMap<ObjTime, BpmChangeObj>
pub fn bpm_changes(&self) -> &BTreeMap<ObjTime, BpmChangeObj>
Returns the bpm change objects.
sourcepub fn section_len_changes(&self) -> &BTreeMap<Track, SectionLenChangeObj>
pub fn section_len_changes(&self) -> &BTreeMap<Track, SectionLenChangeObj>
Returns the section len change objects.
sourcepub fn bga_changes(&self) -> &BTreeMap<ObjTime, BgaObj>
pub fn bga_changes(&self) -> &BTreeMap<ObjTime, BgaObj>
Returns the bga change objects.
sourcepub fn next_obj_by_key(&self, key: Key, time: ObjTime) -> Option<&Obj>
pub fn next_obj_by_key(&self, key: Key, time: ObjTime) -> Option<&Obj>
Finds next object on the key Key
from the time ObjTime
.
sourcepub fn remove_latest_note(&mut self, id: ObjId) -> Option<Obj>
pub fn remove_latest_note(&mut self, id: ObjId) -> Option<Obj>
Removes the latest note from the notes.
sourcepub fn remove_note(&mut self, id: ObjId) -> Vec<Obj>
pub fn remove_note(&mut self, id: ObjId) -> Vec<Obj>
Removes the note from the notes.
sourcepub fn push_bpm_change(&mut self, bpm_change: BpmChangeObj)
pub fn push_bpm_change(&mut self, bpm_change: BpmChangeObj)
Adds a new BPM change object to the notes.
sourcepub fn push_section_len_change(
&mut self,
section_len_change: SectionLenChangeObj
)
pub fn push_section_len_change( &mut self, section_len_change: SectionLenChangeObj )
Adds a new section length change object to the notes.
sourcepub fn push_bga_change(&mut self, bga: BgaObj)
pub fn push_bga_change(&mut self, bga: BgaObj)
Adds a new bga change object to the notes.
sourcepub fn last_visible_time(&self) -> Option<ObjTime>
pub fn last_visible_time(&self) -> Option<ObjTime>
Gets the time of last visible object.
sourcepub fn last_bgm_time(&self) -> Option<ObjTime>
pub fn last_bgm_time(&self) -> Option<ObjTime>
Gets the time of last BGM object.
You can’t use this to find the length of music. Because this doesn’t consider that the length of sound. And visible notes may ring after all BGMs.
sourcepub fn last_obj_time(&self) -> Option<ObjTime>
pub fn last_obj_time(&self) -> Option<ObjTime>
Gets the time of last any object including visible, BGM, BPM change, section length change and so on.
You can’t use this to find the length of music. Because this doesn’t consider that the length of sound.
sourcepub fn resolution_for_pulses(&self) -> u32
pub fn resolution_for_pulses(&self) -> u32
Calculates a required resolution to convert the notes time into pulses, which split one quarter note evenly.