Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/live/scene/fire_as_selected not working as expected? #148

Open
Coupe70 opened this issue Feb 3, 2025 · 4 comments
Open

/live/scene/fire_as_selected not working as expected? #148

Coupe70 opened this issue Feb 3, 2025 · 4 comments

Comments

@Coupe70
Copy link

Coupe70 commented Feb 3, 2025

@ideoforms

I just tried /live/scene/fire_as_selected and think it does not work as it should.

It is supposed to fire the scene that is selected in Live (same as if I hit Enter on a selected scene in Live).
So it should not be necessary to send a scene id as the scene id is already set by the selection in Live.
But if I don't send a scene id, I get an error.

Example of what happens when sending a scene id:

  • I select scene 2 in Live
  • I send /live/scene/fire_as_selected [0]
    -> scene 0 is fired (same as with /fire [0]) and scene 3 is selected (as I have set "select next scene on launch" in Live preferences)
    What I would expect is the selected scene 2 being fired and (with my preferences) scene 3 being selected.

In the API documentation I see something about an argument 'scene', too,

fire_as_selected( (Scene)arg1 [, (bool)force_legato=False]) → None

but somehow it does not make sense to send a scene id...

@ideoforms
Copy link
Owner

Hmm, I wonder if this is actually an internal Live issue!? The LOM documentation says:

"Fire the selected scene, then select the next scene.
It doesn't matter on which scene you are calling this function."

But it seems that the call does actually honour the specified scene_id. Hmm. One of the principles I am applying throughout AbletonOSC is as much as possible to pass-through the design of LOM to the OSC interface, but this is a slightly perplexing one.

@Coupe70
Copy link
Author

Coupe70 commented Feb 3, 2025

The error I get when not sending a scene id is

Error handling OSC message: list index out of range

I guess that is an error message from AbletonOSC and not coming from Live, right?
So maybe let's try to allow and call /live/scene/fire_as_selected without scene id and see if it works?

@ideoforms
Copy link
Owner

It's a good point, but the fire_as_selected method is specifically an object method that requires a Scene to operate on... so it can't be called without a target!

Instead, I've added a new method /live/scene/fire_selected, which takes no parameters and fires the scene that is selected in the view, before selecting the next scene. I think that probably does what is intended?

The only question is whether there should also be another method that fires the selected scene but keeps it selected.

@Coupe70
Copy link
Author

Coupe70 commented Feb 3, 2025

/live/scene/fire_selected works as I would expect it.

/live/scene/fire_as_selected is obsolete in my eyes - I can't see any use case for this strange behaviour.

The only question is whether there should also be another method that fires the selected scene but keeps it selected.

Whether this call selects the next scene or not is set in Live's preferences.
Both settings are working as expected with /live/scene/fire_selected.

Image

Is there a way to select a scene, like /live/scene/select ?
Not super important though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants