Open gogins opened 6 months ago
For cloud-5 type pieces, add a button to start/stop recording to file with fade in/fade out. Victor has a tutorial that shows how to upload and download files that Csound can read or has written here.
Create key bindings for the following inputs:
cloud5_piece.menu_slider_addon(Composition, "NoteTempo", 0, 200);
cloud5_piece.menu_slider_addon(Composition, "NoteDensity", 5, 200);
cloud5_piece.menu_slider_addon(Composition, "NoteDurationFactor", 0., 5.);
cloud5_piece.menu_slider_addon(Composition, "GraphicsTempo", .0, .25);
cloud5_piece.menu_slider_addon(Composition, "GraphicsHue", 0., 1.);
cloud5_piece.menu_slider_addon(Composition, "GraphicsValue", 0., 1.);
Key bindings will be as mnemonic as possible and use [Ctrl][Alt] with [Shift] for decrease and no shift for increase:
n NoteTempo
d NoteDensity
f NoteDurationFactor
g GraphicsTempo
h GraphicsHue
v GraphicsValue
The handler will increment (no [Shift]) or decrement [Shift] the parameter value in steps of size range/100; minimum and maximum values will simply peg.
I wasted time getting the fade in and fade out to work because turnoff2
turned off the master output without releasing its cossegr
envelope. Changing that to linsegr
works.
Submitted the piece, 2024-ICSC.html here at commit 03e599266139bb18baa9ec18d1580ed5c7a1ff1f.
Perhaps not done here. Control the piece from my phone or from a dedicated MIDI controller.
Possibly usable sensors on the phone:
Note: X is left to right, Y is bottom to top, Z is back to front.
The Csound for Android app claims to have the OSC opcodes. I could design a custom GUI and send control parameters from a piece running on my phone through OSC to the actual piece running on my MacBook. I will try this.
There are Android apps for OSC including OSC Controller, TouchOSC, and Sensors2.OSC.
I will test with OSC Controller and if things work, will switch to TouchOSC.
The receiver is controlling data in the JavaScript context so needs to be JavaScript, see https://github.com/colinbdclark/osc.js/. This looks good, but there are hoops to be jumped through. Maybe MIDI would be better.
CsoundAudioNode doesn't implement OSCinit
. I must use either MIDI, or OSC on NW.js.
The Midi Studio on the MacBook does not recognize the MIDI Commander app.
Maybe I can use WebMIDI directly to do this job. See https://webmidijs.org/.
I believe I can use requestFullScreen
with options to select the screen. That would be far the best if it works for me, so that is what I will try first. Supposedly works with current Chrome.
I should then also add a parameter to select which screen.
Partly there with opening a separate browser window with HTML controls on the secondary screen. Now to get it talking.
Apparently in the HTMLControls window, window.opener contains a live reference to the window for the piece, so I should be able to run the controls without using postMessage, just assigning new values to the piece parameters members.
That works.
The thing is basically working, but the two sets of controls should mirror each other somehow.
I actually will prepare the following pieces in parallel and submit the best:
cloud-5
always-on piece.Finishing the piece:
Things I need to do before the conference: