Fiber 2.03 (update May 25, 2004)

Fiber Version 2
It’s here, and these are some of the new features:

Change log
2.03- Updates in Blender 2.33 make dynose obsolete.
2.02- Auto UV [CARD method] makes texturing easier, also has support for transparency,
bumpmapping, ect.
2.01- Now fully platform-independent

  • GUI is compatible with Blender 2.28, complete with file selector
    2.00- Use bezier curves to ‘comb’ hair
  • Wind and animation routines are back in (they were removed from 1.3)
  • Guide Fibers let you control the direction the fibers travel (See images)
  • Automatic detection of vertex paint, so no more errors!
  • All base meshes are stored in a file, so no need to have them selected anymore at runtime!
  • Optimized code runs faster and with fewer possible errors
  • Clumpy hair lets you make dreadlocks, mowhawks

http://www.orst.edu/~dennisa/Blender/Fiber2/FiberGUI.jpg
An example of Fiber 2 using Bézier Fiber Guides

I haven’t had much time recently to update the script because of school and work, but I’ll get around to some major updates soon- I promise! There are still some known bugs in the script- mostly dealing with crashing when trying to rebuild fibers if the existing fibers have a material applied to them.

Download the script here:
http://www.orst.edu/~dennisa/Blender/Fiber2

For example images from my script, head over to http://oregonstate.edu/~dennisa/Blender/Fiber2/gallery.html

JAH, MAAN! DREADLOCKS!

Downloading. See you all next week, when i finished playng with it…
Screenshot looks great, good work!

Daniel

:o :o
WOOW
amazing

Thank’s

kino

Great man… :smiley:

I’m of to try this thing.

Great stuff! One killer script. Thanks

Blend On

INCREDIBLE !!!
I’m speechless in front of such a wonder !!
It contains EVERYTHING I wanted to see in a new version !
But (cause there’s always a “but”), I’ve got a problem with the sliders.
I can’t enter numéric value throught manual input. And also the sliders aren’t following mouse cursor. they just increase of few decimals, then stop. So I have to move the sliders about an hundred time to increase of 20, for example.
Indication : I’m using Blender 2.28a, Python 2.23, and XP family version.
I hope it helps. Anyway, let me congratulate you for this AWESOME script. I had a lot of pleasure when using it on my first project.
I can say I’ll get even more pleasure with it with my second…ooops…I’ve said nothing :slight_smile:
GRATS GRATS GRATS again !!!

This is the only compatability problem I know of with 2.28. I wrote this script in 2.23, but the GUI doesn’t like my code… The easiest solution for now is to download 2.23 from Blenderwars.

http://www.blenderwars.com/content.php?module=blenderdl

It works fine with Blender 2.23 !
But is there any chance someday you’ll make it compatible with 2.28a?
someday…?
plllleaaaaasssse ??? :wink:

I’m definitly trying to find the cause of the problem. I’m trying to make it 100% compatible with 2.28, but I’m not sure how I’ll have to change my code in order for it to work.

Thanx Ripsting, that’s wonderful !

when i try the demo-blend, select the grass.fib, hit create i get:

1494 faces predicted
Unable to read parameters. Please run the GUI first and make sure you have file creation permissions.
Traceback (most recent call last):
File “/home/daniel/Programme/blender-creator-2.23-linux-glibc2.1.2-i386-static/Fiber2GUI.py”, line 195, in bevent
RunFiber()
File “/home/daniel/Programme/blender-creator-2.23-linux-glibc2.1.2-i386-static/Fiber2.py”, line 381, in RunFiber
LoadPreset()
File “/home/daniel/Programme/blender-creator-2.23-linux-glibc2.1.2-i386-static/Fiber2.py”, line 54, in LoadPreset
FVersion = readfloat(f)
UnboundLocalError: Local variable ‘f’ referenced before assignment

I tried every Blender from 223 to 228, python path is set…
Am i dumb? :frowning:

