strudel icon indicating copy to clipboard operation
strudel copied to clipboard

Midimap+

Open nkymut opened this issue 9 months ago • 5 comments

This update enables midimaps to register control names that are not limited to Strudel's controlNames. This provides greater flexibility in customization while maintaining compatibility with existing mappings. However, further consideration is needed regarding potential namespace pollution.

midimaps({ nsx: { gain: 7, 
                  pan:10, 
                  modulate:1, 
                  express:11, 
                  sustain:64, 
                  reverb:91,
                  chorus:93,
                  variation:94  } })
           

This PR includes updates from #1244

nkymut avatar Feb 09 '25 08:02 nkymut

great, yes that was still missing from the midimap PR. so i guess we discuss / merge https://github.com/tidalcycles/strudel/pull/1244 first, before looking at this one?

felixroos avatar Feb 09 '25 09:02 felixroos

great, yes that was still missing from the midimap PR. so i guess we discuss / merge #1244 first, before looking at this one?

Yup, #1244 is good to go. And we can also look at if we map non-cc messages.

nkymut avatar Feb 09 '25 10:02 nkymut

as #1244 is now (finally) merged, we could go with this next.. @nkymut could you maybe merge main into this one? it's a bit hard to see changes otherwise

felixroos avatar Mar 20 '25 22:03 felixroos

Hi @felixroos thank you! I have merged the main.

nkymut avatar Mar 22 '25 00:03 nkymut

Its been a while. As an interim fix, a warning is now shown when midimap overwrites a Strudel API method.

I've tried Throwing an error, but I find it too restrictive. For long-term flexibility—especially to allow smooth switching between MIDI and non-MIDI in the same code—it may be better to permit explicit destructive changes.

It would be more ideal if we could switch controlAlias based on output modes (midi, OSC, superDough) and active midimap, since the root cause is that all Pattern.prototypes are shared.

And currently It is hard to restore overwritten Strudel API methods to their default state beside refreshing the page.

nkymut avatar May 18 '25 08:05 nkymut