Region struct

A region (clip) is an object on the timeline that contains either MidiNote's or AudioClip's.

Contents

It is uniquely identified using its name (and ArrangerObjectInfo type), so name must be unique throughout the Project.

Each main Region must have its obj_info member filled in with clones.

Public variables

ArrangerObject base
Base struct.
char* name
Unique Region name to be shown on the RegionWidget.
int track_pos
Owner Track position.
TrackLane* lane
Owner lane.
char* linked_region_name
Linked parent region.
struct Region* linked_region
cache
int muted
Muted or not.
GdkRGBA color
TODO region color independent of track.
MidiNote** midi_notes
MIDI notes.
MidiNote* unended_notes
Unended notes started in recording with MIDI NOTE ON signal but haven't received a NOTE OFF yet.
int pool_id
Audio pool ID of the associated audio file.
AutomationPoint** aps
The automation points.
AutomationTrack* at
Pointer back to the AutomationTrack.
int at_index
Used when undo/redoing.
ChordObject** chord_objects
ChordObject's in this Region.
PangoLayout* layout
Cache layout for drawing the name.
PangoLayout* chords_layout
Cache layout for drawing the chord names inside the region.

Variable documentation

int Region::track_pos

Owner Track position.

Used in actions after cloning.

char* Region::linked_region_name

Linked parent region.

Either the midi notes from this region, or the midi notes from the linked region are used

GdkRGBA Region::color

TODO region color independent of track.

If null, the track color is used.

AutomationPoint** Region::aps

The automation points.

Must always stay sorted by position.

AutomationTrack* Region::at

Pointer back to the AutomationTrack.

This doesn't have to be serialized - during loading, you can traverse the AutomationTrack's automation Region's and set it.