Wonderfull job!

Now i can make good hairs for my warior. :o

Great I’ll be trying this soon. On the conversion to 228.a, jms has updated several scripts to 228 including, including the yablex and obj import script, maybe he can help you out. Thanks
Paradox

No need for help :
the script works perfectly well on 2.28a, just think to load the script
dynoise.py too and add a zero,

,0

at the end of each slider declaration.

Nice! The control curves realy do a nice job! Still have to try wind though!

You never said whether adding uv along the fibers would be possible on generation?

Anyway, Thanks! Really great stuff! :smiley:

Nice utility, thanks for your work.

A couple comments. First, if you could use os.sep instead of “\” to do your path/filename manipulations, that’d make it a tad more platform independent. This would need to be changed in two places if you want to do it, Fiber2GUI.py and
Fiber2.py have similar sections of code:

#Get the current path and filename
a = Blender.Get(“filename”)
b = Blender.sys.dirname(a)
a = a.split("\")[len(a.split("\")) -1]
fname = b +"\" + str(a.split(".")[0]) + “.fib”

add an “import os” to these files and change them similarly to:

#Get the current path and filename
a = Blender.Get(“filename”)
b = Blender.sys.dirname(a)
a = a.split(os.sep)[len(a.split(os.sep)) -1]
fname = b +os.sep + str(a.split(".")[0]) + “.fib”

Those changes ran under linux for me, but I didn’t take the time to boot up a windoze box and try it out there.

The script seems to be very dependent on the actual size of the object. The model I tried it on was modeled at one blender unit == one foot. It didn’t appear possible to get good results with my scalp at this scale. Scaling the scalp up by a factor of 10 and then applying Fiber2 against it made things work much better. There must be some assumed units to the density value as well as some other parameters. I’m not sure what the ultimate solution to this would be, unless perhaps you added a texture space button or something that would somewhat associate the density and other factors with the scale of the object.

Again, this can be worked around in most circumstances. I’m only trying to give you feedback on my use of the script.

I am running this under 2.28a and while the script works, I gave up on using the GUI directly. Doing SHIFT-LeftClick to assign variables and/or moving the sliders produces unpredictable, or at least unexpected, results. Sometimes variables other than what you are setting are modified, sometimes several are modified. Sorry, I haven’t looked into this at all yet as it wasn’t a show stopper for me, :D.

Since the load and save preset buttons worked, I edited the .fib file in emacs to change my parameters and was able to get it to work.

Donesn’t works on Linux
228a and 2.25 tested

228a :
Path to fname not configured
lot of errors on console, when i give a name to fname:


Using a clean Global Dictionary.
In Object_GetSelected()
1494 faces predicted


RipSting's Fiber Generator v2.0, running on 1 object(s)
Traceback (most recent call last):
  File "Fiber2GUI.py", line 195, in bevent
    RunFiber()
  File "/home/metal3d/blender2.28/blender/Fiber2.py", line 530, in RunFiber
    for x in range (FpF[fnum]): #loop for density in each poly
IndexError: list index out of range

good luck

OSX 2.28 and 2.28a

Error Totblck: 2
button string len: 520 0x25878dc
button string len: 48 0x24e5cec

Blender quit
Using a clean Global Dictionary.
imported from text buffer…
In Object_GetSelected()
1494 faces predicted
Unable to read parameters. Please run the GUI first and make sure you have file creation permissions.
Traceback (most recent call last):
File “Fiber2GUI.py”, line 195, in bevent
File “Fiber2.py”, line 381, in RunFiber
File “Fiber2.py”, line 54, in LoadPreset
UnboundLocalError: local variable ‘f’ referenced before assignment

Fiber 1.3 DID work after I but the diana.py file in the blender program. Did the same for this yet does not work…

^v^

Amazing! Thanks RipSting! :smiley: :smiley: :smiley:

Env

Cool :slight_smile:

Thanx a lot

Stefano