Open nm2107 opened 4 years ago
We could consider changing either the documentation or the behavior... what are you using this info for in your script?
Hello, thank you for your answer.
I'd like to be able to get the identifier of a specific deck (i.e. passed by the <controller id="XXX">
XML attribute). I have one XML file per deck, as the MIDI channel to use is specific to a deck (I'm using a pair of single deck controllers).
For now, I'm using the script's init
function by assuming that all the decks are connected to this kind of controller hardware, but it's a blind assumption. It would be better to be able to only identify the related deck by retrieving its ID (given as the init
fn parameter). This way, I could pass [Channel1]
as the ID for deck 1, and [Channel2]
as the ID for deck 2, so the init
fn would only target the related deck for LED initialization.
To clarify, is the issue that the MIDI channel identifying the deck number is not received until the first MIDI message is received?
To clarify, is the issue that the MIDI channel identifying the deck number is not received until the first MIDI message is received?
yes, exactly :+1:
Hello :wave:
The documentation about MIDI scripting states that the
id
parameter received in the controller'sinit
function is what is defined in the related xml file, but actually the given value is the name of the controller that is listed in theControllers
tab in mixxx's preferences.What the doc says :
What is actually passed : https://github.com/mixxxdj/mixxx/blob/fa797d239d4331d13ca73863391262612ea5d5ed/src/controllers/engine/controllerengine.cpp#L277-L282
Is it possible to fix the doc (or even better, to change mixxx behavior to match the doc ?)