Hi Be!

> I think this is the most reasonable way forward from where Mixxx is. 
> This could facilitate a smooth phasing out of the XML format and a 
> transition to JSON. All the info contained in the header of XML files 
> could be defined in JSON with a metadata object.
> 
> Looking into other programs' mapping systems, it looks like Traktor and 
> possibly Ableton are the only ones that have mapping systems worth 
> taking ideas from. Serato's system is primitive (at least the 
> user-definable part; no one knows the secrets of how official, 
> unmodifiable Serato certified mappings work). VirtualDJ has its own 
> clunky mini-scripting language. Ableton allows scripting with Python but 
> at first glace I don't see much documentation for it and I've heard 
> there is no debugging output. Traktor's mapping system is flexible but 
> tries to do so much in GUI that it ends up being cumbersome. I think it 
> would be awesome to implement a GUI interface similar to Traktor's but 
> allow direct input of JavaScript snippets from the GUI. For example, 
> instead of selecting [Channel1] as the group for a mapping in the GUI, a 
> user could type in a JS variable that could be toggled between 
> [Channel1] and [Channel3]. Also, custom JS functions could be typed into 
> the GUI. This could combine the best of a GUI interface and the 
> flexibility of JavaScript.
> 
> I got another idea that I think would be both powerful and 
> straightforward: mappings could be built from layers, which would be JS 
> objects containing groups of input and output mappings. In the GUI, 
> layers would be presented as tabs at the top of the mapping editor. 
> Button presses (or whatever) would be mapped to switch between layers. 
> By default, activating a layer would overwrite active mappings that 
> overlap with the layer being activated. Mixxx could remember the 
> previously active mappings and revert to that when a layer is disabled, 
> which would make implementing shift button layers trivially easy. Would 
> it make more sense to implement layering functionality in C++ or as a 
> JavaScript library making use of a new mapping (dis)connection function?

Hehehehehe, funny!

I used to work on the team that built Push at Ableton (I still work for
Ableton on a different team).  One of my contributions there was adding
such a layer system to the scripting framework we use internally, which
is built in Python.  The system works almost exactly like you described:
hardware controls can be organized in "layers" (there is an actual
`Layer` class), that are associated to "components" (that implement the
actual functionality).  When a component is activated it grabs the
layer, which gives it the actual controls.  Each control keeps a stack
of the components that are active in the order they grabbed them, so
they can be reasigned back.  It feels a bit like having a "window
system" and focusing different windows.  It also had features like
"priorities", for simulating stuff like a dialog that should stick on
top.  It worked quite well and it is now used also for the new
controllers from Akai, Novation, etc.

In the light of this experience, I believe that it would be much easier
to implement such a system in JavaScript.  Actually, that is one of the
designs I considered for Mixco... however, since I already had
implemented such a system once, I wanted to try something else, hence
the current design based on reactive expressions and "if...else...".  It
is more limited in some ways but it's simpler and it might work better
for DJ controllers (which tend to be no so complicated).  In fact I
think now Ableton has something in this spirit in its scripting
framework too...

Btw, are you by any chance in Berlin area?  I will be doing a public
presentation at the Berlin C++ Meetup on Tuesday (at the Ableton office)
and we could have a chat there!

JP





Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
_______________________________________________
Get Mixxx, the #1 Free MP3 DJ Mixing software Today
http://mixxx.org


Mixxx-devel mailing list
Mixxx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mixxx-devel

Reply via email to