summaryrefslogtreecommitdiff
path: root/libs/ardour/file_source.cc
AgeCommit message (Collapse)Author
2017-04-19Use XMLNode::get_property() in FileSource classTim Mayberry
2016-12-27Allow gain factor for audio sources.Robin Gareus
In preparation for archiving files as .flac (fixed point), normalized with gain factor.
2016-10-17spelling corrections from Jaromír Mikeš <mira.mikes@seznam.cz>Paul Davis
Corresponds to https://anonscm.debian.org/cgit/pkg-multimedia/ardour.git/tree/debian/patches/0070-spelling.patch
2016-09-21add API to change FileSource path in-placeRobin Gareus
This allows to retain IDs and References of a FileSource, while changing the actual file under the hood (e.g. from .wav to .flac)
2016-09-15Use g_strerror instead of strerror in ARDOUR::FileSourceTim Mayberry
For consistency when calling glib functions and to get UTF-8 strings for display.
2016-09-15Use ::g_rename instead of ::rename in ARDOUR::FileSource classTim Mayberry
The path is in UTF-8 encoding so use Glib functions to properly support paths containing characters that aren't in the system codepage. This fixes Clean-up Unused Sources on Windows where paths contain characters that aren't in the system codepage(usually most non-ascii characters).
2016-09-07correct comment for FileSource::find()Paul Davis
2016-07-14enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.hPaul Davis
2016-05-04OMNIBUS COMMIT: prefer const XMLNode::property method (and provide a real one)Paul Davis
2015-10-05NOOP, remove trailing tabs/whitespace.Robin Gareus
2015-10-04globally remove all trailing whitespace from ardour code base.Paul Davis
Paul Davis was responsible for introducing almost all of this.
2015-09-03Fixes case where audiofiles used wrong peakfilesMathias Buhr
2015-04-20add a pure virtual FileSource::close() method so that FileSource::set_path() ↵Paul Davis
can ensure we no longer have a handle open
2015-01-14get Session::save_as() working much more correctly, and cleanerPaul Davis
2014-12-10remove file manager LRU cache from code.Paul Davis
This was a very clever attempt to fix a non-problem. If the platform doesn't have enough file descriptors available then the platform is broken and we're not going to hack around trying to fix it.
2014-12-06Fix uninitialized members.David Robillard
2014-09-15FileSource should not generate its own error message when a file is missingPaul Davis
2014-07-08initial implementation of "bring all media into session folder". Incomplete ↵Paul Davis
but basically functional for audio files
2014-07-01merge with master.Paul Davis
Manually resolved conflicts in import.cc and session.cc
2014-06-10fix crash recovery: add new constructors to SndFileSource, AudioFileSource, ↵Paul Davis
add a new SourceFactory method and finally tweak AudioDiskstream::use_pending_capture_data() to create both the required whole-file and the in-playlist regions
2014-06-10fix crash recovery: add new constructors to SndFileSource, AudioFileSource, ↵Paul Davis
add a new SourceFactory method and finally tweak AudioDiskstream::use_pending_capture_data() to create both the required whole-file and the in-playlist regions
2014-06-02substantive changes to the logic and safety for naming of (audio/MIDI) ↵Paul Davis
sources, especially when created via import
2014-04-14merge 5764970709f15e85ec30c9cea89c318eb8114c58 from cairocanvas as final(?) ↵Paul Davis
change related to data loss
2014-04-14further code simplification and rationalization related to MIDI source/file ↵Paul Davis
renaming
2014-04-14dramatic change in logic and naming for operations related to adding a MIDI ↵Paul Davis
region on demand and cloning/unlinking Existing code would cause data loss due to creation of two Source objects referring the same path, one with removable flags and one without. Careful code review suggested a variety of thinkos, function naming problems and other confusion that caused this. I have tried ot extensively comment what is going on with these operations, because it is one key area in which MIDI differs from audio: with audio, capture is the only way to add a new audio region, but for MIDI there are GUI input events that can add a new region.
2014-04-14redesign technique for naming/creating regions for MIDI clone (or other ↵Paul Davis
non-capture driven MIDI region creation operations). See comments in Session::new_midi_source_name() for details.
2014-04-14more work on linking file existence and removabilityPaul Davis
2014-04-14further code simplification and rationalization related to MIDI source/file ↵Paul Davis
renaming
2014-04-14dramatic change in logic and naming for operations related to adding a MIDI ↵Paul Davis
region on demand and cloning/unlinking Existing code would cause data loss due to creation of two Source objects referring the same path, one with removable flags and one without. Careful code review suggested a variety of thinkos, function naming problems and other confusion that caused this. I have tried ot extensively comment what is going on with these operations, because it is one key area in which MIDI differs from audio: with audio, capture is the only way to add a new audio region, but for MIDI there are GUI input events that can add a new region.
2014-04-10redesign technique for naming/creating regions for MIDI clone (or other ↵Paul Davis
non-capture driven MIDI region creation operations). See comments in Session::new_midi_source_name() for details.
2014-02-10string fix up, IIPaul Davis
2014-02-10string fix upPaul Davis
2014-02-07merge with master, with minor conflict fixesPaul Davis
2014-02-07Fix egregious logic bug in FileSource::removable() and introduce ↵Paul Davis
FileSource::is_stub() to hide logic for deciding if a source (file) is a stub
2013-08-04'libs/ardour' - Platform specific changes and includesJohn Emmas
2013-07-15Fix portability of Session::source_search_pathPaul Davis
2013-07-15Don't use errno after g_file_test on windowsPaul Davis
2013-03-31remove debug outputPaul Davis
2013-03-31more work on the suprisingly ongoing filename/path/origin issuePaul Davis
2013-03-30fix up some confusion with filesources' _origin and _file_is_new members. if ↵Paul Davis
_origin is set, it means that the file is "external" to the session (aka "embedded") and for some purposes this is more significant than _file_is_new. rename SourceFactory::createReadable() to ::createExternal() to more clearly indicate its purpose; remove never-supplied "origin" argument from SourceFactor::createWritable(). Fixes problems caused by 864ce8f0
2013-03-30if a filesource is supposed to be new, don't waste time looking for it. if ↵Paul Davis
it has its _origin member set, search for that, not its name (affects embedded files)
2012-07-25convert from Glib:: to Glib::Threads for all thread-related APIPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@13084 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-07-16do NOT mark imported MIDI files as un-writable - all MIDI files are subject ↵Paul Davis
to rewriting at any time git-svn-id: svn://localhost/ardour2/branches/3.0@13046 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-23Move three file utility functions from pbd/filesystem.h to pbd/file_utils.hTim Mayberry
git-svn-id: svn://localhost/ardour2/branches/3.0@12863 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-23Rename PBD::sys::inodes_same to equivalent_pathsTim Mayberry
This better reflects its function and more closely matches boost naming(which is usually a good sign) git-svn-id: svn://localhost/ardour2/branches/3.0@12857 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-23Remove two unnecessary header includes of pbd/mountpoint.hTim Mayberry
git-svn-id: svn://localhost/ardour2/branches/3.0@12826 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-28Add path_is_within to decide if a path is within a givenCarl Hetherington
directory, taking symlinks into account, and use it to decide whether a file is within the session folder. Should fix #4552. git-svn-id: svn://localhost/ardour2/branches/3.0@12468 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-27don't alter session search path frm within FileSource constructor, do it ↵Paul Davis
when a source is added to the session; related - don't add sources that are created with announce=false to the session, and as a (new) corollary, no longer cause them to potentially alter the session search path (this applies mostly to sources created for auditioning) git-svn-id: svn://localhost/ardour2/branches/3.0@12456 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-24Remove over 500 unnecessary includes (including 54 of session.h).David Robillard
It's slightly possible that this causes trivial build failures on different configurations, but otherwise shouldn't cause any problems (i.e. no actual changes other than include/naming/namespace stuff). I deliberately avoided removing libardour-config.h since this can mysteriously break things, though a few of those do seem to be unnecessary. This commit only targets includes of ardour/*.h. There is also a very large number of unnecessary includes of stuff in gtk2_ardour; tackling that should also give a big improvement in build time when things are modified. git-svn-id: svn://localhost/ardour2/branches/3.0@12420 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-03-05Use inodes_same() function.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@11591 d708f5d6-7413-0410-9779-e7cbd77b26cf