Commit Graph

54 Commits

Author SHA1 Message Date
Robin Gareus 59b2369736
Remove unused gain-buffer for master-read (NOOP) 2024-04-23 21:52:02 +02:00
Robin Gareus 92fbab32c6
Update codebase to use PBD::Progress (1/2) 2023-05-19 00:37:49 +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 e665d456c3
Optimize RB stretch/pitch, set max-process size hint 2022-10-14 02:21:49 +02:00
Robin Gareus 392210270c
Fix pitch-shift producing partially silent regions
It can happen that with a scaling factor of 1.0, rubberband
produces slightly fewer samples than the original.

Region::set_length (region->length * 1.0) is idempotent and
does not shorten it as appropriate to the longest source
via Region::verify_length(), which leads to various issues.
2022-10-12 22:25:10 +02:00
Robin Gareus 8c83149c4c
Fix time stretch if region-start > 0
For some reason applying the property change
  plist.add (Properties::start, std::numeric_limits<timepos_t>::min());
does not correctly reset the offset of the newly created region.
2022-09-27 13:06:13 +02:00
Paul Davis 5175260af4 temporal: remove dangerous muldiv methods and use explicit method name not cast 2022-05-27 12:47:44 -06:00
luz paz 1e640563d6
Fix source comment typos in `libs/ardour`
Found via `codespell`
2022-05-11 00:14:28 +02:00
Paul Davis 56cde042cd Region::_start should be a timepos_t not a timecnt_t
It is an offset from an *implicit* origin (the source zero), not from an explicit origin,
and this fits with the concept underlying timepos_t. A timecnt_t requires an explicit origin,
which makes no sense in this context (just as it doesn't for the timeline as a whole).
2021-08-13 12:51:34 -06:00
Paul Davis 3197d24f38 fix expression ordering when multiplying region length by ratio_t 2021-08-13 12:51:32 -06:00
Paul Davis 82e84e6b92 change all Region::nt_*() methods to names without the nt_ prefix (library version) 2021-08-13 12:51:30 -06:00
Paul Davis eae9d276fe libardour: conversion to use timeline types (mega-commit) 2021-08-13 12:51:29 -06:00
Paul Davis 889edfd0a0 fixup Region object to work with new factory methods for timeline types (and remove explicit music time-related members) 2021-08-13 12:51:28 -06:00
Paul Davis 67de08e78d more type changes for various Region related methods, using timepos_t/timeline_t 2021-08-13 12:51:28 -06:00
Paul Davis d40bdf5e95 first round of changes to use timeline types, here basically for Region position/length/start
UNFINISHED WORK. Does not compile. But region.cc will compile, hence this snapshot
2021-08-13 12:51:28 -06:00
Robin Gareus 97a221f1bb
NO-OP: whitespace 2020-03-28 01:25:44 +01:00
Robin Gareus 08065e87b5
Minor code cleanup - consolidate variables & scope 2020-03-28 01:25:44 +01:00
Robin Gareus 9b84e61fab
Fix incorrect timestretch duration - #7943
Completing readout available() returns 0, until all
background threads have finished and joined.

This also improves performance by feeding suggested/required
amount of samples on every process() call.
2020-03-28 01:25:44 +01:00
Robin Gareus a22f918d9d
Update libardour GPL boilerplate and (C) from git log 2019-08-03 15:53:16 +02:00
Robin Gareus b8a6f7b052
TimeFx-Filter: do not create a region when operation is canceled 2019-02-26 03:07:49 +01:00
Robin Gareus 5f1e2d4961
Fix never-ending timestretch
This is relevant when time-stretch is canceled. In that case
stretcher.process() is never called with final=true, and hence
stretcher.available() will always return a value >=0.
2019-02-26 01:57:02 +01: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
Ross Lagerwall 2203e03831 Match new[] with delete[] 2016-09-27 18:22:53 +01:00
Paul Davis cf52d6e4b4 enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h 2016-07-14 14:45:23 -04:00
nick_m 94e0a15325 Exact beat - provide audio->music mapping for region split.
- for those not in the know, this series provides a way to
	  remove the temporal distortion introduced when using an
	  audio frame-based gui for music-locked objects.

	  In short, the gui uses an audio frame representation to move
	  objects. It displays the object using frame_at_beat(), quantizing
	  the time value to audio frames. This is fine until the user selects
	  that frame but expects it to be interpreted as a beat.
	  Thus beat_at_frame() would not produce the user-expected beat
	  (temporal quantization error of up to 0.5 audio samples).
	  This is one method of mapping audio time to music time accurately.
2016-07-10 02:18:36 +10:00
David Robillard 976a150e6b Remove obviously dead/redundant code. 2014-11-18 02:55:03 -05:00
David Robillard 881d77f1e5 Constrain variable scopen and avoid uninitialized values existing at all.
Note: dead assignments trigger scan-build dead code warnings, which
initializations do not.
2014-11-18 02:55:03 -05:00
Nils Philippsen 5f00d2f3a7 allow linking unbundled versions of some libraries
(libltc, rubberband, taglib, vamp-sdk)
2013-10-28 09:06:09 +01:00
Paul Davis 241a9edd3e replace final(?) incidences of program name (ardour, Ardour) with PROGRAM_NAME (thanks to edgar for tracking them all down)
git-svn-id: svn://localhost/ardour2/branches/3.0@14050 d708f5d6-7413-0410-9779-e7cbd77b26cf
2013-02-05 18:18:35 +00:00
Carl Hetherington af22f1047d Don't set TimeFXRequest done to true too early; it must only be set after Editor::do_timefx has added its StatefulDiffCommands. Should fix #4897 and duplicates.
git-svn-id: svn://localhost/ardour2/branches/3.0@12597 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-06-07 20:57:21 +00:00
David Robillard 6fa6514cfd Remove over 500 unnecessary includes (including 54 of session.h).
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-05-24 06:09:29 +00:00
Carl Hetherington ddd162bdb0 Make time stretch respect edit groups (#4615).
git-svn-id: svn://localhost/ardour2/branches/3.0@11334 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-01-24 17:04:15 +00:00
Carl Hetherington 2b2d49fffa Set new region length correctly after stretch (part of
#3908).


git-svn-id: svn://localhost/ardour2/branches/3.0@9963 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-08-08 15:36:16 +00:00
David Robillard a473d630eb Fix broken whitespace. I'd apologize for the compile times if it was my fault :D
git-svn-id: svn://localhost/ardour2/branches/3.0@9654 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-06-01 16:50:12 +00:00
Paul Davis d4d5b30aeb remove unused and useless "src" argument for a number of Region property modifying methods
git-svn-id: svn://localhost/ardour2/branches/3.0@9632 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-05-30 13:54:44 +00:00
Carl Hetherington 73192bc1a7 Remove all use of nframes_t.
git-svn-id: svn://localhost/ardour2/branches/3.0@8166 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-12-03 22:26:29 +00:00
Paul Davis b85b4d9e54 make ardour3 build and link on OS X (tiger, at least)
git-svn-id: svn://localhost/ardour2/branches/3.0@8018 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-11-13 05:14:48 +00:00
Carl Hetherington a2885a430b Add progress bar to strip silence dialogue. Fixes #3103.
git-svn-id: svn://localhost/ardour2/branches/3.0@7809 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-20 00:58:25 +00:00
Carl Hetherington a4917c9831 Preserve gain envelopes across filtering operations and stretch them across time stretches. Fixes #902.
git-svn-id: svn://localhost/ardour2/branches/3.0@6989 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-04-26 00:23:40 +00:00
Sampo Savolainen b9876aa1d0 Eliminate double reversible commit from time stretch, and make the stretch operation lengthen / shorten the region as per operation.
git-svn-id: svn://localhost/ardour2/branches/3.0@6318 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-06 21:00:43 +00:00
David Robillard bb9cc45cd2 Strip trailing whitespace and fix other whitespace errors (e.g. space/tab mixing). Whitespace changes only.
Vimmers, try let c_space_errors = 1 in your .vimrc to highlight this kind of stuff in red.  I don't know the emacs equivalent...


git-svn-id: svn://localhost/ardour2/branches/3.0@5773 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-10-14 16:10:01 +00:00
David Robillard 9f77cd9e19 Step towards having both rubberband and soundtouch compiled in at once.
git-svn-id: svn://localhost/ardour2/branches/3.0@4697 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-27 00:59:30 +00:00
David Robillard 1d516ac95a Waf building of rubberband.
Use rubberband over soundtouch with waf for the time being.


git-svn-id: svn://localhost/ardour2/branches/3.0@4669 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-26 01:22:20 +00:00
David Robillard e0aaed6d65 *** NEW CODING POLICY ***
All #include statements that include a header that is a part of a library
bundled with ardour MUST use quotes, not angle brackets.

Do this:

#include "ardour/types.h"

NOT this:

#include <ardour/types.h>

Rationale:

This is best practice in general, to ensure we include the local version
and not the system version.  That quotes mean "local" (in some sense)
and angle brackets mean "system" (in some sense) is a ubiquitous
convention and IIRC right in the C spec somewhere.

More pragmatically, this is required by (my) waf (stuff) for dependencies
to work correctly.  That is:

!!! FAILURE TO DO THIS CAN RESULT IN BROKEN BUILDS !!!

Failure to comply is punishable by death by torture. :)

P.S. It's not that dramatic in all cases, but this (in combination with some
GCC flags specific to the include type) is the best way I have found to be
absolutely 100% positive the local ones are being used (and we definitely
want to be absolutely 100% positive on that one).


git-svn-id: svn://localhost/ardour2/branches/3.0@4655 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-25 18:26:51 +00:00
Carl Hetherington 4e1f451520 Remove unnecessary 0 checks before delete; see http://www.parashift.com/c++-faq-lite/freestore-mgmt.html#faq-16.8 Apologies for the big commit.
git-svn-id: svn://localhost/ardour2/branches/3.0@4332 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-12-18 19:31:00 +00:00
Paul Davis bc89fe0147 most of the 2.X->3.0 commit (up to rev 4299) except for gtk2_ardour/editor_canvas.cc; builds and runs and does a few specific things but expect it to be buggy for a while yet
git-svn-id: svn://localhost/ardour2/branches/3.0@4313 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-12-12 14:43:24 +00:00
Paul Davis c86210a9d5 merge 2.0-ongoing into 3.0 @ 3581 - 3710
git-svn-id: svn://localhost/ardour2/branches/3.0@3712 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-09-10 21:27:39 +00:00
Paul Davis 68e943265e merge from 2.0-ongoing @ 3581
git-svn-id: svn://localhost/ardour2/branches/3.0@3711 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-09-10 15:03:30 +00:00
Paul Davis 449aab3c46 rollback to 3428, before the mysterious removal of libs/* at 3431/3432
git-svn-id: svn://localhost/ardour2/branches/3.0@3435 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-06-02 21:41:35 +00:00
Doug McLain 9c0d7d72d7 remove empty sigc++2 directory
git-svn-id: svn://localhost/ardour2/branches/3.0@3432 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-06-02 05:02:28 +00:00