UI draft for MIDI Mapping

Yellow office buildingNew Knobroom version for LR4 is progressing steadily, and I’ve now reached the point that is sensible to create some UI elements as well. Except that Lightroom SDK is notoriously bad with growing UI elements. And if you’ve used the previous LR3 release, you might have noticed that creating lots of pulldown menus isn’t particularly fast either.

The main problem is that once you have created a list of elements, there is no way to grow the list. And since the creation of elements is slow, you really can’t just create lots of hidden controls either. MIDI protocol is quite extensive, e.g. there are 128 id’s of each event, possibly on several channels. And since I’d like to support quite advanced configurations, I need something which I can grow dynamically.

After few miserable attempts with pulldown menu spaghetti, I’ve come up with a list-based approach. Unfortunately, this simple_list component is only available on Lightroom 4. It is not dynamic either, but at least it is possible to unobtrusively fill it with blank rows.

Basically, you can load a mapping preset (in JSON format) and edit it further by clicking the row in the large listbox. When you select the develop setting from the last pulldown menu, it is updated to the listbox. You can also insert new rows into the listbox by selecting a new event type (note, control change) and note/controller key id.

Also, pay attention to the tab view section. The idea is that on the left there are the basic controls (“Base” for now), which specify the default controls. The other tabs override these controls, so that you can specify to use CC 4 as Fill Light when Process Version 2010 is in use. And similar handling to B&W Treatment and JPEGs (RAW Temperature, JPEG IncrementalTemperature)

I originally figured that it would maybe take me a couple of days to create the mapping UI. Fair estimate, but I’ve so far spent about ten times as many hours…

Anyway, I’m working on a new release, and no, I don’t have a set date yet, but I’m hoping to release few first releases during August.

Comments

comments

