Clip Slot Color Index always returns ‘None’ – Solved

55 viewsCSS Questions
0

Hi There,

I am trying to loop through clip slots in a session box and set led colors on my pad controller based on the clip slots color index.

Looking at track 0 for example…

self.song().tracks[0].clip_slots[loop_number].color_index always returns ‘None’ even when self.song().tracks[0].clip_slots[loop_number].has_clip returns ‘True’

self.song().tracks[0]..color_index returns values as expected.

Wondering if I am missing something, or is there a bug here?

Thx,

Rod.

Loop
self.song().tracks[self.get_sessbox_track_offset()].clip_slots
Conditions
loop_number >= self.get_sessbox_scene_offset()
loop_number < self.get_sessbox_scene_offset() + 8
Actions
self.log_message(“csslog: ” + str(loop_number) + str(“: “) + str(self.song().tracks[0].clip_slots[loop_number].has_clip))
self.log_message(“csslog: ” + str(loop_number) + str(“: “) + str(self.song().tracks[0].clip_slots[loop_number].color_index))

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

Doesn’t seem to work in the static case either.

str(self.song().tracks[0].clip_slots[0].color_index) returns ‘None’ whether there is a clip in the slot or not.

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

str(self.song().tracks[0].color_index) returns expected values

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

This works as expected…
self.song().tracks[0].clip_slots[0].clip.color_index
rather than…
str(self.song().tracks[0].clip_slots[0].color_index

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