Struct rimd::MetaEvent [] [src]

pub struct MetaEvent {
    pub command: MetaCommand,
    pub length: u64,
    pub data: Vec<u8>,
}

Meta event building and parsing. See http://cs.fit.edu/~ryan/cse4051/projects/midi/midi.html#meta_event for a description of the various meta events and their formats

Fields

Methods

impl MetaEvent
[src]

Turn bytes bytes of the data of this event into a u64

Parse the data of this event into a utf8 string

Extract the next meta event from a reader

Create a sequence number meta event

Create a text meta event

Create a copyright notice meta event

Create a name meta event

Create an instrument name meta event

Create a lyric text meta event

Create a marker text meta event

Create a cue point meta event

Create a midi channel prefix assignment meta event

Create a midi port prefix assignment meta event

Create an end of track meta event

Create an event to set track tempo. This is stored as a 24-bit value. This method will fail an assertion if the supplied tempo is greater than 224.

Create an smpte offset meta event

Create a time signature event. Time signature of the form: numerator/2denominator eg: 6/8 would be specified using numerator=6, denominator=3

The parameter clocks_per_tick is the number of MIDI Clocks per metronome tick. Normally, there are 24 MIDI Clocks per quarter note. However, some software allows this to be set by the user. The parameter num_32nd_notes_per_24_clocks defines this in terms of the number of 1/32 notes which make up the usual 24 MIDI Clocks (the 'standard' quarter note). 8 is standard

Create a Key Signature event expressed as the number of sharps or flats, and a major/minor flag. sharps_flats of 0 represents a key of C, negative numbers represent 'flats', while positive numbers represent 'sharps'.

This is the MIDI-file equivalent of the System Exclusive Message. sequencer-specific directives can be incorporated into a MIDI file using this event.

Trait Implementations

impl Debug for MetaEvent
[src]

Formats the value using the given formatter.

impl Clone for MetaEvent
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Display for MetaEvent
[src]

Formats the value using the given formatter. Read more