Commit Graph

261 Commits

Author SHA1 Message Date
c44b40afd7
Indicate UTF8 literals - fixes glyph rendering with MSVC (2/2) 2023-01-16 21:41:22 +01:00
e819af1948
Fix clearing automation
Due to refactoring in d41e66f169 and 83ad0a10b5
Automation > Clear re-displayed the line on mouse-over, even
if there are no events. Then trying to interact with he line
caused segfaults because the actual control points no longer exist.
2022-11-01 00:51:53 +01:00
fa71c87358 remove debug output from automation line reset callback 2022-10-27 08:31:57 -06:00
5dd60c03df automation lines: fix missing line segments 2022-10-26 16:57:06 -06:00
83ad0a10b5 automation line: drop ::redisplay() method 2022-10-26 14:01:59 -06:00
d41e66f169 changes to the way automation lines are drawn to show edge-lines
this adds points to the lines so that they always extend to the edge of
regions (not control points).

more work to come to unify ::redisplay() and ::reset_callback()
2022-10-26 14:01:59 -06:00
f32d36f63e fix initialization order warning 2022-10-26 14:01:59 -06:00
a928e35efb significant overhaul of automation region/lines to update during tempo map drags etc 2022-10-25 11:10:36 -06:00
afd23d42cd
Add dedicated InsertReturnLevel type (2/2) 2022-10-14 02:21:50 +02:00
373a73cb51 fix selectability of region-associated automation (i.e. MIDI)
The fix here is really just dropping the use of _offset when computing the session position
of a control point. This was just an arithmetical error.

However, session_sample_position() was redundant and just caused more work, so this
method was removed, and only ::session_position() is now used.

In addition, several closely related places now use C++11 (or later) "auto"
syntax for iterating over containers, for cleaner looking code
2022-08-11 15:26:42 -06:00
Hubert Figuière
9e754959f6 AutomationLine: make sure control points aren't empty
- Otherwise this trigger a C++ assert when built with it
- More reference https://github.com/flathub/org.ardour.Ardour/issues/34
2022-05-28 22:50:06 -04:00
cb85a0a521 fix for automation control point drags: prevent overlapping points in time.
* control points that were already closer than one_tick_in_pixels
 were able to move beyond adjacent points, resulting in out-of-order lines

* prior code was using 'one tick' as the smallest spacing between two
 CPs, but that is larger than the default 'guard point' spacing.  this
 resulted in odd behavior because of the dxt calculation when you moved
 a point that was created as a 'guard point'

For now, use the same 64 samples we use for 'guard points'.  And change
 the 'dxt' calculation logic to more aggressively limit the points from
 overlapping.

TODO:  we might decide that 'one tick' should be the minimum automation
 period throughout ardour.  In that case we should change guard-points.
2022-05-16 07:16:25 -05:00
ca22ba77e1 Constification: make Stateful::get_state() const, with all other required const-ness added (GUI) 2022-04-06 21:56:59 -06:00
f78b54a06d
Fix AutomationLine editing (range based editing)
This fixes various offset issues when editing MIDI (CC)
automation as well as RegionGain range and point based editing.

