triggerbox: get closer to Live semantics and descriptions for follow action/launch style
This commit is contained in:
parent
17b7e0648f
commit
0d104e85c1
@ -82,9 +82,9 @@ class LIBARDOUR_API Trigger : public PBD::Stateful {
|
||||
State state() const { return _state; }
|
||||
|
||||
enum LaunchStyle {
|
||||
Loop, /* runs till stopped, reclick just restarts */
|
||||
OneShot, /* mouse down/NoteOn starts; mouse up/NoteOff ignored */
|
||||
Gate, /* runs till mouse up/note off then to next quantization */
|
||||
Toggle, /* runs till "clicked" again */
|
||||
Toggle, /* runs till next mouse down/NoteOn */
|
||||
Repeat, /* plays only quantization extent until mouse up/note off */
|
||||
};
|
||||
|
||||
@ -93,6 +93,7 @@ class LIBARDOUR_API Trigger : public PBD::Stateful {
|
||||
|
||||
enum FollowAction {
|
||||
Stop,
|
||||
Again,
|
||||
QueuedTrigger, /* DP-style */
|
||||
NextTrigger, /* Live-style, and below */
|
||||
PrevTrigger,
|
||||
|
@ -162,7 +162,7 @@ Trigger::process_state_requests ()
|
||||
|
||||
case Running:
|
||||
switch (launch_style()) {
|
||||
case Loop:
|
||||
case OneShot:
|
||||
DEBUG_TRACE (DEBUG::Triggers, string_compose ("%1 %2 -> %3\n", index(), enum_2_string (Running), enum_2_string (WaitingForRetrigger)));
|
||||
_state = WaitingForRetrigger;
|
||||
break;
|
||||
@ -558,7 +558,7 @@ AudioTrigger::run (BufferSet& bufs, pframes_t nframes, pframes_t dest_offset, bo
|
||||
|
||||
/* We reached the end */
|
||||
|
||||
if (_launch_style == Loop) {
|
||||
if (_follow_action == Again) {
|
||||
nframes -= this_read;
|
||||
dest_offset += this_read;
|
||||
DEBUG_TRACE (DEBUG::Triggers, string_compose ("%1 was reached end, but set to loop, so retrigger\n", index()));
|
||||
|
Loading…
Reference in New Issue
Block a user