Hello fellow Maya users,
I was wondering what is the industry standard for programming in maya, is Python getting more popularity than mel?
I find mel easier but if python is the industry standard then i would consider ditching it.
Thanks in advance,
Solved! Go to Solution.
Solved by chaneyx. Go to Solution.
Hi!
Even most Maya commands are based on MEL (Maya Embedded Language), so there is no reason not to use it, especially if it's easier for you.
Python is a much better programming language than MEL. It is also very popular outside the graphics industry (and within it, quite popular outside Maya), while MEL is just for Maya. And a very important advantage is that Python scripts inside Maya can be debugged with Visual Studio. If now I had to start writing something new for Maya, I'd definitely go with Python.
Probably the only disadvantage of Python is that PyMEL takes too long to start up.
Hi!
I wouldn't say it's better, but of course MEL is only for Maya so it can't be as popular as Python if you also take other software packages into account.
But if you solely look at Maya, then i don't see any reason to choose Python over MEL, except for personal preferences. There are however exceptions, like MASH which has the Python node.
MEL PROS
1. If you are doing any expressions you will need to know MEL.
2. If you are hacking any of the core scripts that ship with Maya, you will need MEL
3. There is a near one to one correspondence with interactive actions being echoed in the scriptEditor.
4. It is easier to learn if you have experience with C or Houdini VEX
PYTHON PROS
1. More data structures are available
2. Better for file i/o and string manipulation
3. Tons of other libraries available to you for math, network connections, file i/o, and more.
4. PyQT can do some cool stuff once you get use to it
5. Universally relevant.
So in short, they are both helpful in Maya but you will need to know MEL and will eventually benefit from using Python
Hi,
I would like to thank you all for taking your time and sharing your thoughts!
Just want to clarify on one of the points made above. PyMEL does take a long time to start up. But PyMEL is not the only way to use Python in Maya. Using maya.cmds is another option.
Starting out, I found MEL very accessible to dip my toe in.
One big advantage, as a beginner in scripting, is that every action you do gets printed out in the Output Window inside Maya. So you can just do the action once, and Maya gives you the code on how to repeat that action for free.
That made it easy to learn how things worked, and just copy/paste code together.
However, MEL is a bit stupid to write more complicated code with, so I quickly felt hindered once I wanted to be a bit more creative with it. Which also affected my motivation to pursue more scripting.
A year later, I randomly started picking up a bit of Python, and it was the best decision I've made in a long time for my CG 'career'. As soon as I got the basics down, it felt a lot more intuitive and fun to work with. The MEL commands are easily translated to Python, and the documentation is excellent. It was a lot easier to write complex scripts, and within a few months of first picking up Python, I had written UIs which automated my entire animation pipeline, speeding up me and my classmates project significantly. That would not have happened if I stuck with MEL.
So yeh, learn a bit of MEL to begin with, but jump on Python as soon as you feel ready for it.
Thank you for this comment. This is what I was leaning towards in regards to becoming more educated in one or the other. Seems to be more effective to learn Python for its multiple uses outside as well.
Can't find what you're looking for? Ask the community or share your knowledge.