summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/auditioner.h
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2014-01-23 13:41:20 -0500
committerPaul Davis <paul@linuxaudiosystems.com>2014-01-23 13:41:20 -0500
commit7000afdc66c9e0ae8dcf9ec080517dabba1e7f34 (patch)
tree19574ed8a1fbafa6bed222d8cf817ee1c8098314 /libs/ardour/ardour/auditioner.h
parent065e1e63342633f72725a5309926f71c87804293 (diff)
parent40d8c5ae01f25e02457c554170a53d537246a7d4 (diff)
fix merge conflict with master
Diffstat (limited to 'libs/ardour/ardour/auditioner.h')
-rw-r--r--libs/ardour/ardour/auditioner.h61
1 files changed, 58 insertions, 3 deletions
diff --git a/libs/ardour/ardour/auditioner.h b/libs/ardour/ardour/auditioner.h
index 26e395f93e..94d4eab479 100644
--- a/libs/ardour/ardour/auditioner.h
+++ b/libs/ardour/ardour/auditioner.h
@@ -26,6 +26,10 @@
#include "ardour/ardour.h"
#include "ardour/audio_track.h"
+#include "ardour/midi_region.h"
+
+#include "ardour/audio_diskstream.h"
+#include "ardour/midi_diskstream.h"
namespace ARDOUR {
@@ -33,14 +37,14 @@ class Session;
class AudioRegion;
class AudioPlaylist;
-class LIBARDOUR_API Auditioner : public AudioTrack
+class LIBARDOUR_API Auditioner : public Track
{
public:
Auditioner (Session&);
~Auditioner ();
int init ();
- int connect ();
+ int connect ();
void audition_region (boost::shared_ptr<Region>);
@@ -63,11 +67,52 @@ class LIBARDOUR_API Auditioner : public AudioTrack
virtual ChanCount input_streams () const;
frameoffset_t seek_frame() const { return _seeking ? _seek_frame : -1;}
- void seek_response(frameoffset_t pos) { _seek_complete = true; if (_seeking) { current_frame = pos; _seek_complete = true;} }
+ void seek_response(frameoffset_t pos) {
+ _seek_complete = true;
+ if (_seeking) { current_frame = pos; _seek_complete = true;}
+ }
+
PBD::Signal2<void, ARDOUR::framecnt_t, ARDOUR::framecnt_t> AuditionProgress;
+ /* Track */
+ int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick, bool& need_butler);
+ DataType data_type () const;
+
+ int roll_audio (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick, bool& need_butler);
+ int roll_midi (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick, bool& need_butler);
+
+ boost::shared_ptr<Diskstream> create_diskstream ();
+ void set_diskstream (boost::shared_ptr<Diskstream> ds);
+
+ /* fake track */
+ void set_state_part_two () {}
+ int set_state (const XMLNode&, int) { return 0; }
+ bool bounceable (boost::shared_ptr<Processor>, bool) const { return false; }
+ void freeze_me (InterThreadInfo&) {}
+ void unfreeze () {}
+
+ boost::shared_ptr<Region> bounce (InterThreadInfo&)
+ { return boost::shared_ptr<Region> (); }
+
+ boost::shared_ptr<Region> bounce_range (framepos_t, framepos_t, InterThreadInfo&, boost::shared_ptr<Processor>, bool)
+ { return boost::shared_ptr<Region> (); }
+
+ int export_stuff (BufferSet&, framepos_t, framecnt_t, boost::shared_ptr<Processor>, bool, bool)
+ { return -1; }
+
+ boost::shared_ptr<Diskstream> diskstream_factory (XMLNode const &)
+ { return boost::shared_ptr<Diskstream> (); }
+
+ boost::shared_ptr<AudioDiskstream> audio_diskstream() const
+ { return boost::dynamic_pointer_cast<AudioDiskstream> (_diskstream); }
+
+ boost::shared_ptr<MidiDiskstream> midi_diskstream() const
+ { return boost::dynamic_pointer_cast<MidiDiskstream> (_diskstream); }
+
+
private:
boost::shared_ptr<AudioRegion> the_region;
+ boost::shared_ptr<MidiRegion> midi_region;
framepos_t current_frame;
mutable gint _auditioning;
Glib::Threads::Mutex lock;
@@ -76,8 +121,18 @@ class LIBARDOUR_API Auditioner : public AudioTrack
bool _seeking;
bool _seek_complete;
bool via_monitor;
+ bool _midi_audition;
+ bool _synth_added;
+ bool _synth_changed;
+ bool _queue_panic;
+
+ boost::shared_ptr<Diskstream> _diskstream_audio;
+ boost::shared_ptr<Diskstream> _diskstream_midi;
+ boost::shared_ptr<Processor> asynth;
void drop_ports ();
+ void lookup_synth ();
+ void config_changed (std::string);
static void *_drop_ports (void *);
void actually_drop_ports ();
void output_changed (IOChange, void*);