sscanf (prop->value().c_str(), "%d", &x);
set_remote_control_id (x);
}
+
+ } else if (child->name() == X_("recenable")) {
+ _rec_enable_control.set_state (*child);
+ _session.add_controllable (&_rec_enable_control);
}
}
for (vector<FreezeRecordInsertInfo*>::iterator i = _freeze_record.insert_info.begin(); i != _freeze_record.insert_info.end(); ++i) {
inode = new XMLNode (X_("insert"));
- (*i)->id.print (buf);
+ (*i)->id.print (buf, sizeof (buf));
inode->add_property (X_("id"), buf);
inode->add_child_copy ((*i)->state);
diskstream.
*/
- _diskstream->id().print (buf);
+ _diskstream->id().print (buf, sizeof (buf));
root.add_property ("diskstream-id", buf);
+ root.add_child_nocopy (_rec_enable_control.get_state());
+
return root;
}
}
void
-AudioTrack::passthru_silence (jack_nframes_t start_frame, jack_nframes_t end_frame, jack_nframes_t nframes, jack_nframes_t offset, int declick, bool meter)
+AudioTrack::passthru_silence (nframes_t start_frame, nframes_t end_frame, nframes_t nframes, nframes_t offset, int declick, bool meter)
{
uint32_t nbufs = n_process_buffers ();
process_output_buffers (_session.get_silent_buffers (nbufs), nbufs, start_frame, end_frame, nframes, offset, true, declick, meter);
}
int
-AudioTrack::no_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame, jack_nframes_t offset,
+AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset,
bool session_state_changing, bool can_record, bool rec_monitors_input)
{
if (n_outputs() == 0) {
send_silence = true;
} else {
- if (_session.get_auto_input()) {
- if (Config->get_use_sw_monitoring()) {
+ if (Config->get_auto_input()) {
+ if (Config->get_monitoring_model() == SoftwareMonitoring) {
send_silence = false;
} else {
send_silence = true;
}
} else {
if (_diskstream->record_enabled()) {
- if (Config->get_use_sw_monitoring()) {
+ if (Config->get_monitoring_model() == SoftwareMonitoring) {
send_silence = false;
} else {
send_silence = true;
}
int
-AudioTrack::roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame, jack_nframes_t offset, int declick,
+AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset, int declick,
bool can_record, bool rec_monitors_input)
{
int dret;
Sample* b;
Sample* tmpb;
- jack_nframes_t transport_frame;
+ nframes_t transport_frame;
boost::shared_ptr<AudioDiskstream> diskstream = audio_diskstream();
{
just_meter_input (start_frame, end_frame, nframes, offset);
}
- if (diskstream->record_enabled() && !can_record && !_session.get_auto_input()) {
+ if (diskstream->record_enabled() && !can_record && !Config->get_auto_input()) {
/* not actually recording, but we want to hear the input material anyway,
at least potentially (depending on monitoring options)
}
}
- process_output_buffers (bufs, limit, start_frame, end_frame, nframes, offset, (!_session.get_record_enabled() || !_session.get_do_not_record_plugins()), declick, (_meter_point != MeterInput));
+ process_output_buffers (bufs, limit, start_frame, end_frame, nframes, offset, (!_session.get_record_enabled() || !Config->get_do_not_record_plugins()), declick, (_meter_point != MeterInput));
} else {
/* problem with the diskstream; just be quiet for a bit */
}
int
-AudioTrack::silent_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame, jack_nframes_t offset,
+AudioTrack::silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset,
bool can_record, bool rec_monitors_input)
{
if (n_outputs() == 0 && _redirects.empty()) {
}
int
-AudioTrack::export_stuff (vector<Sample*>& buffers, uint32_t nbufs, jack_nframes_t start, jack_nframes_t nframes)
+AudioTrack::export_stuff (vector<Sample*>& buffers, uint32_t nbufs, nframes_t start, nframes_t nframes)
{
gain_t gain_automation[nframes];
gain_t gain_buffer[nframes];
for (bi = buffers.begin(); bi != buffers.end(); ++bi) {
Sample *b = *bi;
- for (jack_nframes_t n = 0; n < nframes; ++n) {
+ for (nframes_t n = 0; n < nframes; ++n) {
b[n] *= gain_automation[n];
}
}
for (bi = buffers.begin(); bi != buffers.end(); ++bi) {
Sample *b = *bi;
- for (jack_nframes_t n = 0; n < nframes; ++n) {
+ for (nframes_t n = 0; n < nframes; ++n) {
b[n] *= this_gain;
}
}
void
AudioTrack::bounce (InterThreadInfo& itt)
{
- vector<AudioSource*> srcs;
+ vector<boost::shared_ptr<AudioSource> > srcs;
_session.write_one_audio_track (*this, 0, _session.current_end_frame(), false, srcs, itt);
}
void
-AudioTrack::bounce_range (jack_nframes_t start, jack_nframes_t end, InterThreadInfo& itt)
+AudioTrack::bounce_range (nframes_t start, nframes_t end, InterThreadInfo& itt)
{
- vector<AudioSource*> srcs;
+ vector<boost::shared_ptr<AudioSource> > srcs;
_session.write_one_audio_track (*this, start, end, false, srcs, itt);
}
void
AudioTrack::freeze (InterThreadInfo& itt)
{
- vector<AudioSource*> srcs;
+ vector<boost::shared_ptr<AudioSource> > srcs;
string new_playlist_name;
Playlist* new_playlist;
string dir;