Feature #10919

darktable and MIDI controler

Added by daniel patin about 2 years ago. Updated 5 months ago.

Target version:
Start date:
Due date:
% Done:


Affected Version:
hardware architecture:


Hi, sorry for my poor english.

many Lightroom users use USB MIDI controler for fast and confortable use. you can assign each setting to one controler for time saving and accuracy
on tread on twitter, but in french:
this feature is possible to implant in Darktable?


#1 Updated by Tobias Ellinghaus about 2 years ago

In theory that would be possible. However, until a developer needs that it will most likely not happen.

WARNING: Brainstorming about darktable internals ahead.

One way to handle that could be handled is interfacing Lua to vimkeys (or rather, using the same mechanism to access controls) and then have a Lua script that interfaces with MIDI controllers.

#2 Updated by Tobias Jakobs about 2 years ago

Gimp supports MIDI controller, perhaps there is some code to share.

#3 Updated by daniel patin about 2 years ago

you can find here old mac app for assign MIDI keyboard to keystrokes:
and the source code is on github

#4 Updated by Christian Kanzian over 1 year ago

Tobias is working on this. More about the progress can be found here:

#5 Updated by Tim Sinthofen 8 months ago

I checked the link and saw that Tobias was basically trying to build some Midi Hardware, which didn't work out.
I just want to leave a affordable device here, if somebody still wants to try to implement MIDI: Akai LPD8.
50€ for a board with 8 pads, 8 rotary knobs. And as far as i understand can switch between 4 "programs" basically giving you 4 different mappings for each of the controls.
For implementation you could also check (DJing software)

#6 Updated by Philippe Gauthier 6 months ago

Hi there,
I'm very interested in this feature too and I have a Korg nanoKontrol2, so I gave it a try.
I found a basic midi C library : : reading and writing (turning pannel's leds on/off) to the controller works fine.
I don't know how darktable's insides are designed, but I tried to hardcode a basic midi mapping as proof of concept.
I did a dirty thread in the main loop, listening for midi inputs, and called some image processing function I found, for exemple : dt_dev_exposure_set_exposure(darktable.develop,midiValue);
It kinda works but it stacks too many processing jobs while you move the knobs, and takes forever.
How do I abord previous job if the knob moved while previous job is still in process?
If there is some documentation on the image processing pipeline/jobs API, I'd be glad to read it.

#7 Updated by Tobias Ellinghaus 6 months ago

  • Tracker changed from Bug to Feature
  • System changed from Mac OS X to all
  • % Done changed from 0 to 20
  • Status changed from New to Triaged
  • Category changed from Darkroom to General

Currently the whole control infrastructure inside darktable is not suited to something like that. It will require a major rewrite of several parts.

I started work on that a while ago and hope to continue it once we have the next release out.

#8 Updated by Matthew Harrison 6 months ago

Please can the new infrastructure be flexible enough to support:
Absolute position sliders or dials
Relative position sliders or dials
Motor driven sliders
Led indexed dials
I'll be buying a controller when support is added. Thanks Tobias for the work.

#9 Updated by Tobias Ellinghaus 6 months ago

Yes, all of that is on my list already.

#10 Updated by Philippe Gauthier 5 months ago

Ok, thanks Tobias, good luck then! :)
Just to keep track, I published what I did here :

Also available in: Atom PDF