JS vs pure patching
I’m currently designing a probabilistic sequencer for my own use, firstly.
I’m hesitating between a JS core which would retain all arrays of data (or almost all) VS pure patching objects (coll, etc)
Of course, time accuracy is totally required.
So I’m hesitating before diving into one or the other solution and I’d want to have your opinion.
let me know here or on http://designthemedia.com/forum/25-the-probabilistic-sequencer/
I don’t know this for sure, but if you’re using arrays, wouldn’t jitter matrices be faster than either coll or js?
I decided to go to JS.
Trusting the new engine in Max6…
Translating it into coll or even jitter matrices wouldn’t be that hard
Considering HUGE max 6 improvements, I guess that JS worth to be used..
I’d like to know more about performance comparison between:
- 1 JS parsing A LOT of data coming from 8 sources
- 8 JS parsing data coming from 1 source each one
I really wanted to know that.
posting that in JS forum… more appropriate..
Julien, what are your findings so far?
JS in Max6 is REALLY faster, first good point.
I’d suggest you to prototype first using Max6 Objects, if possible (sometimes, making multiple included loops or more tricky stuff can be a pain following that way)
Then, if it works, keep it. If it doesn’t work well because of complexity of patching work, move to JS.
This would be my way.
Indeed, if you can code C++ routines using the SDK, I’m quite sure it would be the fastest way. I wrote "could be", because I have been very surprised by some part of my patches using JS in Max6.
I know where the weakness of visual programming lies, and when it pays off to move to procedural. The question is more whether I should give JS another try or stick with what I already know is good. I think from your experiences I should give JS second chance.
I forgot one major JS annoyance. The missing module system. I had a look and I still can find no docs on any sort of require() function in Max6. It is possible to break JS code into modules now or is the jsextensions folder still the only way to reuse code?
I would be very curious to hear if some else found a better solution.
So far I go for Java if scripting project get to large.
That’s too bad. Thanks for the tip about eval but I’d rather stick with jit.gl.lua for scripting then. NodeJS has a module system using require() which works nice for server side code. The browser on the other hand loads all scripts in one global space, and then you can quite easily create modules with some namespaces and immediate function wrappers.
A missed opportunity in Max6 imho. Now we have a fast engine and no real way to reuse code or write bigger projects. It was like this in Max4 and years after things are still the same. Bummer.
Forums > MaxMSP