Move highlight to next clip slot from reaction

37 viewsCSS Questions
0

Hello! I’m having a hard time to implement a feature in my remote script. Can somebody give me some hints how this is possible?

I’ would like to implement the following actions and bind it to a footswitch:
– In the case of highlighted clip is empty, start recording
– In the case of highlighted clip has clip and it is recording, stop recording, and play clip
– In the case of highlighted clip has clip, jump to next clip slot in track.

I managed to implement the first two parts using a reaction listening on the press of the switch, and calling “self.song().view.highlighted_clip_slot.fire()” in a custom code block.

I can also use reaction conditions to check for the clip status, so basically i have the entrypoint for the ” jump to next clip slot in highlighted track” action to be called. The problem is i can not find a way to make that action happen.

Any advice is greatly appreciated!

admin Changed status to publish May 22, 2024
Attached Files:
0

Okay, so one possible solution for this is utilizing modifiers. You can create a reaction that saves the currently selected track to a modifier, triggered by “Selected scene changed”. Then use a custom code action to change the highlighted clip to the next one on the selected track
self.song().view.highlighted_clip_slot = self.song().view.selected_track.clip_slots[self.get_modifier_value(“m1”) + 1]

The better approach IMHO is without using modifiers, with the custom action self.application().view.scroll_view(1,””,False)

admin Changed status to publish May 22, 2024
Attached Files: