How to expose SessionComponent to Max For Live (M4L) from control surface script?
Hi,
I’m working with a custom control surface script created with CSS and a Max for Live device, and I’d like to access the SessionComponent from M4L (to do stuff like explained here: https://www.keithmcmillen.com/blog/controlling-the-controllers-communicate-with-and-controlling-live-scripts-part-1/). However, I can’t see the SessionComponent exposed anywhere in the Live API when I try to access it from my device. I can access it when its the original (APC40 MK2) script though.
With the custom CSS script I see other componenents (Devicecomponent) but the one I really need is SessionComponent
Is there something I need to do in the control surface script to explicitly expose the SessionComponent to the Max for Live API? As it really plays in pivotal role for M4L.
Any help or examples would be much appreciated—thanks!
I’m not exactly sure about this, but you may be able to get to it through control_surfaces > ‘control_surface’ > sessionComponent… ?
Hi John are you talking about something in Max For Live? Because I Max for Live I know the path I should use – I can see SessionComponent in the original script of the device and it’s the same as in tutorials I follow about how to see SessionComponent in general.
I have impression it’s something missing in the CSS script but I dont know what, I asked ChaGPT but I dont have the knowledge to understand precisely what is missing.
For info, in M4L I can still see in CSS script these components: DeviceComponent and CustomMixerComponent
I do have a session box.
ChatGpt also said somethign around these lines but after hours of trials I did not manage to make it appear (I don’t realy know to code so I’m trying blindly…)
Would it be possible to get make SessionComponent visible, either through a future CSS update or at least for now through some custom code?
Sign up
User registration is currently not allowed.
deviceComponent is called/added as soon as the script is initiated, so maybe that’s why you can see it.
SessionComponent is added deeper in the script, inside a mode.
Note that an instance of sessionComponent is only created if you have added a session box mapping in the active mode or global mode.