leolabs / ableton-js

Control Ableton Live with Node.js
MIT License
368 stars 46 forks source link

Add audio channel and add clip from desktop #20

Closed beatelite closed 3 years ago

beatelite commented 3 years ago

Hi, this project looks really cool.

I have 5 samples in a folder. Via JS, I want to open an audio channel for each sample in the folder and add those samples to each audio channel in Live.

Is this possible using your library?

I looked at the unofficial documentation for the live API methods here https://structure-void.com/PythonLiveAPI_documentation//Live10.0.2.xml but couldn't really see anything that indicated I could add channels and load clips into them by using their /path. I saw a lot of event listeners but not actions.

What am I missing?

beatelite commented 3 years ago

A little more digging and I found

Live.Song.Song.View.highlighted_clip_slot Get/Set the clip slot, defined via the highlighted track and scene in the Session.Will be None for Master- and Sendtracks.

Looks like this might be possible. Let me know if I can do all this so I know whether to keep digging or not.

leolabs commented 3 years ago

Hey @beatelite!

Sorry for the delayed response. I don't think Ableton's Python allows adding clips by their paths, unfortunately. It's originally designed to be an interface for hardware modules like the Novation Launchpad so cases like this weren't in mind.

I don't know your use case for what you want to do, but when I want to create a track for each clip I move into Ableton, I do it by dragging them into the arrangement view while holding CMD.

beatelite commented 3 years ago

ouch! ok. That really sucks. Thanks a mill for the response.

leolabs commented 3 years ago

Yeah, it's a pity and I hope that the API will be expanded in future versions.