[Closed] MaxScripr VS SDK
SDK = Fast! Ugly. Not very well documented, but powerful. Development takes longer because you have to compile, start max, test, close max, change code, compile again, repeat. Creating GUIs is a PITA and can take hours or days.
MAXScript = Slow. (usually orders of magnitude). Slightly better documented Development is lighting-fast as you can evaluate with Ctrl+E and see the result of your changes instantly. Creating GUIs is a breeze. Note that MAXScript is a sort of a wrapper around the SDK, so it does MOST of the things the SDK can, but not all.
At Frantic, we try to combine the positive sides of both, usually developing user-level code (GUIs, custom tools etc.) in MAXScript but the underlying logic in the SDK. This way, we can tweak the GUI at the speed of light and still get the maximum performance.
Also, MAXScript is great for prototyping tools that will be later ported to plugins via the SDK, and for solving problems where the solution is needed yesterday and would not allow for a week of dev. time. Even if the script runs 400 times slower, it can be developed 400 times faster, so if a deadline looms it is a good alternative…
SDK run 400 time faster?!!:eek:
What is the most important things where SDK can access and Maxscript can’t??
Depends on what you are calculating, if you are doing raytracing, it might be thousands of times faster (I wrote a raytracer in MAXScript, check out the DVD in my signtature).
See this thread:
http://forums.cgsociety.org/showthread.php?f=206&t=469866
Oleg tested DataFlow Operators from PFlow Box#3 against comparable scripted operators and came up with a factor of 200x. So while my number was arbitrary, you are getting an idea of the orders of magnitude when comparing C++ code with scripted code.
I agree 100% with what Bobo said.
To give you a few examples:
One example is that you cannot write modifiers in Maxscript that deform the vertices.
(The Maxscript version of such a modifier is incredibly unstable and easily 400x slower )
Another example is that you cannot write new controllers.
(You can use a scripted controller of course, but that doesn’t give you the same performance or functionality)
There are also certain things you cannot do with scripted (object) plugins that you can do with c++ plugins, i.e. change certain properties or overwrite certain behaviours.
Maxscript also tends to become unstable over time for certain things.
Usually related to Garbage Collection.
Maxscript however is unbeatable when it comes do development time and GUI development. It is also simply A LOT easier to do certain things in maxscript.
You won’t believe how overly complicated certain simple behaviours are in c++.
Especially string manipulation is a huge pain.
Also creating an array in maxscript that has different data types in the various elements of the array is super easy, while in c++ this is nearly impossible.
So my recommendation is that if you choose to use the SDK, do it for the right reasons and don’t give up using maxscript.
Even though I can probably write all of my plugins 100% in the SDK, I still choose to do at least the entire UI in maxscript and quite often write additional functions in maxscript just because it is so much quicker and easier.
I have a question (sorry for use this post but i think it was ok):
I´m learning maxscript trough the documentation and scriptspot.com and i´m very excited about the things you can do, now my questions is this:
If i want to create a very complete plugin like Lumonix´s, Chaos Vray, AfterBurn or FumeFX which i think are very complex to make, which leanguage should i start to learn, i know the big one is C++ but what about C or C#? What is the best or complete IDE for create this plugins and run them in Windows (since 3ds Max runs in Windows of course). The journey is long, i know that, and maybe i should learn more deep Maxscript, but i would like to know this stuff to see how is done, thanks for any info. (and sorry for my english)
Max and its SDK are strictly MSVC++, so you should get yourself MS Visual Studio and explore the SDK examples – nearly 60% of the the Max source code is available in the SDK so you have a great starting point.
MAXScript is a Quick Fix tool – it can be used to do certain things of a certain complexity, when you come to the heavy stuff you mentioned above, you have to go with C++ and the SDK. Once again, MAXScript is unbeatable when it comes to development speed (see the DIMaster v2 thread in the Main Max Board – the tool was written in 3 days. In the SDK, it would have taken me about a month). But execution speed and stability are the plus sides of real plugins, so a renderer written in MAXScript is just an insider joke
thank you very much Bobo, i´m following some basic tutorials about C++ under Visual C++ 6, but i think it can by apply to MSVC++ 2005, i see how far i can go.
here it’s much of the same
maxscript is used for everything except performance code and things that are impossible to write in maxscript (controllers, geometry modifiers)
a lot of times the c++ stuff might just be maxscript extensions or fixes to existing modifiers for better scriptability (is that a word?)
as far as the rigging department goes maxscript is also used extensively for prototyping these c++ plugins
and as far as i know in most studios it’s the same outside the 3d packages, with a combination of python and c++