Skip to content

Resolve "Create OSC endpoint for /satie/plugins"

Edu Meneses requested to merge 4-create-osc-endpoint-for-satie-plugins into develop

Closes #4 (closed)

PySATIE didn´t have a signal to expose the plugins list. This MR:

  • Creates a function (get_satie_plugins()) to query SATIE for the updated plugins list
  • Creates a signal (satie_get_plugins) to emit the list

Example of use:

import json
import time

from pysatie.satie import Satie

satie = Satie()

satie.initialize()

# Waiting for SC and SATIE to boot:

print("\nWaiting for SC and SATIE to boot...")
time.sleep(5)
print("\nSC and SATIE boot done")

# Create a Synth:

sources = satie.query_audiosources()
print("\nwaiting for getting plugin list...")
time.sleep(1) # wait to get plugins

dust = satie.get_plugin_by_name('dustyRez')
satie.create_source_node('dustey', dust, group="default") if dust else print("nope")

# Create functions and signal endpoints to get info back from SATIE Introspection

def get_satie_answer(sender, **kw):
  options = { sender: sender, **kw }
  data = json.dumps(options)
  print(data)

satie.signals['satie_get_plugins'].connect(get_satie_answer)

# Get list of SATIE available plugins

satie.get_satie_plugins()
Edited by Edu Meneses

Merge request reports