fire or set_fire_buton_state and quantization

taprik's icon

Hi,

I'd like to fire some clips using M4L.
It's pretty straightforward with thee function fire, stop, ...
But ...
What I want to do is armed a clip and play it at quantization or don't play it if stop is called before the quantization of Live says "play" to the clip. In my example :
My live set have a quantization of 1 bar. When I "fire" a clip and immediatly call the stop function the call of the stop is not heard by Live. When I'm referring to the help of Max it seems all right as
for the function stop on a clip it says "Same effect as pressing the stop button of the track, but only if this clip is actually playing or recording".
Ok, so I look at the "set_fire_button_state" function as when I'm referring to help of Max it says "If the state is set to 1, Live simulates pressing of clip start button until the state is set to 0 or until the clip is stopped otherwise.". "Until the state is set to 0". Of course there is something I don't understand.
Could you help me to understand :
- what the set_fire_buton_state function is for.
- Is there a way to call fire and immediatly stop on a quantized set of live without hearing the clip (even once).

Please find below the code of my M4L patche.

Max Patch
Copy patch and select New From Clipboard in Max.

taprik's icon

Here is the answer I had from the ableton support

with call fire/stop, you simply start and stop a clip.
with set_fire_button_state, you imitate the mouse down and mouse up which is needed for the clip launch modes other than trigger and toggle.

The stop behavior makes sense since you can observe the property is_triggered.