David Nahmani Posted July 17, 2013 Share Posted July 17, 2013 Wow, cool, just realized that there's a way to script your own MIDI Plug-ins!! The only downside: you need to script them using JavaScript. But I'm assuming that means many 3rd party manufacturers will be able to offer additional MIDI plug-ins? Sounds exciting. Link to comment Share on other sites More sharing options...
ed Posted July 17, 2013 Share Posted July 17, 2013 I am pretty sure that it is javascript not java. While it does still mean programming it should be an easier entry point than java. From the Effects manual: "Use the Script Editor The Script Editor is used to edit JavaScript code, enabling you to write your own MIDI plug-ins." *** Thanks to Eric's update of the original message this makes no sense. Glad it is all cleared up! Link to comment Share on other sites More sharing options...
shivermetimbers Posted July 17, 2013 Share Posted July 17, 2013 Too funny! http://mudcu.be/midi-js/ Link to comment Share on other sites More sharing options...
beej Posted July 17, 2013 Share Posted July 17, 2013 Please - "Java" has *nothing at all* to do with *Javascript*, despite the name similarities. Let's not add to the confusion. Apple say the MIDI scripter is "Javascript", so can we please always refer to the scripting language as Javascript. Can you edit the thread title, please David? Thanks... Edit: Interestingly, from the docs, there is no concept of a "SysEx" event type, further echoing the evidence that sysex events are filtered out from channel strip objects, which is a bit of a shame... Nice API though, looks like all sorts of fun can be had here for the nerdy types... Given the work involved in implementing the scripter plugin and language and javascript interpreter, it suggests to me that possibly *all* of LPX's new MIDI plugins are written with this API, rather than natively - with the others obviously having a nicely wrapped GUI as well. So the should give an idea of just some of the things that are possible, as well as more bespoke personal customisations... Good stuff... Link to comment Share on other sites More sharing options...
Eric Cardenas Posted July 17, 2013 Share Posted July 17, 2013 Fixed the title for David. Link to comment Share on other sites More sharing options...
basils Posted July 17, 2013 Share Posted July 17, 2013 Woah, this is interesting. I work in another software where gifted scripters write amazing plugins that add so much functionality. If this catches on you will be amazed. Link to comment Share on other sites More sharing options...
Ploki Posted July 17, 2013 Share Posted July 17, 2013 Woah, this is interesting. I work in another software where gifted scripters write amazing plugins that add so much functionality. If this catches on you will be amazed. Smells like Max. I'm loving it too Link to comment Share on other sites More sharing options...
ibt Posted July 17, 2013 Share Posted July 17, 2013 Would be great if a plugin could be javascripted so Ultrabeat output it's MIDI notes in realtime...* *wishful thinking? Link to comment Share on other sites More sharing options...
ed Posted July 17, 2013 Share Posted July 17, 2013 Having done a lot of coding in Javascript.. I am chompin' at the bit! Link to comment Share on other sites More sharing options...
mysticfm Posted July 17, 2013 Share Posted July 17, 2013 Hey, that's pretty sweet. I've done lots of Javascript development too. I'd be kind of excited about trying my hand at this ... if not for that pesky "New Track with Next MIDI Channel" bug that is currently keeping me from purchasing it. Link to comment Share on other sites More sharing options...
plpdig Posted July 17, 2013 Share Posted July 17, 2013 This is cool, gonna have to learn javascript again .... Link to comment Share on other sites More sharing options...
88keys Posted July 17, 2013 Share Posted July 17, 2013 So does this mean that it will be possible to create scripts similar to the ones Kontakt has made use of for some for the nicer sample libraries ie for articulation switches etc. - assuming you set up EXS with appropriate samples to trigger. Link to comment Share on other sites More sharing options...
FredBegin Posted July 17, 2013 Share Posted July 17, 2013 I'm wondering if it would be possible to make a kind of expression map with the scripter plugin. Transforming 1 keyswitch to multiple keyswitch and/or midi controller seems possible. But I'm not sure we could make this with several notes. I'm looking to come back from Cubase to Logic if I could have a Expression Map alternative even if it's more complex to set up. Logic have always been slicker to me but I can't live without Expression Map feature anymore. Link to comment Share on other sites More sharing options...
David Nahmani Posted July 17, 2013 Author Share Posted July 17, 2013 This is cool, gonna have to learn javascript again .... My thoughts too. Link to comment Share on other sites More sharing options...
Michael Ellis Posted July 18, 2013 Share Posted July 18, 2013 Is there a manual for the Scripter API? Can't find anything useful online. Link to comment Share on other sites More sharing options...
beej Posted July 18, 2013 Share Posted July 18, 2013 Is there a manual for the Scripter API? Can't find anything useful online. Yes, it's in the LPX Effects manual. Documentation is decent. http://support.apple.com/manuals/#professionalsoftware Link to comment Share on other sites More sharing options...
beej Posted July 18, 2013 Share Posted July 18, 2013 Would be great if a plugin could be javascripted so Ultrabeat output it's MIDI notes in realtime...**wishful thinking? It's only inserted in the MIDI signal flow before any instrument plugins. So it cannot get MIDI out of instruments, like UB. The AU spec doesn't support that, or at least hasn't for a while... Link to comment Share on other sites More sharing options...
beej Posted July 18, 2013 Share Posted July 18, 2013 So does this mean that it will be possible to create scripts similar to the ones Kontakt has made use of for some for the nicer sample libraries ie for articulation switches etc. - assuming you set up EXS with appropriate samples to trigger. Probably yes, to some degree - for instance, you could implement features like when you are holding a C0 key, the MIDI channel is changed to 1, and triggering a certain set of samples, and if you hold a D0, the MIDI channel is changed to 2 to trigger a different set of samples. However, this will be limited, as there is no direct access to the EXS24 stuff, only plain vanilla MIDI. I think a better sampler solution is coming... Link to comment Share on other sites More sharing options...
Michael Ellis Posted July 18, 2013 Share Posted July 18, 2013 Thanks, beej! Looks very interesting. http://manuals.info.apple.com/en_US/logic_pro_x_effects.pdf pages 185-193 Link to comment Share on other sites More sharing options...
Michael Ellis Posted July 18, 2013 Share Posted July 18, 2013 Looking through the docs, I think I see the following capabilities: 1. Receive and examine incoming MIDI events from an external midi source or an upstream plug-in 2. Modify events 3. Create new events 4. Send modifited and/or new events downstream in real time or delayed to some future beat position. 5. Create fader and menu GUI items 6. Get initial and changed values from GUI items while processing the incoming MIDI That's a fairly complete and compact set of of functions that should allow you to apply almost any conceivable transformation to incoming MIDI. I like it. I can't tell the extent to which Apple may have crippled the JavaScript interpreter. Specifically, I suspect it's not possible to load external javascript libraries (although you might be able to paste the source code into your plug-in script). That could be a big hindrance to developing anything really sophisticated. It's also not clear if Apple has included a debugger in the script editor. I think they do have a syntax checker, but a real debugger would be nice to have, especially if you can't modularize the code to allow use of third-party editors and development tools. Really hope my suspicions are wrong. Related but not precisely on-topic: Does anyone know if LPX has better support for AppleScript/Automator? I'd love to be able to control the transport from a script outside of Logic,. e.g. play from, say, bar 13 to bar 17, then bar 5 to bar 7, etc. Link to comment Share on other sites More sharing options...
ibt Posted July 18, 2013 Share Posted July 18, 2013 That's a fairly complete and compact set of of functions that should allow you to apply almost any conceivable transformation to incoming MIDI. I like it. Do you think the new Javascript MIDI plugins/spec can offer any functionality beyond what can be built in the Environment as is? Link to comment Share on other sites More sharing options...
beej Posted July 18, 2013 Share Posted July 18, 2013 That's a fairly complete and compact set of of functions that should allow you to apply almost any conceivable transformation to incoming MIDI. I like it. Do you think the new Java MIDI plugins/spec can offer any functionality beyond what can be built in the Environment as is? "Javascript". And yes, because you have access to proper programming principles, like variables and maths and functions. Have you ever tried dividing one value by another and storing the result using fader objects in the environment..? That stuff is horrendously clunky in the environment (which is, at best, a rather simple visual programming language) but becomes trivial to do with actual code. Link to comment Share on other sites More sharing options...
ibt Posted July 18, 2013 Share Posted July 18, 2013 "Javascript". dohScript () = ; So, could this open up an easier way of say, storing plug-in snapshots (pretty involved in the environment)... and also morphing between plug-in states / mixer states ? Link to comment Share on other sites More sharing options...
beej Posted July 18, 2013 Share Posted July 18, 2013 "Javascript". dohScript () = ; So, could this open up an easier way of say, storing plug-in snapshots (pretty involved in the environment)... and also morphing between plug-in states / mixer states ? Well, it's up to us to explore the possibilities. Not sure if they work with Logic's internal meta events (if they do that would be super awesome). Don't forget we can use these scripts in conjunction with other environment objects too... It's just that they are single entities (I can think of workarounds to copy variables between scripts on different channels etc) in a fixed position, which might limit things a bit, but we'll see. Who knows, we might even get a "Scripter" environment object in the future, which would be *super* awesome..! Link to comment Share on other sites More sharing options...
shagstaphone Posted July 18, 2013 Share Posted July 18, 2013 Hey All, I posted the text of the 14 included "Tutorial Scripts" to make them easier to read while trying it out: http://www.shagstaphone.com/logic/scripter_samples.html Cheers, Dave Link to comment Share on other sites More sharing options...
cyril Posted July 19, 2013 Share Posted July 19, 2013 Hello I am also very interested of this possibility to develop the equivalent of the VST expression Map to drive VSL articulation changes I have read that the score have been re-wrote ! is this true ? Reading the manual I did not find that it was possible to convert score events (staccato, legato ...) into a midi command to be send to VSL Also you cannot work on note length. Looks like you cannot do more that what you can do with the environment ! I hope I am wrong and that this is missing in the manual Best Cyril Link to comment Share on other sites More sharing options...
majool Posted July 19, 2013 Share Posted July 19, 2013 Flexible MIDI out routing directly from AU's would have been nice. Then you could use Reaktor, Max, Plogue etc. instead. Can't really see why they they didn't go that route. What does Javascript have that makes it a better choice for MIDI out than AUs? It seems like it must have been more complex to write... Thoughts? Link to comment Share on other sites More sharing options...
beej Posted July 19, 2013 Share Posted July 19, 2013 Flexible MIDI out routing directly from AU's would have been nice. Then you could use Reaktor, Max, Plogue etc. instead. Can't really see why they they didn't go that route. Because that would require updates to the AU spec, an incorporation in a new version of OSX, before applications like Logic can take advantage of it. In short, it needs OSX support first, they can't just do it in a Logic update... Link to comment Share on other sites More sharing options...
ski Posted July 19, 2013 Share Posted July 19, 2013 Diving into MIDI Scripting. I've already written a few little routines and (drum roll please) they work! What can be done with MIDI Scripting far outweighs what can be accomplished using environment objects alone, both in terms of function and complexity. For example, it's fairly simple (though awkward) to create the equivalent of a simple "if-then" or "if-else" function (comparator) using a transformer. For this you'd use the Condition Splitter mode, define a condition, and have all data that meets the condition output on the top cable. Everything else outputs on the bottom cable. Simple. But if you need to test for more than one condition (if A, then, if B...), the awkwardness factor of programming individual transformers increases logarithmically because you have to cascade the various transformer's outputs, and when it comes to editing their values you can only view one transformer's window at a time. With Javascript, all you have to do is write a few lines of code to accomplish these tasks and the order of operations is laid out before your eyes in one window. Also, it's extremely difficult to create the equivalent of variables using Environment programming. Again, with Javascript it's a piece of cake. However... You can't install a MIDI Script in Logic's "front end" (inbetween the output of the Physical Input and the Sequencer Input). So scripts can't be used to process MIDI data before it's received at the Sequencer Input. This is something I hope can be addressed in a future version. Link to comment Share on other sites More sharing options...
shivermetimbers Posted July 19, 2013 Share Posted July 19, 2013 Diving into MIDI Scripting. I've already written a few little ...Blah, Blah, Blah ... So with whatever it is that you are saying, do you think it will be a matter of weeks or months (time) before these 'scripts' start popping up (for sale as an 'app')? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.