(It does not fix a related issue that region start-trim
offsets region-gain. Historically region-gain _offset is always
zero, regardless of region->start().
2022-03-17 20:16:07 +01:00
97fe05e4de
Improve GUI HiDPI support
* scale default track heights
* scale region-gain, automation lane control points
* scale max. MIDI note lane height
2022-01-29 22:33:07 +01:00
luz paz
364f2f0788 Fix typos in gtk2_ardour/ directory
Found via `codespell -q 3 -S *.po,./share/patchfiles,./libs -L ba,buss,busses,doubleclick,hsi,ontop,ro,seh,siz,sur,te,trough,ue`
2022-01-26 12:35:38 -05:00
3c03e4951e
Use updated temporal API 2/2 2021-12-11 15:51:31 +01:00
49424ab0e3 Region::_start should be a timepos_t not a timecnt_t (GUI edition) 2021-08-13 12:51:34 -06:00
0162d3f9d6 GUI changes to *try* to adapt to a world without explicit beats<->samples converter objects (i.e. use AutomationLine::get_origin() instead 2021-08-13 12:51:34 -06:00
888239a834 remove dual (x,y) version of AutomationLine::view_to_model_coord()
The x-axis coordinate was never transformed or modified anyway (6.x just changed it
from double to integer and back again!)
2021-08-13 12:51:33 -06:00
2a6b2dfa7c cease using BarTime for anything 2021-08-13 12:51:31 -06:00
3c00fab75e remove/hide Session::tempo_map() and use TempoMap::use() instead (thread local shared ptr) (GUI edition) 2021-08-13 12:51:30 -06:00
cdab3a5e8f fix a bunch of missing symbols related to temporal 2021-08-13 12:51:29 -06:00
f67029bd02 random commit to facilitate trivial move of work from laptop back to main system 2021-08-13 12:51:29 -06:00
9d69fa3820 another day or two's work on timeline type conversion 2021-08-13 12:51:29 -06:00
04e8dbb342 another day of slow timeline type conversion 2021-08-13 12:51:29 -06:00
7433bc27e0 intermediate, unfinished snapshot of ongoing timeline types work on GTK GUI 2021-08-13 12:51:29 -06:00
f4490f54c5 change Timecode::BBT_Time to use Temporal namespace, plus a couple of other minor changes to enable compilation
This still uses the tempo map object in libs/ardour, not the new one in libs/temporal, and isn't likely to be functional
(though it could be)
2021-08-13 12:51:28 -06:00
5c579ed52d
Remove unused #include<> (1/2)
PBD::stacktrace() is not used nor needed by default.
It should be used sparingly.
2021-05-05 17:43:28 +02:00
6ada6c553b
Speed up automation lane removal with many ctrl points
Deleting the group first, directly removes child items
without triggering Canvas::item_changed() for every item.

This significantly speeds up closing sessions (or deleting tracks)
with lots of automation events.
2020-05-20 01:02:36 +02:00
d4ad9e3486
Make BusSendLevel 1st class citizen (2/2) 2019-12-14 15:06:34 +01:00
a855119bdd rename all Evoral source from .(hpp|cpp)$ to .(h|cc) 2019-11-02 16:32:18 -06:00
4050ca5633
Update GPL boilerplate and (C)
Copyright-holder and year information is extracted from git log.

git history begins in 2005. So (C) from 1998..2005 is lost. Also some
(C) assignment of commits where the committer didn't use --author.
2019-08-03 15:53:15 +02:00
86d3735ea8 Fix MIDI Automation interpolation options 2017-10-03 02:20:57 +02:00
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
1545c426d9 Revert "Temporary session-format compatibility (revert before release)"
This reverts commit 8cd8cb1650.
2017-09-18 11:40:52 -04:00
f04bacdfac Drags are such a drag. 2017-07-24 01:59:13 +02:00
601c317d70 Clean up library inheritance (colors.h, utils.h)
make libwidget independent of libcanvas.
Confine basics to pbd and gtkmm2ext.
2017-07-17 21:06:04 +02:00
8cd8cb1650 Temporary session-format compatibility (revert before release)
Saving the new ControlList interpolation methods (enum) breaks loading
the session in older version. The session-format version will
need to be increased.

Until then:
 * Fader automation + region gain envelope uses linear fades
 * The automation-line visible in the GUI does not match the actual fade
   (the y-axis is log/exp-scale, the fade is linear)
 * Adding new points on the line is not using the correct initial value
 * Custom changes of interpolation mode are not available

Neither of these issues is a regression.
2017-06-21 18:13:36 +02:00
fd36355e2c Log-scale/relative automation point dragging 2017-06-21 18:13:03 +02:00
1db9ce4c90 update GUI to use new APIs 2017-06-21 18:13:01 +02:00
555fcb89e5 GUI: prepare for API changes
remove use of
- unbound_min/max
- list->default_value and min/max_y
2017-06-21 18:12:16 +02:00
a869b39cd9 allow automation line fill opacity to be theme-able 2017-01-12 15:21:21 -06:00
fa828e0385 clamp values appropriately in AutomationLine::view_to_model_y()
Before this, drags from one automation track to another could add illegal/stupid values to an automation line. Presumably there needs to be another bounds check in ControlList
2017-01-09 12:41:49 +00:00
cf52d6e4b4 enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h 2016-07-14 14:45:23 -04:00
4f7d3069ab highlight area below automation lanes 2016-07-05 00:39:43 +02:00
8125ea5909 tweak API of Selectable 2016-06-05 20:50:57 -04:00
nick_m
baf8f37967 Tempo ramps - rename meter_at() -> meter_at_frame() & make the ticker slightly more efficient. 2016-05-27 23:38:17 +10:00
nick_m
8f3bc6f809 Tempo ramps - rename tempo_at() -> tempo_at_frame().. 3 decimals for the audioclock tempo display. 2016-05-27 23:38:17 +10:00
42424eeb6c another log-scale automation fix 2015-10-27 20:54:09 +01:00