New Year Deal!
Get Control Surface Studio Now For Just $62
Time left to get it...
mailtimers.com
Your shopping cart is empty.

Move highlight to next clip slot from reaction

Submitted by papoaudio on Sun, 11/13/2022 - 13:00
papoaudio
Control Surface Studio User

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!

Topic Category: 

1 Responses

Comments

papoaudio
Control Surface Studio User
#1

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)