Tree @v1.1.0 (Download .tar.gz)
abletonlink
Lightweight Lua wrapper of the Ableton Link C API (abl_link).
API
The module follows the C API very closely.
See the abl_link.h for comments for the various methods.
The module table has three members:
abletonlink._VERSION: a string like"1.0.0"abletonlink.create(number bpm): creates anabl_linkinstanceabletonlink.create_session_state(): creates anabl_link_session_stateinstance
abl_link instances have the following methods:
link:is_enabled() -> boollink:enable(bool?)(defaults to true)link:is_start_stop_sync_enabled() -> boollink:enable_start_stop_sync(bool?)(defaults to true)link:num_peers() -> intlink:clock_micros() -> intlink:capture_audio_session_state(session_state output)link:commit_audio_session_state(session_state input)link:capture_app_session_state(session_state output)link:commit_app_session_state(session_state input)link:destroy(): Destroys this instance. Calling any other method on a destroyed instance causes an error. This is automatically called in __gc.link:pump_events(): If callbacks are installed, this needs to be called regularily to dispatch events. It will returntrueif the internal event queue overran.link:set_num_peers_callback(cb): cb is called with number of peers (int).link:set_tempo_callback(cb): cb is called with new tempo (int).link:set_start_stop_callback(cb): cb is called with playing state (bool).
abl_link_session_state instances have the following methods:
session_state:tempo() -> numbersession_state:set_tempo(number bpm, int at_time)session_state:beat_at_time(int time, number quantum) -> numbersession_state:phase_at_time(int time, number quantum) -> numbersession_state:time_at_beat(number beat, number quantum) -> intsession_state:request_beat_at_time(number beat, int time, number quantum)session_state:force_beat_at_time(number beat, int time, number quantum)session_state:set_is_playing(bool, int at_time)session_state:is_playing() -> boolsession_state:time_for_is_playing() -> intsession_state:request_beat_at_start_playing_time(number beat, number quantum)session_state:set_is_playing_and_request_beat_at_time(bool, int time, number beat, number quantum)session_state:destroy(): Destroys this instance. Calling any other method on a destroyed instance causes an error. This is automatically called in __gc.
Commit History
@v1.1.0
git clone https://git.s-ol.nu/lua-abletonlink.git
- fix rockspec s-ol 15 days ago
- bump version to 1.1.0 s-ol 15 days ago
- implement callbacks s-ol 15 days ago
- examples/linkhut: fix phase display s-ol 15 days ago
- fix whitespace s-ol 15 days ago
- update to Link 3.1.2 s-ol 1 year, 1 month ago
- add Lua linkhut example s-ol 3 years ago
- implement session_state s-ol 3 years ago
- implement simple get/setters s-ol 3 years ago