Fibermesh to maya curves (script)


Thank you so much Francesco for your screen grabs!

Here there is a small video showing the script in action:

At 0:49 you will notice that I select the code in the script editor and I execute it. To fire it press ctrl+enter.
Actually the best way is to select that code and drag’n drop it into a shelf (mid btn), so you will have only to click the newly created button next time.

furthermore, I want to report again the code to execute the script in gui mode, as I… emh, made a typo error (I corrected the previous post too):

import fibermesh_to_curves as ftc


And here a small video for newbies looking for a way to convert curves to an hair system:

PFx hair don’t really look so great tough, as they not blend nicely together.
You could also try to use maya fur combed by maya hair, but if you have it, use Shave and a Haircut and comb its guides with the curves generated by the script.


Bravissimo! :thumbsup: :bowdown:

and thanks for the tutorials, she works very nicely with GoZ.


eheheh and also thanks for this Mario!!!



I managed to briefly check the new version on both Maya 2009Sp1 and Maya 2012 SAP. Works smoothly without a hick-up! Many thanks again. :slight_smile:



I just updated the link.
I added the chance to eliminate all curves shorter than one value, as not everyone needs tiny curves. Currently you can use it only firing a command, but I am planning to add a panel to the gui with some new features (like this one), to edit the generated curves.

Here the necessary steps:

  1. Download the script here and replace the old one
  2. Select curves (or a group which contains them)
  3. write this code in the script editor (python) and execute it:
import fibermesh_to_curves as ftc

…where instead of 0.5 you specify a value between 0 and 1.
This value represents the percent of the longest curve. So, for example, if your longest curve is 5units long, and you specify 0.1 as value, all curves shorter than 0.5 units will be deleted

Kudos to Kenneth Finlayson having suggested this feature!

Added a tab in the gui to delete tiny curves :slight_smile:


Why cannot I download?


Hi KingMax02,
Have you succeded downloading the script? I just tried on another platform, in another location and with another connection, and it works fine by my side.

Please try again:
… and let me know if you still have the problem.



Thanks for making this free - I tried it out this morning and it works like a charm


This works in OSX as well ? Thanks


I hadn’t the chance to try it on osX, but yes, it should work.


I updated the script with a different “tolerance picking”.
Previously, I choosed fibers to be discarded according to zbrush creation order. This way, under some circumstances like a high number of curves to be created, caused the generation of bald areas.
Now I added the option to pick fibers randomly, instead of using a predefined pattern.

I left the option to choose the previous method (“ZB Creation Order”), as I suppose it should better work with a few amount of fibers (I could be wrong though), but it could be completely removed in the future, if a certain amount of users will report me it as useless.

The Random picking offers a seed field too, so you can try different results with the same amount of curves.

Hopefully Pixologic will come with automatic generation of curves in the next release. Anyway I will continue to give support to edit and create curves for hair and fur systems.

Cheers :slight_smile:


What would be a way to import curves into Zbrush for fibermesh?


In zbrush 4 r3,Pixologic will come with automatic generation of curves


It’s in my ToDo list.
I am on vacation this weekend, but I’ll dig into it on Monday.
I can’t check now, but there should be basically two ways:

  1. extruding a profile for every curve, converting every nurbs tube to polygons and the combine them in a unique mesh. You can’t do it manually though, as you should do it for loads of guides, so it needs to be scripted.
  2. Attach a pfx to your hair system, and converting it to polygons. This is something you could try by yourself, I will be more precise when I’ll be back.


Many thanks for the recent updates and your continued efforts! :slight_smile:

Btw, is it possible to have the curves centered on the individual fibermesh strand geometry along its entire length? I have not tried in newer ones, but with an older version of the script, I noticed the curve is located on one of the 2 outside edges.



exactly: currently the script generates the curve on one side of the fibermesh, as this way it is 2X faster.
While this usually doesn’t impact the general appearance of the the guides, as fibers are usually really narrow, I see your point though, as you could have some wide stripes to be textured with a stencil texture.
I will add an option to choose between the two methods.


Sweet! That sounds great! :thumbsup:




Could you make those 2 videos available for download on vimeo or just post to youtube?



hi, after i paste this command to script editor and press execute p, li { white-space: pre-wrap; } import fibermesh_to_curves as ftc


it gives me this error message:

Error: ImportError: No module named fibermesh_to_curves

please help me :frowning: