mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 23:35:03 +01:00
Merge branch 'master' into cairocanvas
This commit is contained in:
commit
b880a38152
13 changed files with 36 additions and 39 deletions
|
|
@ -4891,8 +4891,10 @@ Editor::add_routes (RouteList& routes)
|
||||||
rtv->view()->RegionViewRemoved.connect (sigc::mem_fun (*this, &Editor::region_view_removed));
|
rtv->view()->RegionViewRemoved.connect (sigc::mem_fun (*this, &Editor::region_view_removed));
|
||||||
}
|
}
|
||||||
|
|
||||||
_routes->routes_added (new_views);
|
if (new_views.size() > 0) {
|
||||||
_summary->routes_added (new_views);
|
_routes->routes_added (new_views);
|
||||||
|
_summary->routes_added (new_views);
|
||||||
|
}
|
||||||
|
|
||||||
if (show_editor_mixer_when_tracks_arrive) {
|
if (show_editor_mixer_when_tracks_arrive) {
|
||||||
show_editor_mixer (true);
|
show_editor_mixer (true);
|
||||||
|
|
|
||||||
|
|
@ -897,8 +897,6 @@ ExportFormatDialog::show_ogg_enconding_options (boost::shared_ptr<ARDOUR::Export
|
||||||
encoding_options_table.resize (1, 1);
|
encoding_options_table.resize (1, 1);
|
||||||
encoding_options_table.attach (tag_checkbox, 0, 1, 0, 1);
|
encoding_options_table.attach (tag_checkbox, 0, 1, 0, 1);
|
||||||
|
|
||||||
update_tagging_selection ();
|
|
||||||
|
|
||||||
show_all_children ();
|
show_all_children ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -33,17 +33,7 @@ public:
|
||||||
AudioBuffer(size_t capacity);
|
AudioBuffer(size_t capacity);
|
||||||
~AudioBuffer();
|
~AudioBuffer();
|
||||||
|
|
||||||
void silence (framecnt_t len, framecnt_t offset = 0) {
|
void silence (framecnt_t len, framecnt_t offset = 0);
|
||||||
if (!_silent) {
|
|
||||||
assert(_capacity > 0);
|
|
||||||
assert(offset + len <= _capacity);
|
|
||||||
memset(_data + offset, 0, sizeof (Sample) * len);
|
|
||||||
if (len == _capacity) {
|
|
||||||
_silent = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
_written = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Read @a len frames @a src starting at @a src_offset into self starting at @ dst_offset*/
|
/** Read @a len frames @a src starting at @a src_offset into self starting at @ dst_offset*/
|
||||||
void read_from (const Sample* src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
void read_from (const Sample* src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
||||||
|
|
@ -204,10 +194,11 @@ public:
|
||||||
|
|
||||||
Sample* data (framecnt_t offset = 0) {
|
Sample* data (framecnt_t offset = 0) {
|
||||||
assert(offset <= _capacity);
|
assert(offset <= _capacity);
|
||||||
|
_silent = false;
|
||||||
return _data + offset;
|
return _data + offset;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool check_silence (pframes_t, pframes_t&) const;
|
bool check_silence (pframes_t, bool, pframes_t&) const;
|
||||||
|
|
||||||
void prepare () { _written = false; _silent = false; }
|
void prepare () { _written = false; _silent = false; }
|
||||||
bool written() const { return _written; }
|
bool written() const { return _written; }
|
||||||
|
|
|
||||||
|
|
@ -62,7 +62,6 @@ public:
|
||||||
DataType type() const { return _type; }
|
DataType type() const { return _type; }
|
||||||
|
|
||||||
bool silent() const { return _silent; }
|
bool silent() const { return _silent; }
|
||||||
void set_is_silent(bool yn) { _silent = yn; }
|
|
||||||
|
|
||||||
/** Reallocate the buffer used internally to handle at least @a size_t units of data.
|
/** Reallocate the buffer used internally to handle at least @a size_t units of data.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,6 @@ public:
|
||||||
const ChanCount& count() const { return _count; }
|
const ChanCount& count() const { return _count; }
|
||||||
ChanCount& count() { return _count; }
|
ChanCount& count() { return _count; }
|
||||||
|
|
||||||
void set_is_silent(bool yn);
|
|
||||||
void silence (framecnt_t nframes, framecnt_t offset);
|
void silence (framecnt_t nframes, framecnt_t offset);
|
||||||
bool is_mirror() const { return _is_mirror; }
|
bool is_mirror() const { return _is_mirror; }
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -76,12 +76,26 @@ AudioBuffer::resize (size_t size)
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
AudioBuffer::check_silence (pframes_t nframes, pframes_t& n) const
|
AudioBuffer::check_silence (pframes_t nframes, bool wholebuffer, pframes_t& n) const
|
||||||
{
|
{
|
||||||
for (n = 0; n < _size && n < nframes; ++n) {
|
for (n = 0; (wholebuffer || n < _size) && n < nframes; ++n) {
|
||||||
if (_data[n] != Sample (0)) {
|
if (_data[n] != Sample (0)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
AudioBuffer::silence (framecnt_t len, framecnt_t offset) {
|
||||||
|
pframes_t n = 0;
|
||||||
|
if (!_silent) {
|
||||||
|
assert(_capacity > 0);
|
||||||
|
assert(offset + len <= _capacity);
|
||||||
|
memset(_data + offset, 0, sizeof (Sample) * len);
|
||||||
|
if (len == _capacity) {
|
||||||
|
_silent = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_written = true;
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -468,16 +468,5 @@ BufferSet::silence (framecnt_t nframes, framecnt_t offset)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
BufferSet::set_is_silent (bool yn)
|
|
||||||
{
|
|
||||||
for (std::vector<BufferVec>::iterator i = _buffers.begin(); i != _buffers.end(); ++i) {
|
|
||||||
for (BufferVec::iterator b = i->begin(); b != i->end(); ++b) {
|
|
||||||
(*b)->set_is_silent (yn);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace ARDOUR
|
} // namespace ARDOUR
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -25,12 +25,14 @@
|
||||||
|
|
||||||
#include "pbd/convert.h"
|
#include "pbd/convert.h"
|
||||||
|
|
||||||
|
#include "ardour/audiofile_tagger.h"
|
||||||
#include "ardour/export_graph_builder.h"
|
#include "ardour/export_graph_builder.h"
|
||||||
#include "ardour/export_timespan.h"
|
#include "ardour/export_timespan.h"
|
||||||
#include "ardour/export_channel_configuration.h"
|
#include "ardour/export_channel_configuration.h"
|
||||||
#include "ardour/export_status.h"
|
#include "ardour/export_status.h"
|
||||||
#include "ardour/export_format_specification.h"
|
#include "ardour/export_format_specification.h"
|
||||||
#include "ardour/export_filename.h"
|
#include "ardour/export_filename.h"
|
||||||
|
#include "ardour/session_metadata.h"
|
||||||
|
|
||||||
#include "i18n.h"
|
#include "i18n.h"
|
||||||
|
|
||||||
|
|
@ -280,13 +282,18 @@ ExportHandler::finish_timespan ()
|
||||||
while (config_map.begin() != timespan_bounds.second) {
|
while (config_map.begin() != timespan_bounds.second) {
|
||||||
|
|
||||||
ExportFormatSpecPtr fmt = config_map.begin()->second.format;
|
ExportFormatSpecPtr fmt = config_map.begin()->second.format;
|
||||||
|
std::string filename = config_map.begin()->second.filename->get_path(fmt);
|
||||||
|
|
||||||
if (fmt->with_cue()) {
|
if (fmt->with_cue()) {
|
||||||
export_cd_marker_file (current_timespan, fmt, config_map.begin()->second.filename->get_path(fmt), CDMarkerCUE);
|
export_cd_marker_file (current_timespan, fmt, filename, CDMarkerCUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fmt->with_toc()) {
|
if (fmt->with_toc()) {
|
||||||
export_cd_marker_file (current_timespan, fmt, config_map.begin()->second.filename->get_path(fmt), CDMarkerTOC);
|
export_cd_marker_file (current_timespan, fmt, filename, CDMarkerTOC);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (fmt->tag()) {
|
||||||
|
AudiofileTagger::tag_file(filename, *SessionMetadata::Metadata());
|
||||||
}
|
}
|
||||||
|
|
||||||
config_map.erase (config_map.begin());
|
config_map.erase (config_map.begin());
|
||||||
|
|
|
||||||
|
|
@ -505,7 +505,6 @@ PluginInsert::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end
|
||||||
* all buffers appropriately.
|
* all buffers appropriately.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
bufs.set_is_silent (false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
|
|
@ -116,7 +116,6 @@ PortInsert::run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame,
|
||||||
|
|
||||||
_mtdm->process (nframes, in, out);
|
_mtdm->process (nframes, in, out);
|
||||||
|
|
||||||
outbuf.set_is_silent (false);
|
|
||||||
outbuf.set_written (true);
|
outbuf.set_written (true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -96,6 +96,7 @@ Route::Route (Session& sess, string name, Flag flg, DataType default_type)
|
||||||
, _have_internal_generator (false)
|
, _have_internal_generator (false)
|
||||||
, _solo_safe (false)
|
, _solo_safe (false)
|
||||||
, _default_type (default_type)
|
, _default_type (default_type)
|
||||||
|
, _order_key (0)
|
||||||
, _has_order_key (false)
|
, _has_order_key (false)
|
||||||
, _remote_control_id (0)
|
, _remote_control_id (0)
|
||||||
, _in_configure_processors (false)
|
, _in_configure_processors (false)
|
||||||
|
|
@ -418,8 +419,6 @@ Route::process_output_buffers (BufferSet& bufs,
|
||||||
framepos_t start_frame, framepos_t end_frame, pframes_t nframes,
|
framepos_t start_frame, framepos_t end_frame, pframes_t nframes,
|
||||||
int declick, bool gain_automation_ok)
|
int declick, bool gain_automation_ok)
|
||||||
{
|
{
|
||||||
bufs.set_is_silent (false);
|
|
||||||
|
|
||||||
/* figure out if we're going to use gain automation */
|
/* figure out if we're going to use gain automation */
|
||||||
if (gain_automation_ok) {
|
if (gain_automation_ok) {
|
||||||
_amp->set_gain_automation_buffer (_session.gain_automation_buffer ());
|
_amp->set_gain_automation_buffer (_session.gain_automation_buffer ());
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,7 @@ class MidiClockTicker::Position : public Timecode::BBT_Time
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
Position() : speed(0.0f), frame(0) { }
|
Position() : speed(0.0f), frame(0), midi_beats(0) { }
|
||||||
~Position() { }
|
~Position() { }
|
||||||
|
|
||||||
/** Sync timing information taken from the given Session
|
/** Sync timing information taken from the given Session
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
#include <stdbool.h>
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
|
||||||
#ifndef BUFFER_SIZE_SAMPLES
|
#ifndef BUFFER_SIZE_SAMPLES
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue