2 Copyright (C) 2002-2006 Paul Davis
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 #ifndef __ardour_audio_track_h__
21 #define __ardour_audio_track_h__
23 #include "ardour/interthread_info.h"
24 #include "ardour/track.h"
29 class AudioDiskstream;
32 class AudioFileSource;
34 class LIBARDOUR_API AudioTrack : public Track
37 AudioTrack (Session&, std::string name, TrackMode m = Normal);
40 #ifdef XXX_OLD_DESTRUCTIVE_API_XXX
41 int set_mode (TrackMode m);
42 bool can_use_mode (TrackMode m, bool& bounce_required);
45 int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
46 int declick, bool& need_butler);
48 boost::shared_ptr<Diskstream> create_diskstream ();
49 void set_diskstream (boost::shared_ptr<Diskstream>);
51 DataType data_type () const {
52 return DataType::AUDIO;
55 void freeze_me (InterThreadInfo&);
58 bool bounceable (boost::shared_ptr<Processor>, bool include_endpoint) const;
59 boost::shared_ptr<Region> bounce (InterThreadInfo&);
60 boost::shared_ptr<Region> bounce_range (framepos_t start, framepos_t end, InterThreadInfo&,
61 boost::shared_ptr<Processor> endpoint, bool include_endpoint);
62 int export_stuff (BufferSet& bufs, framepos_t start_frame, framecnt_t nframes,
63 boost::shared_ptr<Processor> endpoint, bool include_endpoint, bool for_export, bool for_freeze);
65 int set_state (const XMLNode&, int version);
67 boost::shared_ptr<AudioFileSource> write_source (uint32_t n = 0);
70 boost::shared_ptr<AudioDiskstream> audio_diskstream () const;
71 XMLNode& state (bool full);
75 boost::shared_ptr<Diskstream> diskstream_factory (XMLNode const &);
77 int deprecated_use_diskstream_connections ();
78 void set_state_part_two ();
79 void set_state_part_three ();
84 #endif /* __ardour_audio_track_h__ */