tidalcycles / Tidal

Pattern language
http://tidalcycles.org/
GNU General Public License v3.0
2.24k stars 255 forks source link

Backend: Make it easy to specify IP and Port #297

Closed jarmitage closed 6 years ago

jarmitage commented 6 years ago

Defining a backend destination for Tidal to send to is somewhat buried currently, e.g.:

https://github.com/tidalcycles/Tidal/blob/master/Sound/Tidal/Dirt.hs#L73-L75

Here's an example of connecting to a remote IP and adding a nudge for compensation: https://github.com/yaxu/spicule/blob/master/init32.tidal

Vivid allows you to do something like this which is helpful: createSCServerConnection $ defaultConnectConfig { _scConnectConfig_hostName = "192.168.7.2" }

It would be good if one could easily use both the local and remote simultaneously. E.g.:

d1 $ sound "bd"
rd1 $ sound "bd" -- "remote dirt" somewhere via a different IP+port
yaxu commented 6 years ago

It's now quite easy in the refactor: https://github.com/tidalcycles/Tidal/blob/refactor/src/Sound/Tidal/Stream.hs d <- stream (superdirtTarget {address = "192.168.1.2", port = 2342})