Forum Replies Created
-
AuthorPosts
-
I probably tried all that at some point and found it very frustrating – Stuff getting jumbled around lost – it is much harder than layers – once you get used to using layers, you will never look back! ?
Hey Steve,
You’ll continue to have nightmares with uiGroup and tabs – hours of work suddenly lost – I recommend layers, but you’ll need to dip your toes into the lua river I’m afraid – worth it though in the end!
Also Ctrl+s every second more or less!
ctrlr.org/forums/topic/using-layers-tutorial-1-0/
Hi llatham,
Does
(6-modulatorValue)+61
work ??See panel.
I think learning Ctrlr is difficult, because there is no manual except for one Goodweather wrote, but you have to track that down – I don’t know where it is, so personally I like to share what little knowledge I have of this amazing program. So don’t worry about firing off a hundred questions!
JG
Attachments:
You must be logged in to view attached files.Hi llatham,
In area Expression to evaluate … of the Octave Shift uiCombo set it to
modulatorValue+61
That should do the trick!
Regards,
When you open your panel in the AU instance of Ctrlr, you can then Then go to File -> Export -> Export Restricted Instance..
Before you do that though, make sure you add 24 pixels to the height of the panel.
For example if your panel height is 1000, set is to 1024 and then export!
You can then run your panel as a separate AU (same case for VST)
Regards,
JG
- This reply was modified 3 years, 6 months ago by dnaldoog.
Hi llatham,
For instructions on how to export as standalone or AU in macOS see here!
ctrlr.org/roland-jd990-super-editor/Regards,
October 16, 2020 at 9:38 am in reply to: Changing just one element in SysEx string globally? #120317Hi llatham,
If you don’t want to use lua…
You can do it globally using setGlobal() function in the little box Expression to evaluate …. To write the global variable to sysex, use k0,k1 etc for the static value you want to change.
substitute
F0 41 10 00 00 77 12 19 01 k1 k0 xx z5 F7
for
f0 41 10 00 00 77 12 19 01 20 0c xx z5 f7
for example.
I also included a formula for switching between 0,127 (7F) using a toggle – which is sometimes needed.
setGlobal (0,(modulatorValue*127))
(0 = k0,1 = k1 etc)?
See attached panel.
Also: see https://ctrlr.org/forums/topic/did-i-mess-up-my-panel-size/#post-120399
- This reply was modified 3 years, 6 months ago by dnaldoog. Reason: forgot attachment
- This reply was modified 3 years, 6 months ago by dnaldoog.
Attachments:
You must be logged in to view attached files.Hi Tedjuh,
I don’t think RectangleList is supported.
This attached panel would probably give the OP a starting point.
Attachments:
You must be logged in to view attached files.Hi Puppeteer
Can you explain this in more detail? Give an example of the sysex?
They are returned as each pixel being the last 6 pixels of each byte. It’s essentially a 1 bit (black/white) bitmap.
I think the idea is to take a 64 x 240 multidimensional array and map each 1 to a black pixel and each 0 to a white pixel? Is that about right.
You would use a uiComponent and place a 1 x 1 black png or g:fillRect() ?? in each ‘on’ state – See attached panel for the basic idea.
- This reply was modified 3 years, 6 months ago by dnaldoog.
- This reply was modified 3 years, 6 months ago by dnaldoog. Reason: added download
- This reply was modified 3 years, 6 months ago by dnaldoog.
Attachments:
You must be logged in to view attached files.Hi Spiffo,
Probably another way of doing it, but then I am not familiar with using uiGroup and Goodweather, who has never used layers but is a veteran, didn’t know how to use layers, so I guess it shows the depth of Ctrlr (and JUCE) – several ways to achieve a similar result!
My latest panel for the Zoom RFX-2000 uses 15 layers!
Also, I often have hidden modulators in a hidden layer. That’s pretty useful.
Regards,
Hi Goodweather,
I made a tutorial for layers. It should explain some of your questions. I tried to keep it as basic as possible for people beginning with Ctrlr.
See https://ctrlr.org/forums/topic/using-layers-tutorial-1-0/
Regards,
Hi Goodweather,
That previous post is all a bit beyond me I am afraid! I only know about valueTree for saveState and loadState, but if you want true flexibility with background images on tabs, you could cheat by having a component in a layer sitting below the transparent tabs object that changes (repaints) on a tab click. You can do anything with images in uiComponent including tiling all pretty easily.
Here is an example panel using metatable to initialise an image for the uiComponent on boot (that could be a transparent png for example)
Regards,
JG
Attachments:
You must be logged in to view attached files.Hi Goodweather,
Maybe it’s not possible because all these methods are commented out and it’s the only reference to that method I can see anywhere.
See line: 339
- This reply was modified 3 years, 6 months ago by dnaldoog.
Thanks Goodweather,
A short reply was not possible!
I thought of explaining
MemoryBlock()
but that’s another complication as you said.A lot of this code is taken from a panel I am doing for the Zoom RFX 2000, which is turning out to be more difficult than I thought, but it actually uses MemoryBlock() everywhere. Everything is 4 bit nibbles msb,lsb in the Zoom RFX 2000 and every MIDI message is 83 bytes, so I condense that combine4n(b2,b1) into a MemoryBlock() single byte each time.
Regards,
UPDATE :: 10/05/2020
When a callback function is set in “Called when the modulator value changes”
When assigning incoming MIDI to the modulator – If the receiving incoming MIDI value is the same as the current Modulator Value then some functions do not trigger the callback function; see below.
Note that
setValue(value,false)
never triggers a callback function.
if the value is the same the function is not fired panel:getModulatorByName(k):getComponent():setValue(value,true) panel:getComponent(k):setValue(value,true) Function is never fired panel:getComponent(k):setValue(value,false) panel:getModulatorByName(k):getComponent():setValue(value,false) Function is always fired panel:getModulatorByName(k):setValue(value,true) panel:getModulatorByName(k):setModulatorValue(value,true,true,true) panel:getModulatorByName(k):setModulatorValue(value,true,true,false) panel:getModulatorByName(k):setModulatorValue(value,true,false,false) panel:getModulatorByName(k):setModulatorValue(value,true,false,true) panel:getModulatorByName(k):setModulatorValue(value,false,false,false) panel:getModulatorByName(k):setModulatorValue(value,false,false,true) panel:getModulatorByName(k):setModulatorValue(value,false,true,false) panel:getModulatorByName(k):setModulatorValue(value,false,true,true)
Hi Baus,
First you would need to determine at the positions of the two 4bit bytes in the incoming MIDI message. Remember to count from
F0
as zero.These two bytes will be converted to a number, for example
0F 01
is converted to1F
which in decimal is31
as you know.Create a function that processes the 148 byte MIDI message. You can filter out other incoming midi strings:
receiveMidiFromDevice = function(--[[ CtrlrMidiMessage --]] midi) if midi:getSize()==148 then updateModulators(midi) - only run function if incoming MIDI = 148 end end
In that
updateModulators()
function, create a hash table of all the modulator names you want to assign values to:
The key refers to the modulator name and the value to the position of the leading byte in the MIDI message.local t={dial1=8,dial2=10,dial3=12}
In the function you pass :
local b1=m:getData():getByte(v) local b2=m:getData():getByte(v+1)
..as two arguments to the 4 bit denibbilize function:
† It is possible to use getRange(t.dial1,2) and pass one argument to a function but we won’t go there
That function will return the value which you then assign to the modulator.
function combine4n(a, b) -- convert two 4 bit nibbles to a single integer local m = bit.lshift(a, 4) return m + b end
In that
updateModulators()
function, loop through the table to assign values to the modulators:function updateModulators(m) local t={dial1=8,dial2=10,dial3=12} for k,v in pairs (t) do local b1=m:getData():getByte(v) local b2=m:getData():getByte(v+1) local value=combine4n(b2,b1) panel:getModulatorByName(k):getComponent():setValue(value,true) end end
*NOTE: it is possible that this may in turn cause the modulator to fire off a send MIDI message, but I haven’t addressed that issue here. Also the code
panel:getModulatorByName(k)
can be assigned to a lua variable on start as previously discussed in another post.See attached panel.
Regards,
JG
- This reply was modified 3 years, 6 months ago by dnaldoog. Reason: removed unnecessary variable
- This reply was modified 3 years, 6 months ago by dnaldoog. Reason: removed another unnecessary variable
Attachments:
You must be logged in to view attached files.From what I can tell, this panel is only available as a precompiled executable, so there’s nothing you can do to fix it. You would have to contact the author and ask them to address the issue. Looks like a fundamental coding error in that function.
Also make sure you are in Ctrlr 5.3.201 – that button looks like you are using 6*.
- This reply was modified 3 years, 6 months ago by dnaldoog.
Do you mean last item clicked on or last item in the uiListBox? The question is a little ambiguous.
September 28, 2020 at 5:59 am in reply to: Midi Input Overload on Multiple Sysex Dump Requests #120070Hi Jsh,
Try:
os.execute(sleep(125))
Between messages you want to delay.
Here the delay is
125=Milliseconds for example -
AuthorPosts