Noticed something neat when trying a ensemble in Reaktor.
The combobox for selecting presets has a next and last button included in it. I think this would be cool if there’s a way to implement this?
Noticed something neat when trying a ensemble in Reaktor.
The combobox for selecting presets has a next and last button included in it. I think this would be cool if there’s a way to implement this?
The question I have related to this is, how much control of combobox
do we have from csound? EG:
chnset "value(2)", "presetComboboxIDchn"
To select the second preset form inside of a Csound instrument.
A regular channel can be used to both set an retreieve a value from a combobox, like a slider:
<Cabbage>
form caption("Test") size(400, 300), pluginid("def1")
combobox bounds(140, 56, 130, 42) items("I", "can", "change", "this", "using", "a", "normal", "channel") channel("cbox")
</Cabbage>
<CsoundSynthesizer>
<CsOptions>
</CsOptions>
<CsInstruments>
ksmps = 32
nchnls = 2
0dbfs = 1
instr 1
if metro(1) == 1 then
chnset int(random:k(1, 7)), "cbox"
endif
endin
</CsInstruments>
<CsScore>
f0 z
i1 0 z
</CsScore>
</CsoundSynthesizer>
It can also be done with an identifier channel.
if metro(1) == 1 then
SMessage sprintfk "value(%d)", int(random:k(0, 7))
chnset SMessage, "cbox"
endif
You could add two button beside a combobox, and then set the value of the combobox accordingly. If it’s for presets though you might want to roll your own preset manager and build a new system. There is only so far you can push the existing one…