25 #ifndef __gtk_ardour_midi_region_view_h__
26 #define __gtk_ardour_midi_region_view_h__
80 std::shared_ptr<ARDOUR::MidiRegion> r,
82 uint32_t basic_color);
86 std::shared_ptr<ARDOUR::MidiRegion> r,
186 std::shared_ptr<ARDOUR::MidiModel>
model()
const {
return _model; }
225 void select_notes (std::list<Evoral::event_id_t>,
bool allow_audition);
451 std::string
get_note_name (std::shared_ptr<NoteType> note, uint8_t note_value)
const;
463 typedef boost::unordered_map<ARDOUR::MidiModel::PatchChangePtr, std::shared_ptr<PatchChange> >
PatchChanges;
464 typedef boost::unordered_map<ARDOUR::MidiModel::constSysExPtr, std::shared_ptr<SysEx> >
SysExes;
467 std::shared_ptr<ARDOUR::MidiModel>
_model;
std::shared_ptr< PatchChange< Temporal::Beats > > PatchChangePtr
std::multiset< NotePtr, EarlierNoteComparator > Notes
std::shared_ptr< Event< Temporal::Beats > > SysExPtr
std::vector< SplitInfo > split_info
void show_verbose_cursor(std::shared_ptr< NoteType >) const
void increase_note_velocity_smush_together()
Temporal::Beats _step_edit_cursor_position
const std::shared_ptr< ARDOUR::MidiRegion > midi_region() const
void nudge_notes(bool forward, bool fine)
void set_flags(XMLNode *)
void note_left(NoteBase *ev)
void step_add_note(uint8_t channel, uint8_t number, uint8_t velocity, Temporal::Beats pos, Temporal::Beats len)
void select_notes(std::list< Evoral::event_id_t >, bool allow_audition)
void display_patch_changes()
void get_patch_key_at(Temporal::Beats time, uint8_t channel, MIDI::Name::PatchPrimaryKey &key) const
void increase_note_velocity_smush()
void increase_note_velocity_fine_together()
void transpose_up_tone_smush()
uint8_t get_velocity_for_add(ARDOUR::MidiModel::TimeType time) const
void decrease_note_velocity_fine_together()
MidiRegionView(ArdourCanvas::Container *parent, RouteTimeAxisView &tv, std::shared_ptr< ARDOUR::MidiRegion > r, double samples_per_pixel, uint32_t basic_color, bool recording, Visibility visibility)
void decrease_note_velocity()
void transpose_up_octave_smush()
PBD::ScopedConnection _channel_mode_changed_connection
void start_playing_midi_note(std::shared_ptr< NoteType > note)
void set_step_edit_cursor_width(Temporal::Beats beats)
std::vector< NoteResizeData * > _resize_data
void delete_patch_change(PatchChange *)
void invert_note_selection()
void change_note_lengths(bool, bool, Temporal::Beats beats, bool start, bool end)
GhostRegion * add_ghost(TimeAxisView &)
NoteBase * channel_selector_scoped_note()
uint16_t get_selected_channels() const
void increase_note_velocity_fine_smush_together()
void note_deleted(NoteBase *)
bool paste(Temporal::timepos_t const &pos, const ::Selection &selection, PasteContext &ctx)
void note_mouse_position(float xfraction, float yfraction, bool can_set_cursor=true)
Temporal::Beats _step_edit_cursor_width
void increase_note_velocity_together()
bool _select_all_notes_after_add
MouseState mouse_state() const
void note_selected(NoteBase *ev, bool add, bool extend=false)
uint8_t y_to_note(double y) const
void transpose_down_tone()
void move_note_starts_earlier()
void change_note_velocity(NoteBase *ev, int8_t vel, bool relative=false)
void decrease_note_velocity_smush()
std::set< NoteBase * > Selection
void transpose(bool up, bool fine, bool allow_smush)
void _redisplay(bool view_only)
void enter_internal(uint32_t state)
void unique_select(NoteBase *ev)
NoteBase * add_note(const std::shared_ptr< NoteType > note, bool visible)
double note_to_y(uint8_t note) const
void connect_to_diskstream()
NoteBase * copy_selection(NoteBase *primary)
void transpose_down_octave()
bool enter_notify(GdkEventCrossing *)
void goto_next_note(bool add_to_selection)
uint8_t get_channel_for_add(ARDOUR::MidiModel::TimeType time) const
void move_note_ends_later()
void begin_resizing(bool at_front)
void update_resizing(NoteBase *primary, bool at_front, double delta_x, bool relative, double snap_delta, bool with_snap)
void extend_active_notes()
void add_canvas_patch_change(ARDOUR::MidiModel::PatchChangePtr patch)
std::vector< NoteBase * > CopyDragEvents
void increase_note_velocity_fine_smush()
void move_patch_change(PatchChange &, Temporal::Beats)
void transpose_down_octave_smush()
void change_note_time(NoteBase *ev, ARDOUR::MidiModel::TimeType, bool relative=false)
void parameter_changed(std::string const &p)
MidiStreamView * midi_stream_view() const
void move_selection(Temporal::timecnt_t const &dx, double dy, double cumulative_dy)
void note_entered(NoteBase *ev)
Temporal::timecnt_t snap_pixel_to_time(double x, bool ensure_snap=false)
std::shared_ptr< PatchChange > find_canvas_patch_change(ARDOUR::MidiModel::PatchChangePtr p)
void sync_velocity_drag(double factor)
void decrease_note_velocity_together()
void cut_copy_clear(Editing::CutCopyOp)
void get_events(Events &e, Evoral::Sequence< Temporal::Beats >::NoteOperator op, uint8_t val, int chan_mask=0)
void start_playing_midi_chord(std::vector< std::shared_ptr< NoteType > > notes)
void apply_note_range(uint8_t lowest, uint8_t highest, bool force=false)
std::shared_ptr< ARDOUR::MidiModel > model() const
void create_note_at(Temporal::timepos_t const &t, double y, Temporal::Beats length, uint32_t state, bool shift_snap)
void move_note_ends_later_fine()
void trim_front_starting()
void nudge_notes_earlier()
void create_ghost_note(double, double, uint32_t state)
MidiTimeAxisView * midi_view() const
ArdourCanvas::Rectangle * _step_edit_cursor
void region_resized(const PBD::PropertyChange &)
MidiRegionView(const MidiRegionView &other)
NoteBase * find_canvas_note(Evoral::event_id_t id)
samplecnt_t _last_display_zoom
void begin_drag_edit(std::string const &why)
void update_vertical_drag_selection(double last_y, double y, bool extend)
void selection_as_notelist(Notes &selected, bool allow_all_if_none_selected=false)
void midi_channel_mode_changed()
Temporal::Beats get_grid_beats(Temporal::timepos_t const &pos) const
void change_velocities(bool up, bool fine, bool allow_smush, bool all_together)
double get_end_position_pixels()
ARDOUR::MidiModel::NoteDiffCommand * _note_diff_command
void move_step_edit_cursor(Temporal::Beats pos)
std::shared_ptr< SysEx > find_canvas_sys_ex(ARDOUR::MidiModel::SysExPtr s)
double contents_note_range() const
bool motion(GdkEventMotion *)
bool note_in_region_range(const std::shared_ptr< NoteType > note, bool &visible) const
bool key_release(GdkEventKey *)
bool note_in_region_time_range(const std::shared_ptr< NoteType > note) const
void maybe_select_by_position(GdkEventButton *ev, double x, double y)
double get_position_pixels()
void change_note_channel(NoteBase *, int8_t, bool relative=false)
void note_diff_add_note(const std::shared_ptr< NoteType > note, bool selected, bool show_velocity=false)
void apply_note_diff(bool as_subcommand=false, bool was_copy=false)
uint32_t get_fill_color() const
void patch_left(PatchChange *)
void add_patch_change(Temporal::timecnt_t const &, Evoral::PatchChange< Temporal::Beats > const &)
void transpose_up_octave()
double contents_height() const
void start_note_splitting()
void quantize_selected_notes()
void move_note_starts_earlier_fine()
void add_to_selection(NoteBase *)
Gtkmm2ext::Color _patch_change_outline
void clear_selection_internal()
void add_select_next_note()
void show_verbose_cursor_for_new_note_value(std::shared_ptr< NoteType > current_note, uint8_t new_note) const
void note_diff_add_change(NoteBase *ev, ARDOUR::MidiModel::NoteDiffCommand::Property, uint8_t val)
std::set< std::shared_ptr< NoteType > > _marked_for_velocity
bool scroll(GdkEventScroll *)
void update_hit(Hit *, bool update_ghost_regions=true)
void note_deselected(NoteBase *ev)
void clear_note_selection()
void delete_note(std::shared_ptr< NoteType >)
uint8_t _current_range_max
void display_patch_changes_on_channel(uint8_t, bool, PatchChanges &)
void end_note_splitting()
void finish_resizing(NoteBase *primary, bool at_front, double delat_x, bool relative, double snap_delta, bool with_snap)
void paste_internal(Temporal::timepos_t const &pos, unsigned paste_count, float times, const MidiCutBuffer &)
std::set< Evoral::event_id_t > _pending_note_selection
void decrease_note_velocity_fine_smush()
void start_note_diff_command(std::string name="midi edit")
void trim_note(NoteBase *ev, ARDOUR::MidiModel::TimeType start_delta, ARDOUR::MidiModel::TimeType end_delta)
ARDOUR::ColorMode color_mode() const
std::shared_ptr< ARDOUR::MidiModel > _model
void sync_ghost_selection(NoteBase *)
void update_note(NoteBase *, bool update_ghost_regions=true)
void extend_note_selection()
void note_dropped(NoteBase *ev, Temporal::timecnt_t const &d_qn, int8_t d_note, bool copy)
void increase_note_velocity()
bool leave_notify(GdkEventCrossing *)
bool button_press(GdkEventButton *)
void set_selected(bool yn)
bool set_velocity_for_notes(std::vector< NoteBase * > ¬es, int velocity)
bool button_release(GdkEventButton *)
void nudge_notes_earlier_fine()
MidiCutBuffer * selection_as_cut_buffer() const
void change_patch_change(PatchChange &old_patch, const MIDI::Name::PatchPrimaryKey &new_patch)
void select_matching_notes(uint8_t notenum, uint16_t channel_mask, bool add, bool extend)
void mouse_mode_changed()
uint8_t _current_range_min
void note_diff_remove_note(NoteBase *ev)
Events::iterator _optimization_iterator
void remove_from_selection(NoteBase *)
void select_range(Temporal::timepos_t const &start, Temporal::timepos_t const &end)
Evoral::Note< Temporal::Beats > NoteType
void play_midi_note(std::shared_ptr< NoteType > note)
void transpose_down_tone_smush()
void show_step_edit_cursor(Temporal::Beats pos)
void change_note_length(NoteBase *, ARDOUR::MidiModel::TimeType)
void select_previous_note()
double snap_to_pixel(double x, bool ensure_snap=false)
void update_sustained(Note *, bool update_ghost_regions=true)
void step_sustain(Temporal::Beats beats)
void set_channel_selector_scoped_note(NoteBase *note)
PBD::ScopedConnection _instrument_changed_connection
PBD::ScopedConnection snap_changed_connection
NoteBase * _channel_selection_scoped_note
void sysex_left(SysEx *p)
PatchChanges _patch_changes
CopyDragEvents _copy_drag_events
void toggle_matching_notes(uint8_t notenum, uint16_t channel_mask)
PBD::ScopedConnection _mouse_mode_connection
void step_patch(PatchChange &patch, bool bank, int delta)
boost::unordered_map< ARDOUR::MidiModel::constSysExPtr, std::shared_ptr< SysEx > > SysExes
bool key_press(GdkEventKey *)
Evoral::Sequence< Temporal::Beats >::Notes Notes
void delete_sysex(SysEx *)
bool canvas_group_event(GdkEvent *ev)
void duplicate_selection()
void move_note_ends_earlier()
void move_note_starts_later()
MidiListEditor * _list_editor
void display_model(std::shared_ptr< ARDOUR::MidiModel > model)
void update_ghost_note(double, double, uint32_t state)
ARDOUR::InstrumentInfo & instrument_info() const
bool note_canvas_event(GdkEvent *ev)
void edit_patch_change(PatchChange *)
MIDI::Name::PatchPrimaryKey patch_change_to_patch_key(ARDOUR::MidiModel::PatchChangePtr)
MidiRegionView(const MidiRegionView &other, std::shared_ptr< ARDOUR::MidiRegion >)
boost::unordered_map< ARDOUR::MidiModel::PatchChangePtr, std::shared_ptr< PatchChange > > PatchChanges
void move_note_ends_earlier_fine()
void increase_note_velocity_fine()
void update_patch_changes()
void decrease_note_velocity_smush_together()
bool set_velocities_for_notes(std::vector< NoteBase * > ¬es, std::vector< int > &velocities)
PBD::ScopedConnection content_connection
ARDOUR::ChannelMode get_channel_mode() const
void show_verbose_cursor(std::string const &, double, double) const
ArdourCanvas::Container * _note_group
uint8_t change_note_note(NoteBase *ev, int8_t note, bool relative=false)
void update_drag_selection(Temporal::timepos_t const &start, Temporal::timepos_t const &end, double y0, double y1, bool extend)
Temporal::Beats get_draw_length_beats(Temporal::timepos_t const &pos) const
void set_velocity(NoteBase *primary, int velocity)
void goto_previous_note(bool add_to_selection)
void move_note_starts_later_fine()
bool _mouse_changed_selection
void hide_step_edit_cursor()
void add_select_previous_note()
boost::unordered_map< std::shared_ptr< NoteType >, NoteBase * > Events
void patch_entered(PatchChange *)
void hide_verbose_cursor()
Selection const & selection() const
std::set< std::shared_ptr< NoteType > > _marked_for_selection
void sysex_entered(SysEx *p)
Gtkmm2ext::Color _patch_change_fill
void move_copies(Temporal::timecnt_t const &dx_qn, double dy, double cumulative_dy)
double note_height() const
std::shared_ptr< CursorContext > _press_cursor_ctx
void change_patch_change(ARDOUR::MidiModel::PatchChangePtr, Evoral::PatchChange< Temporal::Beats > const &)
void reset_width_dependent_items(double pixel_width)
void decrease_note_velocity_fine_smush_together()
std::string get_note_name(std::shared_ptr< NoteType > note, uint8_t note_value) const
MidiRegionView(ArdourCanvas::Container *parent, RouteTimeAxisView &tv, std::shared_ptr< ARDOUR::MidiRegion > r, double samples_per_pixel, uint32_t basic_color)
void join_notes_on_channel(int channel)
Temporal::Beats earliest_in_selection()
void note_diff_add_change(NoteBase *ev, ARDOUR::MidiModel::NoteDiffCommand::Property, Temporal::Beats val)
void nudge_notes_later_fine()
void change_channel(uint8_t channel)
NoteBase * find_canvas_note(std::shared_ptr< NoteType >)
void data_recorded(std::weak_ptr< ARDOUR::MidiSource >)
void instrument_settings_changed()
void decrease_note_velocity_fine()
ARDOUR::ColorMode color_mode() const
MidiStreamView * midi_view()
virtual bool selected() const
static double NAME_HIGHLIGHT_SIZE
GtkImageIconNameData name
PBD::PropertyDescriptor< timecnt_t > length
PBD::PropertyDescriptor< timepos_t > start
Temporal::samplecnt_t samplecnt_t
void add(const Gtk::StockItem &item)
int pixel_width(const std::string &str, const Pango::FontDescription &font)
ArdourCanvas::Rectangle * resize_rect
SplitInfo(Temporal::Beats const &t, Temporal::Beats const &l, int n, int c, int v, int ov)