Ardour  8.12
midi_playlist.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2006-2016 David Robillard <d@drobilla.net>
3  * Copyright (C) 2007-2017 Paul Davis <paul@linuxaudiosystems.com>
4  * Copyright (C) 2009-2012 Carl Hetherington <carl@carlh.net>
5  * Copyright (C) 2013 John Emmas <john@creativepost.co.uk>
6  * Copyright (C) 2017-2019 Robin Gareus <robin@gareus.org>
7  *
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License along
19  * with this program; if not, write to the Free Software Foundation, Inc.,
20  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21  */
22 
23 #ifndef __ardour_midi_playlist_h__
24 #define __ardour_midi_playlist_h__
25 
26 #include <vector>
27 #include <list>
28 
29 #include "evoral/Parameter.h"
30 
31 #include "ardour/ardour.h"
32 #include "ardour/midi_cursor.h"
33 #include "ardour/midi_model.h"
35 #include "ardour/playlist.h"
36 #include "evoral/Note.h"
37 #include "evoral/Parameter.h"
38 #include "ardour/rt_midibuffer.h"
39 
40 namespace Evoral {
41 template<typename Time> class EventSink;
42 class Beats;
43 }
44 
45 namespace ARDOUR
46 {
47 
48 class BeatsSamplesConverter;
49 class MidiChannelFilter;
50 class MidiRegion;
51 class Session;
52 class Source;
53 
54 template<typename T> class MidiRingBuffer;
55 
57 {
58 public:
59  MidiPlaylist (Session&, const XMLNode&, bool hidden = false);
60  MidiPlaylist (Session&, std::string name, bool hidden = false);
61  MidiPlaylist (std::shared_ptr<const MidiPlaylist> other, std::string name, bool hidden = false);
62 
64  MidiPlaylist (std::shared_ptr<const MidiPlaylist> other,
65  timepos_t const & start,
66  timepos_t const & cnt,
67  std::string name,
68  bool hidden = false);
69 
71 
74 
75  int set_state (const XMLNode&, int version);
76 
77  bool destroy_region (std::shared_ptr<Region>);
78 
79  void _split_region (std::shared_ptr<Region>, timepos_t const & position, ThawList& thawlist);
80 
81  void set_note_mode (NoteMode m) { _note_mode = m; }
82 
83  std::set<Evoral::Parameter> contained_automation();
84 
85  std::shared_ptr<Region> combine (const RegionList&, std::shared_ptr<Track>);
86  void uncombine (std::shared_ptr<Region>);
87 
88  private:
89  void dump () const;
90 
92 
94 };
95 
96 } /* namespace ARDOUR */
97 
98 #endif /* __ardour_midi_playlist_h__ */
int set_state(const XMLNode &, int version)
void uncombine(std::shared_ptr< Region >)
MidiPlaylist(std::shared_ptr< const MidiPlaylist > other, timepos_t const &start, timepos_t const &cnt, std::string name, bool hidden=false)
MidiPlaylist(Session &, std::string name, bool hidden=false)
bool destroy_region(std::shared_ptr< Region >)
RTMidiBuffer * rendered()
RTMidiBuffer _rendered
Definition: midi_playlist.h:93
void render(MidiChannelFilter *)
MidiPlaylist(Session &, const XMLNode &, bool hidden=false)
void set_note_mode(NoteMode m)
Definition: midi_playlist.h:81
std::shared_ptr< Region > combine(const RegionList &, std::shared_ptr< Track >)
void _split_region(std::shared_ptr< Region >, timepos_t const &position, ThawList &thawlist)
MidiPlaylist(std::shared_ptr< const MidiPlaylist > other, std::string name, bool hidden=false)
std::set< Evoral::Parameter > contained_automation()
Definition: xml++.h:114
GtkImageIconNameData name
Definition: gtkimage.h:6
#define LIBARDOUR_API
PBD::PropertyDescriptor< bool > hidden
PBD::PropertyDescriptor< timepos_t > start
std::list< std::shared_ptr< Region > > RegionList
Definition: editor.h:87
DebugBits Beats
DebugBits MidiRingBuffer