summaryrefslogtreecommitdiff
path: root/libs/ardour/session_transport.cc
AgeCommit message (Collapse)Author
2020-05-17Fix repeated toggling of loop modeMark Knoop
Calling Session::set_play_loop repeatedly (e.g. LLL) should toggle in and out of loop play. Previously transport needed to be stopped before loop play could be started for a second or subsequent time. This uses the loop_changing boolean to flag that Session::non_realtime_stop should not unset the loop. Also, Session::non_realtime_stop must reset loop_changing to false after use so it does not affect the next transport action.
2020-05-13update DiskReader loop delick objects when loop changesPaul Davis
2020-05-13reinstate Session::loop_changing to avoid problems when locating to start of ↵Paul Davis
loop for loop play
2020-05-12essentially a no-op to just make conditional clearer more explicitPaul Davis
2020-05-12find a different way to NOT unset play loop when locating to start of loopPaul Davis
2020-05-12remove Session::loop_changingPaul Davis
Since we now (correctly) do not locate for loop changes, this member is unnecessary
2020-05-12remove #ifdef'ed codePaul Davis
2020-05-12restore mistakenly remove condition for locatingPaul Davis
2020-05-12remove debug/information messagePaul Davis
2020-05-12As in previous commit, never locate because of loop handlingPaul Davis
2020-05-12We use seamless looping always now. Never any need to locate for loop changesPaul Davis
2020-05-12make conditional logic fully explicitPaul Davis
2020-05-07Remove unused variableRobin Gareus
2020-04-24fix thinko in Session::should_ignore_transport_request() and drop out of ↵Paul Davis
external sync if command is allowed The semantics are that if the user configures things to allow transport commands while using a transport master, issuing such commands first stops using the master
2020-04-24make Session::should_ignore_transport_request() non-constPaul Davis
2020-04-23Clean up Audition realtime_overwriteRobin Gareus
Auditioner seek calls are explicitly handled by the butler, and DR:overwrite_existing_buffers() is called explicitly to read MIDI data for audition. Session::non_realtime_overwrite is no longer required. This reverts commit 6fbcf837793ec9a8347fd2d12823b9e56587ffc0 and parts of 2d11667ce3d2ada93c0fb90978bdcc054413c2bb.
2020-04-23Fix MIDI auditioningRobin Gareus
The Auditioner is not part of the session route-list and the auditioner route's I/O latency is never updated. Session::process_audition() does not handle pre-roll either, so it need to be zeroed, otherwise Route::roll skips samples. This has lead to initial samples being skipped, IFF the auditioner's output-port had non-zero latency. Since private port-latencies are usually only set for routes in the route-list, and _remaining_latency_preroll is reset at transport-stop, this *usually* worked... Last but not least, MIDI notes need to be resolved when seeking.
2020-04-23Don't add the Auditioner to the route-listRobin Gareus
This fixes a bug introduce in 2d11667ce3. The Auditoner was accidentally added to the shared_ptr<> referenced RouteList.
2020-04-22Fix MIDI audition and audition seekingRobin Gareus
DiskReader::seek() no longer fills MIDI buffers. MIDI is now read into memory via DR:overwrite_existing_buffers() There is still some edge-case remaining to be fixed. For some reasons the synth does not receive initial patch/program changes when starting auditioning.
2020-04-18RAII collect processor-change signals6.0-rc1Robin Gareus
2020-04-10Revert "Another attempt at fixing multi-range export"Robin Gareus
This reverts commit c5332ddd0092c3a73315923a90c41024c0ad7758. Apparently this is not needed 4f3a95a1da is sufficient.
2020-04-09Another attempt at fixing multi-range exportRobin Gareus
See also * 4f3a95a1da9 * cfd95340b18 * 61e7f3176bf
2020-04-09Cont'd work on fixing export rangesRobin Gareus
This picks up where cfd95340b1 left off. The goal is to ensure that the butler has completed all PostTransportStop related tasks and won't meddle with transport after exporting has started. Previously this could happen, because realtime_stop() queues PostTransportStop and the butler is sommoned after every export process cycle. Since 61e7f3176bf the butler keeps calling non_realtime_stop() every time it is woken up, until TFSM comes around and unsets the flag in the process callback.
2020-04-02Emit Locate() in ::locate() even if we are not synced_to_engine()Johannes Mueller
This reverts 05c77db7739c (revert necessary due to 4637c49838a8) Since 4637c49838a8 we no longer emit Located() in ::backend_sync_callback(). Therefore we must emit Located() in ::locate() even if we are synced_to_engine(). Otherwise the playhead is not updated when synced_to_engine() in some circumstances.
2020-04-02Restart Transport FSM after x-run halt #7951Robin Gareus
2020-03-24remove unused variablePaul Davis
2020-03-23add disk i/o apparent speed output to non-RT locate callPaul Davis
2020-03-23add in timing for disk buffer reload after locate, to replace hard-coded ↵Paul Davis
0.05 seconds per track Leave debug output in place for now to get some numbers from any testers
2020-03-13add new API to TransportMasterManager to manage use of ↵Paul Davis
DiskReader::{inc,dec}_no_disk_output()
2020-03-10small adjustments to TransportMaster API to better accomodate the ↵Paul Davis
"ignore/accept commands" concept
2020-03-10do not reset default transport speed when stopping to prepare for a locatePaul Davis
2020-03-09Session::have_looped must only be true when we locate because we reached the ↵Paul Davis
loop end Locating the start of the loop range at transport start does not count as "have looped". This was preventing pre-roll when starting to loop, which in turn caused data/event loss because the start/end sample ranges would be incorrect inside process
2020-03-08Fix count-in and loop-as-mode metronome clicksRobin Gareus
2020-03-06Fix export alignment (#7916)Robin Gareus
Ardour's playback is aligned to master-out: "When the playback clock reads 01:00:00:00, the sample corresponding to 01:00:00:00 is audible at the speaker(s)" When exporting, and grabbing data from output ports, the signal is offset by the master-bus physical playback latency. This was compensated for, but lead to initial silence in the exported file. New approach is to start capturing export data during pre-roll, at the time when playback is written to the output buffers. To also shaves off a common offset to make this work with realtime export. Effectively this emulates processing with disconnected master-output port, while still keeping any latency of effects on the master-bus itself. Last but not least: jack updates latencies when freewheeling, (setting HW latency to zero). The callback arrives asynchronously some time after enabling freewheeling, but after Export Ports have been configured. Those callbacks are ignored.
2020-03-05continue with code simplification and add comment given 4a40ff9e53Paul Davis
2020-03-05transport stop resets default_transport_speedPaul Davis
This means that using the wheel in the GUI (or equivalent) ends its effect at transport stop
2020-02-27Add signals to indicate Punch/Loop constraintsRobin Gareus
This is in preparation for GUI sensitivity of Loop and Punch actions.
2020-02-27Prevent concurrent loop and punch recording (backend)Robin Gareus
This also prevents switching between punch-in/out record and looping without transport-stop.
2020-02-26Consolidate loop en/disable callsRobin Gareus
2020-02-24Zero x-run count after session-load and engine restartRobin Gareus
2020-02-21avoid double-locate call when locating-while-stoppedPaul Davis
Session::locate() used TransportFSM::stopped() to determine if realtime stop was required. But this would return false, since the motion state at that time is WaitingForLocate. So invert the test and use !TransportFSM::rolling
2020-02-20change transport API, session API, transportFSM API to move reverse ↵Paul Davis
management and motion state (partially) into TFSM
2020-02-19remove "destination_sample" from API for Session::set_transport_speed()Paul Davis
This was a leftover from changes made for Tracks Live, related to the concept of an auto-return preference. We don't use this anywhere in Ardour or Mixbus, and the concept should eventually be removed entirely.
2020-01-28fix previous commit, and another instance of the same (incorrect ↵Paul Davis
constructor) issue
2020-01-28fix assert-crash caused by not constructing a StopTransport event correctlyPaul Davis
2020-01-27Fix sending MMC Start/Stop messagesRobin Gareus
Ardour 5.x slave check was incorrectly ported to A6's TMM: In Ardour 5 the comparison tested for *not* MTC: ``` if (!dynamic_cast<MTC_Slave*>(_slave)) { ..send MMC.. } ``` Other MMC messages (Record, Locate) are sent unconditionally.
2020-01-26Fix Loop-length (no pre-roll on loop-iterations)Robin Gareus
2020-01-25remove debug outputPaul Davis
2020-01-23add more debug outputPaul Davis
2020-01-23use Session::locate_initiated(), appropriatelyPaul Davis