Sounds | LRFSound
The LRFSound
data type is a collection of properties that represent a song in the Little Robot Friends library. LRFSounds consist of five properties: note
which contains the musical note that the sound is comprised of. octave
determines the octave that the note is played in. intonation
is the behavior of the note, this allows for a variety of expressions. duration
stores the length of the note and finally, pause
is the length of the pause that follows the note.
Examples
Long-form:
LRFSound mySound = {
.note = LRFNote_A,
.octave = LRFOctave_3,
.intonation = LRFIntonation_Flat,
.duration = LRFDuration_Long,
.pause = LRFDuration_None
};
Short-form:
LRFSound myOtherSound = { LRFNote_C, LRFOctave_4, LRFIntonation_Rising, LRFDuration_DoubleMedium, LRFDuration_None };
Syntax
LRFSound mySound = {
.note = ,
.octave = ,
.intonation = ,
.duration = ,
.pause =
}
Parameters
note
: LRFNote type - The musical note of the sound.octave
: LRFOctave type - The octave that the note is played in.intonation
: LRFIntonation type - The intonation of the sound made.duration
: LRFDuration type - The duration of the sound made.pause
: LRFDuration type - The duration of the pause after the note is played.