Add a list of marker locations to the session, for the the UI to add the
current location to when "add-region-cue-marker" happens whilst recording.
On record-stop, create source markers at the locations in that list in all
newly-recorded audio regions.
This change still runs the triggerbox during latency-preroll, but as with the disk reader,
the transport speed argument is set to zero. The triggerbox notices this and behaves
appropriately (I think !)
When an archive are saved, a new folder in interchange/ is created,
named after the archive. However session-archive also retains files
in the session-folder that Ardour does not know about.
This can cause that the the original interchange folder is retained.
It will be empty with just the .DS_Store file in it. The result is
that the session may not load if there is an ambiguity.
Triggerboxen were being executed during the latency preroll phase, which is
inappropriate. ::fast_forward() will prepare them to run at precisely the
correct time. So we add an explicit clause to avoid this.
Found via `codespell -q 3 -S *.po,./.git,./share/patchfiles,./libs,./msvc_extra_headers,./share/web_surfaces,*.patch -L ba,buss,busses,discreet,doubleclick,hsi,ontop,ro,scrollin,seh,siz,sord,sur,te,trough,ue`
Rather than start at zero, we now search backwards for the first relevant cue
before the locate position, making our task in ffwd'ing from there much simpler
since there are no other cues to consider
Also remove Meter:: versions of related methods, because they are not necessary. We
only need metrical information for operations like ::round_to_bar()
* there are rare cases where a midi clip would not advance the ffwd position, looping endlessly
* this problem did not occur when the user chose an explicit Follow Length (different code path)
This workaround bypasses RegionMap and SessionPlaylist APIs
(region_use_count, destroy_region) which are not directly
applicable to Triggerboxes. There are likely various edge
cases until TriggerBoxes integrate with Session Playlist.
e.g. whole file regions generated for regions/source used by
triggerboxes are cleaned up.
A compound region itself may be unused, but the nested source
it provides can be used in another region compound.
In this case the first, unused, region needs to be saved
to save the nested source.
Constructing a playlist from another playlist plus an offset used the wrong
RegionFactory::create method. By failing to pass in the offset to the region
constructor, the newly created region gets its envelope (and possibly other
automation data) from the start of the existing region, not its own start.
There was a logic error previously which failed to consider follow actions (and follow count).
Now we find a relevant cue, and use follow actions and follow counts as we move forward
in time
This fixes an issue with LV2 plugin that unconditionally
initialize LV2 Atom ports even if they are not connected.
eg. JUCE7 produces LV2s at the time of writing.
The actual goal here is to use direct InterpolationStyle serialization
in MidiSource (identical to AutomationList). enum_2_string()
does not work for Evoral types.
As side-effect virtual base-classes have been changed to pass
Parameters as const references
This fixes an issue when creating tracks or busses with a colon
in the name. Renaming those tracks later IO::set_name()
crashed in current_name.replace(std::string::npos,..).
`IO::build_legal_port_name` uses ";" instead of ":" while
`IO::set_name` replaced it with a "-".
Initially the IO name included the colon, so ports created
use a semicolon. But after renaming the IO, ::set_name() applies
the replacement and the IO's name is changed to include the "-".
This leads to a conflict with ports that already have the semicolon
in the port-name.
Loop Location start="a1665678660" end="b145920"
Loop-end (at 122BPM) is a2109859636
at 48kHz this is sample 1794098.32
Now play the loop and play sample 1794098 = a2109859248
Range::squish start: a1665678660 end: a2109859636 squish: a2109859248
squish() does nothing, since there are still 388 superclock-ticks
until the end of the loop.
However, DiskReader::get_midi_playback convertes the value back
to samples(), this leads to effective_start == loop_end;
resulting in an endless loop.
Thanks to MikeLupe to provide a session to reproduce this issue.
So far group-override "inverts" group behavior. Disabled groups
(or group settings) are enabled and vice-versa.
When the setting is disabled, groups can only ever be disabled
(Controllable::NoGroup) and group-override will not enable them
(Controllable::InverseGroup).
This ensures that the user will see a "POOL OUT OF MEMORY" message.
In rare case dumping the pool can segfault when printing the Event,
The pool is zero initialized and only ever contains events, so
in theory it is safe to print them..
When exporting many ranges, locate and restarting transport for
every ranged a SessionEvent::TransportStateChange event is queued.
Since freewheel export does not process events. Those events
can accumulate:
https://discourse.ardour.org/t/pipewire-jack-export-freeze/107383/18?u=x42
During export those requests can be safely ignored because the only
purpose is to emit a TransportStateChange() signal when the playhead
passes a given location and notify the UI.
This fixes automation lanes bleeding into the ruler area.
The bounding box of all items in the main canvas group starts
at -0.5, and the cursor-scroll-group at -1.5. This is calculated
to include line-width, and outlines outside the item(s).
A scroll-group however must not extend its render area to
render those.
The region-gain envelop is an Automation list that uses AudioTime
regardless of the regions own position.
Since the actual audio data is using always using samples this
results in reliable envelopes without the reduced granularity of
BeatTime.
All points the list have to be in the AudioTime domain.
Previously it was possible to have a mixed-domain list e.g.
- add 2h:30min long source
- lock it to music-time
- set grid and snap to 1/8 note
- range select some range shortly after 2:25
- draw region-gain for range
<events>
a0 1
a492113664000 1.0000001192092896
a492113737500 0
a494032822500 0
a494032896000 1.0000003048365
b34560000 1.0000003048365
</events>
jack1 (which is Linux only) does not have a jack_client_stop_thread
API, and expects the application to call pthread_join().
This fixes an issue when the application is compiled using jack2 headers
but the application later runs using jack1's library.
When a session-range coincides with a loop-range location, moving
the session-range also updates the loop-range.
Keeping session and loop-range in sync can be useful if the whole
session is looped. However markers are treated individually, so
we need prevent invalid ranges.
If session-start and loop-start coincide, but loop-end is before the
end-marker, it is possible to move session-start beyond the loop-end.
Automation Controls (and controls in general) are now
only updated in realtime context. Either via automation-playback,
or via SessioEvent. This directly sets the Control:_user_value
(before emitting the Changed signal).
The GUI does not need to evaluate the control at a given point
in time, so the API call can be removed and unified.
This commit first removes all calls to "get_double" to ensure
that no special cases exist.
::automation_run() evaluates the value, possibly ahead of time
depending on latency-compensation. The actual value is set in
realtime-context via set_value_unchecked() -> actually_set_value()
which emits the Changed signal.
At this point in time Control::user_value is already set correctly.
There is no need to evaluate and interpolate again, at a potentially
incorrect (uncompensated) time: `_session.transport_sample()`.
This fixes an issue with the GUI Automation control showing an
outdated value when there is an "immediate jump" in the signal:
eg. add a latent plugin post-fader, then automate the Fader to jump
from 0dB to -inf dB (snap to grid) and play though that transition.
(Plugin controls were not affected by this bug, the process
cycle is split for those, but Mixbus internal AC were affected).
When the loop-range is defined in BeatTime, the disk-reader encounters
rounding issues due to time-domain mismatches.
With a simple session fixed BPM at 120, 48kHz.
looping 1 bar exactly 2 sec at the start of the session:
```
Range::squish start: b0 end: b7680 squish: a113554560
Range::squish using modulo: b45 = a661500
Range::squish using modulo in TD: a5760
Range::squish using earlier(): a658560
```
The correct answer is a113554560 - 2 * 56448000 [SC/sec] = a658560
Calculating the modulo iteratively is not great, however usually
only one iteration is required.