58 thoughts on “UI draft for MIDI Mapping

  1. Jarno,

    Thank you for all your hard work on this project – anything we can do to improve productivity is invaluable.

    This question might be slightly off-topic, and please forgive me if this has already been addressed or another solution exists – but I don’t know if it…

    Is there a way to tweak Knobroom (or perhaps have another plugin) so we can use Hot-Keys or Shortcuts in conjunction with a gesture from a Magic Mouse or Apple Track Pad for some of the developing channels?

    For instance, if I wanted to slide my Exposure value a keystroke of Shift+E in addition to a one or two finger Up/Down swipe on the trackpad or mouse. Contrast, Highlights etc. would all work in similar fashion with their own designated keystroke plus gesture.

    I know there is a wide world of plugins and programs out there, and it seems like all get close to solving this, but I don’t see it out there. Your work and the Better Touch Tool are about as close as I have found.

    It just seems to me that this would be a great way to boost productivity using some of the hardware we already have in the keyboard and mouse. I would attempt to write my own plugin, but know nothing about that process. Again, sorry if this is out of bounds, but thought it might be worth asking. Thanks again for all the hard work and I look forward to the new plugin for LR4!

  2. Why not just open source this? I’d love to help with development, and it is obviously more than you have time or interest for. I’m sure others could contribute too.

    1. I’ve also been thinking about it, but there are some small essential parts that cannot be opened. And I don’t that there would be any other active developers, it’s more effort that what it would be worth πŸ˜‰

    1. yeah me too! πŸ™‚

      unfortunately i was in flu this week, and there have been some set backs with the Lightroom UI stuff. So the UI draft is gone, its just not reliable to try to use Lightroom controls in dynamic manner. So the first version will have oldschool json based text interface.

  3. Thanks for the hard work, Jarno! This could seriously save me so much time!

    Here’s what I got (I hope feedback is appreciated!): Downloaded the beta and followed instructions… Couldn’t map any midi though… Plug-in Manager only displays Status and Plug-in Author Tools segments… There is one diagnostic message (actually three, but they are all identical…): ?:0 attempt to index field ‘mapping’ (a nil value)

    I’m on an iMac 27″, 10.7.4, LR 4.1

    Looking forward to try this out!

    Best,
    D.

    1. Sorry, there was a fatal bug in the preferences loading, which failed if there weren’t any preferences for the plugin. Fixed in r660. These are automated builds so the newer version isn’t always better πŸ˜‰

      1. No problem & thank you! This is better… Now of course I’m trying to figure out how to do the midi mapping… For test purposes I’m trying to use my old M-Audio O2 controller… Before I decide to get a more knobby control surface mainly to control Lightroom…

        So, my question now is: Are there any apps / utilities out there that tell me what the CC# a certain button of a controller triggers… That of course would help to set things up quickly…

        Sorry for all these newbie questions!

        D.

          1. Wow! This is very promising! Thank you for the quick reply and hand holding!

            Here’s what I experienced: At first I didn’t know that I had to import at least an empty map to get the plug-in to work… Then sometimes the mapping I tried would “stick”… Found I had to stop and restart Knobroom to make it use the latest version of the maps I just did…

            Hope that this helps! This is all very cool!

            D.

  4. Of course I’m back with more questions ;):
    a) I’m researching which midi controller would fit best for me and Knobroom / LR 4… Trying to decide between the Behringer BCR2000 and the Icon iStage ( http://www.icondigitalusa.com/content/istage-velocity-sensitive-drum-pads ): I don’t like about the BCR is that it seems quite bulky and needs mains power… The iStage seems smaller and is bus powered… On the other hand the BCR is tested for this application and has been around for a bit… The iStage seems uncharted territory… Now to my question: The iStage allows for mapping two buttons to one CC#, one for increasing and one for decreasing values… Would that theoretically even work with Knobroom?
    b) I’d love to be able to select adjustment brush presets with a key command… Or with a button press… Is that possible in Knobroom? (I read on the Paddy discussion boards that the option exists in Paddy…) Or would a key macro program like Livid Instruments Selectrix ( http://blog.lividinstruments.com/forum/topic.php?id=3142 ) be needed (or even work aside Knobroom)?

    Thank you for your time, Jarno!

    D.

    1. I haven’t tried iStage, but generally I don’t like the rubbery feeling in buttons. In theory, using two buttons to increment/decrement values should work.

      I think Paddy uses purely event stuffing to do it’s work, I’m more interested in using the Lightroom’s API functions. Thus, you can’t really control the UI of Lightroom, because there is no official API for it.

      Using MIDI macro programs depends on the controller, you might need a virtual MIDI port to multiplex devices.

      1. Thank you for your pointers, Jarno! Appreciated!
        Had put a question out to iCon-USA in regards to the iStage, but haven’t heard back yet… Good point about the rubbery feeling of the keys though…

        D.

  5. Hi Jarno. Looks promising indeed. It only looks at the moment though, for me. I registered knobroom even if it’s not working yet, as an encouragement: after the previous build problems, now I managed to create a list. Midi monitor receives data regularly on channel one, but in lightroom, with knobroom on, no changes happen… Any suggestion? Best regards and thanks for your work!
    Matteo

    1. Actually, there was a problem with Knobroom initialising, the sliders values were sent before the device was selected, which resulted in not getting proper output values. I fixed it today, so the build 678 should contain the fix (I haven’t tested the actual builds yet :).

      When you have selected mapping, started knobroom from plugin extras, Knobroom should send MIDI out messages to your device. These messages should display in MIDI Monitor (make sure to tick ‘Spy on output’ active).

      1. IT’S ALIVVVE !

        Well done Jarno, working really fine for me.

        For minor ideas/bug report/feature request do you have a dedicated mail or should we post it here ?

  6. Yep… Latest build works! πŸ™‚ Thanks! Seems to be a bit slow-ish… Is that something you can address or it just depends on lightroom/my mac?
    Also, a “previous pic” and “next pic” would be wonderful additions, together with a “crop” function, maybe starting from a corner and going down (or up) proportionally, even though I’m not sure that’s possible (though it would be wonderful!)…
    Thanks!!!

    1. “next pic” and “previous” are already available, you even have “go to first” and “go to last” !

      There are not in the function list altough.
      But if you load the “BCF2000_simple” mapping, you’ll find them all the way down the map (CC 89 90 91 92).

    2. I’m planning to implement accessibility API, which should be a bit faster. If you try e.g. prev/next navigation, you can see that it is not communication to LR that is slow. Slowness comes from LR’s internal way of processing develop presets.

  7. Great Antoine! I was puzzled because I din’t see them in the list either.
    Still hoping for the crop function though πŸ™‚
    Also… Missing from the list is a “null” or a “unassigned” function πŸ˜‰

  8. Thank you for the progress versions, Jarno!

    Here’s some more feedback from my side:

    – When importing the mapping Knobroom still needs to be restarted to make the mapping current.

    – Got “An internal error has occured. ?:0: attempt to index a nil value” up on deleting images from my library…

    Tried to txt edit the BFC2000_simple.json file to create a version where I could have access to first,. last, backwards and forwards too… Not successfully though! πŸ˜‰

    Great though that you are implementing new things! Love it!
    Please let me know about my other questions when you get those!

    Thank you!

    D.

  9. Hi there,

    I have just bought a Korg NanoKontrol2 and am looking to try it out with my LR4. I have followed the instructions in the readme file, however, when I go to Plug-in Extras and click on Start Knobroom, the TR4 application just closes down.

    Is there a way to fix this?

  10. I want to use the Ableton APC40 as midi controller for Lightroom via Knobroom. The problem is that all the control-data is sent on midi ch 0. Is it possible to change the midi ch?

    Tnx in advance.

    1. There is no option for that in the simple mapping UI, but if you edit the mapping json manually, it is keyed by MIDI event and a CC number (e.g. “0xb022” stands for Control Change on channel 0 number 22 (hex), 0xbf22 would be same CC on channel 15). Haven’t tested it, but it should work.

      1. Tnx for the fast reply. Basically it worked but with a delay (aprox. 1-2sec) when fader are touched. Is there a way to elliminate this delay?
        How do I implement midi notes in the programming?

        Regards

  11. Hi all!
    Jarno, thanks for the hard work to make our life easier!

    I’m heaving a hard time here trying to make it work!
    I’m using OSC Touch with OSCulator on Lightroom on my mac and it’s not working.

    I can see the faders moving on the quick look. So the app is working and the link is fine.
    And as OSCulator can’t set ch0, I have changed the .json file to use ch1.

    Still not working.

    Can somebody help me?
    I’m trying to do it for two days now.. and I can’t find anything on the internet to help me.

    Many thanks!
    Sunny regards from Brazil!

    1. I haven’t tried OSculator, but is there a chance it is using channels 1-16 to represent actual channels 0-15?

      1. Oh yeah! That’s it!

        Now it’s working perfectly! Your plugin is awesome! Thanks for all the work that you put on it! =) Well done!

        I will try to do some post about my configuration.
        I send you the link if I do it…

        Cheers!

  12. I am new to this program – running MacOSX. I bought a BCF2000 & loaded your json file. That file works & I understand how to reprogram the buttons in the Lightroom plug-in manager. However I am not sure which button is which, e.g., CC1 or CC2 etc. Some I can figure out but I can’t figure out what is controlling the Hue, Sat, Adjustments for each individual color nor the presets button. Do you have a key or map of the buttons on this device?

  13. I’ve been trying to use an Ableton Push with Knobroom. I’ve been able to get it to work, however when I turn the knobs on the Push to increase a setting it’s backwards and decreases the value. In addition it’s changing the maximum amount possible rather than having increments. Is there a way to control the sensitivity and the direction?

    1. Well, there hasn’t been much updates lately, but on the other hand, there has been absolutely no API improvements from Adobe, and the current versions works.

Leave a Reply

Your email address will not be published. Required fields are marked *