Skip to content

Note

Notes in the piano roll trigger sounds in instruments.

Note

Represents a note in the FL Studio piano roll.

number property writable

number: int

Standard MIDI note number (60 is middle C).

time property writable

time: int

Time at which the note begins (in ticks).

length property writable

length: int

Length of the note (in ticks).

group property writable

group: int

Group number that this note belongs to. This can be used to link notes together such that if the user moves one, all others in the same group are also moved.

To un-group notes, set the group number to 0.

pan property writable

pan: float

The panning value of the note, between 0 and 1. 0.5 is centered.

velocity property writable

velocity: float

The velocity of the note, between 0 and 1. 0.8 is the default.

release property writable

release: float

The release of the note, between 0 and 1. 0.5 is the default.

color property writable

color: int

The color of the note, between 0 and 15. 0 is the default note color.

fcut property writable

fcut: float

The note filter cutoff frequency, between 0 and 1. 0.5 is the default.

fres property writable

fres: float

The note filter resonance frequency, between 0 and 1. 0.5 is the default.

pitchofs property writable

pitchofs: int

The pitch offset of the note, between -120 (-1 octave) and 120 (+1 octave).

This is represented in units of 10 cents, so setting note.pitchofs = 42 will set the pitch offset to +420 cents.

repeats property writable

repeats: int

The repeats property of the note from 0 to 14.

  • 0: no repeat
  • 1: 1/4 (beat)
  • 2: 1/8 dotted
  • 3: 1/4 triplet
  • 4: 1/8
  • 5: 1/16 dotted
  • 6: 1/8 triplet
  • 7: 1/16 (step)
  • 8: 1/32 dotted
  • 9: 1/16 triplet
  • 10: 1/32 (half step)
  • 11: 1/64 dotted
  • 12: 1/32 triplet
  • 13: 1/64 (quarter step)
  • 14: 1/64 triplet

slide property writable

slide: bool

Whether the note is a slide note.

porta property writable

porta: bool

Whether the note is a portamento note.

muted property writable

muted: bool

Whether the note is muted.

selected property writable

selected: bool

Whether the note is selected within the piano roll.

__init__

__init__() -> None

Create a new instance of a Note object

This note won't be added to the piano roll unless it is passed to score.addNote.

clone

clone() -> Note

Return a new Note object with identical properties to this note.

This note will not be added to the piano roll until score.addNote is called with it as an argument.