Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GUI example with synth and soundfx selection ? #100

Open
johncohn opened this issue Dec 26, 2020 · 8 comments
Open

GUI example with synth and soundfx selection ? #100

johncohn opened this issue Dec 26, 2020 · 8 comments

Comments

@johncohn
Copy link

Steven,
This is not so much an issue as a request.… I am really enjoying node-red-contribute-music… I'm using it to (re)build a 30 foot keyboard for a popular band. I'm wondering if you happen to have a simple example of a node red dashboard fragment that prompts the user to try different sense and effects… I was about to write one but I figured at some point someone may have already created one but I haven't seen it. Do you have such a thing?

Again very nice job on this… Have a great holiday
-John Cohn

@johncohn
Copy link
Author

Steven,
I have several usage questions now that I'm digging in deeper. Where would you prefer those questions?… Here in this issues I get? Or another public forum? I'm specifically trying to figure out a way of passing in the name of a tuned synthesizer. E.g. "piano" versus "ambi_choir", etc . What I'm trying to do is randomly assign an instrument to various phases of an interactive performance.… I'd like to do it programmatically rather than through user selection.… So I need to be able to switch which key on this 30 foot keyboard plays what instrument when struck. .. Please let me know where the best place to ask questions like this.. I really appreciate all the work you've put into this!…
-jc

@stevenaeola
Copy link
Owner

Hi John,
thanks for your interest and your question. It's fine to ask questions on here - you could put them on the node red forum at https://discourse.nodered.org/ in the General category but it's possible I might miss them there.

@stevenaeola
Copy link
Owner

I've certainly used the dashboard for controlling volume, tempo etc, generating random sounds etc and it works fine in a public setting, as long as you have a publically accessible IP address. Do you mean a dashboard as in https://flows.nodered.org/node/node-red-dashboard or something else?

@stevenaeola
Copy link
Owner

The project sounds great! How are the keys being played (as a matter of interest)? For programmatically selecting which instrument gets played, probably the easiest way is to use a standard switch node with outputs leading to synths for each of the types you want to use. If each note played is to be randomised you could use a JSonata expression and use the $random function. If you want to stick with the same synth being used for a while you could use a sequencer node (from n-r-c-music) with the order being randomised. Then you can either use the same instrument for a given number of bars, or have it wired up to a dashboard component which triggers the next action. If you let me know which of these you would prefer then I could quickly knock up an example for you.

@johncohn
Copy link
Author

johncohn commented Dec 27, 2020 via email

@stevenaeola
Copy link
Owner

OK so are the play messages from different notes on the keyboard arriving as messages from different nodes, or as messages from the same node with a certain property (e.g. payload) set to something?

@stevenaeola
Copy link
Owner

One thing that would be helpful is finding a list of 'tonal' synths that
ship with N-R-C-M .. I found this
https://github.com/stevenaeola/node-red-contrib-music/blob/master/synthtypes.json
and think i think the keyword 'tuned' means it will take a midi note..
true ? ..

In the synth node properties on the right hand side there are a bunch of tag filters. If you select 'tuned' then you will see the ones that have a specific pitch. Set the 'note' property on the the incoming message to select the note in the scale (1 is the first note, 8 is an octave higher). The synth node turns this into midi according to the current scale. Alternatively you can set the 'midi' property on the incoming message if you already know the midi value you want.

@stevenaeola
Copy link
Owner

It also seems that if the synth has a tag 'sonic-pi' it's a
sample.. Also true ?

In the synthtypes files the ones tagged with 'tuned' are indeed tuned, with a given midi pitch for the basic sample. It is speeded up/slowed down appropriately, nothing fancy. In that file most of the synths are referring to samples from somewhere in the the samples/ directory. The ones that aren't samples are labelled with "synth": true and use a SuperCollider synth in the synthdefs/ directory. Some of the synths come from https://sonic-pi.net/ and some of the samples do to: the "sonic-pi" tag is independent of the others.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants