Multi Synth/Sound Module patches onto one comboBox #694
Replies: 7 comments 12 replies
-
Hi there @jfk-france I would not use uiCombo in this case. It is better to use JUCE PopupMenu() Here is a demo panel (attached) by Atom that should get you in the right direction. It includes a more complex panel I made for the JD-990. Also this panel for the Roland JV-1010 has a complex PopupMenu sttructure. Don't hesitate to ask any questions as PopupMenu() can be difficult. The main thing to aim for in nested menu items is that each selection must return a unique number. local ret = m:show(0,0,0,0) if ret ~= 0 then sendMidi(t[ret]) -- where t{} might be a lookup table with various CC program change, sysex commands etc end t={ "F0 00 02 01 F7", "F0 00 0A 03 F7", "B0 07 7F", } |
Beta Was this translation helpful? Give feedback.
-
Hi @jfk-france, Yes not all JUCE methods are bound to lua in Ctrlr - that method is no doubt one of them. I just down loaded the JV-1010 and opened it in Ctrlr. It loads ok. You need the file attached, not any of the other files and I am using Ctrlr 5.3.201 in Windows. If on mac I recommend 5.3.198 because I don't think it will open in Damien's CtrlrX as yet. |
Beta Was this translation helpful? Give feedback.
-
What version of Ctrlr are you using? |
Beta Was this translation helpful? Give feedback.
-
I am at a loss to know what is going on because it works for me when I open in a panel on a virtual box macOS Mojave. Maybe it’s the Mac version you’re running? |
Beta Was this translation helpful? Give feedback.
-
That's strange - When I use 5.3.198 on VirtualBox and open the .bpanelz file in Ctrlr I can easily go into panel mode, lua editor mode etc - there is an executable,AU and VST version as well as the .bpanelz file - only on the bpanelz file can you access the source code. |
Beta Was this translation helpful? Give feedback.
-
Salut @damiensellier , A dispo, j'ai the following:
Malheureusement, je n'ai plus de Catalina sous la main, mais je vais voir avec un ami, si il en a encore un. Cordialement, |
Beta Was this translation helpful? Give feedback.
-
I'll look for a Montery one - might take me a couple of days to find one, if any. |
Beta Was this translation helpful? Give feedback.
-
Bonjour everybody,
I am new here, this is a first. I don't have much experience in developing nor in creating plugins. However, I'd like to learn.
I was initially using the old site (ctrl.org - ver5.3.198) a while back, then had to move on to other things. Now I have time again. With that said, I have been able to get a few things running (reading and using lots of the examples within here) but not to any of your level.
Here is what I'd like to achieve (something similar to what - SoundDiver did), well the basic. I have a whole bunch of old school sound modules (which I still liked even if they are cheesy). I'd love to get all those synth/sound module's Patches name (hardcoded right now) into a couple of dropdown by category (guitar, synth, beats, etc) regardless of the synth/sound module.
As an example, in the Guitar dropdown, I could have 10 Patches from Synth 1, 20 patches from synth 2, etc..
This might be relevant to how I design this:
Here are my questions on the below code:
----CODE START HERE-----
SendBassBankPatchChange = function(--[[ CtrlrModulator --]] mod, --[[ number --]] value, --[[ number --]] source)
if panel:getBootstrapState() then
return
end
-- get Current MIDI information
local deviceMidiOutput = panel:getProperty("panelMidiOutputDevice")
local deviceMidichannelOut = panel:getProperty("panelMidiOutputChannelDevice")
local deviceMidiInput = panel:getProperty("panelMidiInputDevice")
local deviceMidichannelIn = panel:getProperty("panelMidiInputChannelDevice")
--get info the Combobox
if value == 0 then
deviceMidiOut = "Orbit"
deviceMidichannelOut = 1
bankValue = 2
patchValue = 14
elseif value == 1 then
deviceMidiOut = "XtremeLead"
deviceMidichannelOut = 1
bankValue = 0
patchValue = 25
... to the entire list (some have 200 patches)
end
--updating the MIDI Info with the If statement above var
panel:setPropertyString("panelMidiOutputDevice", deviceMidiOut) -- set the proper Out Device based on the patch
panel:setProperty("panelMidiOutputChannelDevice", deviceMidichannelOut, true) -- set the proper Channel from Patch
--WORKING
--Send BankChange
local statusByte = 0xB0 + (deviceMidichannelOut - 1) -- use this code for dynamic channel changes
local midinumber = 32 -- WORKING
--send Patch change
statusByte = 0xC0 + (deviceMidichannelOut - 1) -- use this code for dynamic channel changes
local programChange = CtrlrMidiMessage(MemoryBlock({statusByte, patchValue}))
panel:sendMidiMessageNow(programChange)
end
Merci beaucoup - Thanks a million for any help.
Beta Was this translation helpful? Give feedback.
All reactions