image image image image image

Script for Maya, based upon Worn Edges by Neil Blevins

cgx_wornEdges script


To download:

cgx_wornEdges at Creative Crash or Here

To use it:

Place the .py file in your scripts folder, restart Maya and execute the following code from a Python tab in your Script Editor:


Paints hard edges, in a user defined threshold, using Vertex Paint. Look for the Help in the script to get a lot more info about it.

Script based upon Neil Blevins’ ( Worn Edges Using A Distorted Vertex Map and his DVD for The Gnomon Workshop.

I recommend using a Warp Node as the one from Binary Alchemy to get better results. I also used to work with the Raylength node from Binary Alchemy to do the same thing as the script but since it is raytrace based many times the rendering time needed to get noise-free renders were too high.


Use case:

This script was used by my fellow artist Adriana Nieto as a base layer to paint the Worn Edges for the soldiers in this TVC (where I worked as Lead CG artist):



Q. The script is not creating the shading network as in your tutorial.
-Make sure you have Mentalray loaded in Settings/Preferences, Plugins Manager. The script relies on Mentalray to get the vertex info out of the geometry.
Q. The script doesn’t work in my Maya version.
-I have tested and used the script in Maya versions from 2008 and up to 2014. If you’re having problems, I can help but only if you send me the error or warning you’re getting when you try to use it.


Hope you find it useful. Your feedback will be greatly appreciated.


(18-12-2010): I got more feedback than I expected and worked on the script (I didn’t expect any feedback to be honest, haha). There are a couple to do’s pending.

(19-12-2010): Added a new option that creates a Maya Set containing the vertices used by the script. This will allow you to do things like growing or shrinking the resulting vertex map using Maya’s vertex painting and selection tools. Also, cleaned up the code a little bit.

(20-12-2010): Uploaded the wrong version yesterday, sorry for that.

(19-01-2011): Fixed a bug that connected the vtxMap to an empty colorSet. Thanks Vic Fina!!

(21-10-2012): Optimized a few lines to make the script faster.

(05-11-2012): More code optimizations to make the script faster. New UI creation code added. Changed the way the UI is created so please use the new code (see above). Videotutorial added too at


Virgil 20-05-2012, 20:38

hi, the rar file is either corrupted or it doesn’t exist, can you pls make it available again? thanks! :}

Chris Granados 20-05-2012, 21:24

Hey Virgil,

Changed the link to point to creative crash.

Thank you for the heads up!!

Mauricio 11-11-2013, 01:20

Hey Chris … great script ..sadly it doesn’t work on newer versions of maya ! … any chance of an update to Maya 2013 ?

Thanks !!

Xian 11-11-2013, 01:33

Hey Mauricio,

I have tested and worked with the script in Maya 2008 and up to 2014. All cases working perfectly with no workarounds.

Can you please tell me what error are you getting in your script editor when you try using it? That might help me find a solution to your issue.

Anyway, make sure you have a Python tab to execute the script, make sure you have Mentalray loaded in your plugins.

Thanks for letting me know about this. Take care!!

Isaac 13-01-2014, 21:07

Fantastic script!

However in maya 2014 there are some ui problems, I can’t type in float values for min/max angles becuase the text boxes for them are not visable – the only workaround I have is to manually edit the script’s min/max defualts which is very stupid on my part cause I don’t know python! Any chance for an update? Also, is it possible to add support for v-ray’s vertex color node instead of using mentalray’s?

Here is a link to a screenshot showing the problem:

I am using Maya 2014, on a Mac running the OS version 10.8.5 (Mountain Lion ).

Well done on this amazing and complex script.

Xian 13-01-2014, 21:29

Hey Isaac, thanks for pointing this out. I haven’t tested the script on any Maya running on Mac.

The code is correct, but it just doesn’t work with Mac OS. I’ll try a fix and send you the modified script. If it works for you I’ll publish that as a new version.

As for the Vray vertex color node, I’ll add it to my To Do list and post a comment here when it’s done.

Ryan 05-12-2014, 10:39

Hi Chris, I would really like to use this script for a research project but it doesn’t work on Mac OS / Maya 2015 (“# Error: ImportError: No module named #”).

I saw in your last comment that you were working on a fix for Mac — did you ever get this to work by any chance? Thanks in advance for your time!

p.s. there’s some kind of error in your “Contact” form

Xian 05-12-2014, 14:01

Hi Ryan,

I don’t have access to Mac based Maya’s and I didn’t got much help from the guy who asked for it so I haven’t been able to work on any fix. It was just a GUI fix.
You should be able to use the script anyway. Please make sure you’re locating the .py file in the correct Maya Scripts folder.
If this doesn’t work, just open the .py file with any text editor and Copy/Paste the entire thing into a Python tab in Maya’s script editor. At the end of it all add these two lines (without any indentation):

cgx_wornEdgesVar = CGX_WornEdgesUI()

Select all text in the script and hit Ctrl+Enter to run the script.

Let me know if this doesn’t work and I’ll try to help you back 😉


Pierre 20-08-2015, 05:08


im happy to found maya curvature map plugin. But its doesnt work anymore on 2015-2016.
Your toll is the own acceptable stuff on this i found on hours on google.

Like u please update it,


# Error: RuntimeError: file C:/Users/XXXX/Documents/maya/2016/scripts\ line 260: Maya command error #

=> mc.polyColorPerVertex(listaVertexNo , notUndoable = True , colorDisplayOption = True , r = colorFondo , g = colorFondo , b = colorFondo)

Vic 20-07-2015, 10:43

Would love to use this, but it’s giving an error in Maya 2015. Says there is a command error on line 261.

Am I doing something wrong, or does it not work with Maya 2015? If so, can it be updated?



internetPerson 15-01-2016, 08:39

Hi, i’m encountering the same problem as Isaac above. I can’t enter the min and max values due to an problem with the GUI. Using maya 2014 on mac OSX 10.10.3


Leave a Reply

Get email notifications

About me

I'm a Colombian living in Buenos Aires (Argentina) and working as a CG Generalist and Motion Graphics artist for TV shows and commercials for all around the world.
My professional goal is to be a Character Animator and to help me fulfill it I studied at Animation Mentor. (read more...)

Character Animation Reel 2014

Character Animation Reel 2014
It took a lot longer than I expected but after two broken arms, one graduation, many months of recovery and some crazy projects in between, here it is, my Character Animation reel. What a journey, and this is just the beginning!! Hope you like it 😉

Class 1 Progress Reel

Class 1 Progress Reel
So, this is my Progress Reel for Class 1 of Animation Mentor. Again, I really want to thank Don Kim for sharing all his knowledge with us. And of course, thank you classmates!! Without your comments and support this wouldn’t be half of what it is, haha Chris Granados Animation Mentor Progress Reel Class 1 […]

End of Class 1

End of Class 1
Ok, this is a sad but happy moment. I don’t think I’ve ever felt this way for school. I mean, I do want to take a break (because I had to work my ass off, haha) but I really want to keep learning from such great people (mentors and students). Last Q&A was really fun, […]
  • 1
  • 2
  • 3
  • 4