Commit Graph

87 Commits

Author SHA1 Message Date
Robin Gareus 300de26b3e
Fix XML read error when creating new export profiles
Previously creating a new preset first attempted to load
it from disk, before creating it. This resulted in a
`XML error: failed to load external entity`.
2023-09-25 22:36:24 +02:00
Robin Gareus a3a30e39df
Fix silent stem export channels (#9294)
When toggling a channel-configs the following happens:

 1. TrackExportChannelSelector::update_config
 2. ExportProfileManager::clear_channel_configs
 3. RouteExportChannel::create_from_route
[...] CriticalSelectionChanged
 4. ExportDialog::update_warnings_and_example_filename
 5. ARDOUR::ExportProfileManager::get_warnings
 6. ARDOUR::ExportProfileManager::build_filenames
 7. ARDOUR::ExportFilename::set_channel_config
[...]


Step 3 creates a RouteExportChannel, Step 7 retains a
shared-pointer to it in the config's ExportFilenamePtr.
When toggling another channel: step 2 release the reference
and step 3 creates a new RouteExportChannel.
This new channel reuses the existing Route::_capture_processor (!).

Now Step 7 releases the first RouteExportChannel in order
to get_warnings for the new one. Since ExportFilenamePtr holds the
the last reference, the d'tor of RouteExportChannel runs,
which removes the capture-processor from the route.

The newly created RouteExportChannel now has a reference
to a CaptureProcessor that is not in the signal-flow.


Note: the order of adding/removing RouteExportChannel matters.
With a two track session:
 * Disable "with track/bus processing
 * Enable Track 1
 * Enable Track 2
 * Disable Track 1
 * Enable Track 1 // << Track 2 becomes silent
2023-04-03 15:53:50 +02:00
Paul Davis b35518e212 switch from boost::{shared,weak}_ptr to std::{shared,weak}_ptr
This is mostly a simple lexical search+replace but the absence of operator< for
std::weak_ptr<T> leads to some complications, particularly with Evoral::Sequence
and ExportPortChannel.
2023-03-24 14:19:15 -06:00
Robin Gareus caec9acf8d
Export: check all channel-configurations before export
This correctly sets up the filename, and lists all existing
files that will be replaced on export.
2023-02-04 00:21:09 +01:00
Robin Gareus a0a49b9769
Prevent crash if export format is N/A
This can happen when trying to use the mp3 preset
while there is no mp3 encoder available.
2022-11-04 22:10:19 +01:00
Mads Kiilerich 07c370bdc9 Handle exception from export formats with unknown enum values
Before, an export format with an invalid enum value (for example in the
Encoding id) would crash Ardour with:

	unhandled exception (type std::exception) in signal handler:
	what: unknown enumerator FOO in PBD::EnumWriter

That kind of error can happen if a new type is introduced and users
switch back to versions without it.

Instead, catch such exceptions while loading a format, log an error, and
skip the format - similar to how other format loading errors are
handled.
2022-11-04 03:52:45 +01:00
Robin Gareus d55d3a7360
Save/load export timespan realtime setting 2022-05-15 02:20:19 +02:00
Robin Gareus 4577f86aa0
NO-OP: clang-format 2022-05-15 02:19:46 +02:00
Paul Davis eae9d276fe libardour: conversion to use timeline types (mega-commit) 2021-08-13 12:51:29 -06:00
Robin Gareus df47da4e55
Disambiguate export filename early on
When exporting multiple formats with identical filename
extension for the same time-span, the format-name needs
to be added.

Previously that was done internally when starting to export.
The Export-Dialog did not show correct filenames nor
warn of existing files that will be overwritten.
2021-04-12 23:15:30 +02:00
Edgar Aichinger 70937dc1f9
Fix typos in preparation for translations 2020-04-13 16:10:13 +02:00
Robin Gareus 3ff1541825
Fix export w/o session-range (typo in 468731c14b) 2019-10-15 23:17:48 +02:00
Paul Davis 468731c14b goodbye Profile->...trx 2019-09-25 13:02:31 -06:00
Robin Gareus a22f918d9d
Update libardour GPL boilerplate and (C) from git log 2019-08-03 15:53:16 +02:00
Robin Gareus 2f91bdfa53
NO-OP: <tab> after <space> fixes in libs 2019-04-13 19:19:29 +02:00
Robin Gareus 9326ced760 Allow to revert export-format from disk
This allows to restore ProfileManager's ExportFormatSpec without
re-instantiating the ProfileManager.
2018-11-21 23:14:52 +01:00
Robin Gareus 27e0e78e1d Implement FFMPEG/MP3 export-format spec and profile 2018-11-20 00:21:01 +01:00
Robin Gareus df72e1ba4f Initial backend support for external export encoder
This adds an experimental pipe to ffmpeg to encode mp3. Currently
quality is hardcoded and various aspects remain to be implemented.
However, it is sufficient for initial testing.
2018-11-19 05:21:17 +01:00
Robin Gareus 0dc9c068e7 Don't allow invalid export Locations (when using the GUI) 2018-07-25 18:21:19 +02:00
Robin Gareus ff5cc4a311 Reset export-config maps before each new export (1/2) 2018-07-25 18:19:55 +02:00
Paul Davis 30b087ab3d globally change all use of "frame" to refer to audio into "sample".
Generated by tools/f2s. Some hand-editing will be required in a few places to fix up comments related to timecode
and video in order to keep the legible
2017-09-18 12:39:17 -04:00
Tim Mayberry 34ee50d171 Use XMLNode::get/set_property in ARDOUR::ExportProfileManager class 2017-04-19 09:36:51 +10:00
Tim Mayberry ce16b5424f Fix crash when ExportDialog is hidden
The issue is that when ExportDialog is destroyed
ExportFileNotebook::FilePage::on_hide is called which in turn calls
ExportProfileManager::save_format_to_disk() in order to save changes to the
analysis and soundcloud upload checkboxes. This then causes the
ExportProfileManager::FormatListChanged signal to be emitted, which in all
other cases is emitted when the format list is modified so that the GUI can
rebuild the format selector menu in ExportFormatSelector::update_format_list
when a format is added or removed.

The problem when doing this in the destructor is that some of the widgets have
already been destroyed, specifically the issue was in
ExportFileNotebook::update_soundcloud_upload trying to access the
soundcloud_selector member that had already had its destructor called.

As it is not necessary to call this signal in the first place and it just
causes unnecessary GUI updates remove the signal emission.
2016-09-17 22:03:16 +10:00
Tim Mayberry ac4ad28b4f Fix indentation in ARDOUR::ExportProfileManager source file 2016-09-17 22:03:16 +10:00
Robin Gareus 9eaced4c9d allow to query export profile type 2016-07-16 02:14:27 +02:00
Paul Davis cf52d6e4b4 enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h 2016-07-14 14:45:23 -04:00
Robin Gareus 80cc70966c missing local export config is not an error 2016-05-25 13:56:11 +02:00
Paul Davis 17ace643e4 OMNIBUS COMMIT: prefer const XMLNode::property method (and provide a real one) 2016-05-04 23:09:45 -04:00
Robin Gareus 2397429e99 use quotes for in-tree pbd/glib wrapper include 2015-10-05 22:15:18 +02:00
Robin Gareus 22b07e0233 NOOP, remove trailing tabs/whitespace. 2015-10-05 16:17:49 +02:00
Robin Gareus 7ac691ec82 use pbd's gstdio compatibility wrapper 2015-09-17 14:37:57 +02:00
Robin Gareus c342769925 allow to export loop-range w/o looping. fixes #6508 2015-08-14 02:32:29 +02:00
Paul Davis a6a522766b add required header 2015-06-29 14:18:12 -04:00
Paul Davis 0b1a10b2d5 make use of loop range as default export range being Tracks specific 2015-06-29 14:18:12 -04:00
VKamyshniy 14226356d8 [Summary] Per Igor's request: if auto play loop is set on, the main timespan should be the range loop location. 2015-06-29 14:18:11 -04:00
nick_m 7099f0ec4e Add backwards compatibility for instant.xml changes. 2014-08-14 03:19:40 +10:00
nick_m 34bf7457c6 Move ExportProfile xml from Session instant.xml to session file. 2014-08-14 02:52:42 +10:00
Tim Mayberry 8d0cba3384 Use PBD::find_files_matching_pattern instead of other variations 2014-06-25 12:40:10 -04:00
John Emmas d1fd112bdf Transfer 'export_formats_search_path()' into 'libs/ardour/search_paths.cc' 2014-03-10 16:24:06 +00:00
Paul Davis f0ddf5281b debugging export format UUID creation 2014-02-14 17:41:45 -05:00
Paul Davis 133251db91 possible fix for error during export format load-from-disk 2014-02-14 16:33:44 -05:00
Paul Davis 1b21eec042 Fix for ambiguity of UUID type on windows 2013-07-11 14:13:55 -04:00
Sakari Bergen b01ff11b04 Return null if deserializing an export timespan doesn't succeed with at least one range.
This should fix an issue with loading old sessions using the old way of
handling session ranges specially.
2013-05-26 21:25:22 +03:00
Sakari Bergen 0a364fd991 Remove special handling of session range in export. Fixes things when the session range is renamed. 2013-05-26 20:25:27 +03:00
Robin Gareus ee426ca223 fix crash on export if no master bus is present in the session 2013-05-06 00:15:48 +02:00
Sakari Bergen 526a1a71fe Make export type an enum and pass it to the profile manager instead of the xml node name.
Use this to always include the channel configuration name in stem exports.


git-svn-id: svn://localhost/ardour2/branches/3.0@13616 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-12-07 21:58:33 +00:00
Paul Davis 1cdf02ae2f remove use of boost::thread/boost::mutex; bump glibmm requirement to 2.30 in order to pick up Glib::Threads::Mutex which can be used statically, use that to replace boost::mutex; add required inclusion of <cerrno> in a couple of places
git-svn-id: svn://localhost/ardour2/branches/3.0@13076 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-07-24 21:43:05 +00:00
Paul Davis e6610e6ad8 i18n fixes from alexander prokoudine (#5016)
git-svn-id: svn://localhost/ardour2/branches/3.0@13050 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-07-17 13:11:15 +00:00
Tim Mayberry 7e7d053f53 Replace use of PBD::sys::path in ExportProfileManager
git-svn-id: svn://localhost/ardour2/branches/3.0@12831 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-23 05:07:00 +00:00
Tim Mayberry 105caf23da Use std::string instead of PBD::sys::path in pbd/search_path.h, pbd/file_utils.h and ardour/session_dir.h
git-svn-id: svn://localhost/ardour2/branches/3.0@12829 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-23 05:06:54 +00:00