Author Topic: Export Hair Particle Issue  (Read 17161 times)

2017-05-14, 19:03:31

Rac Leborg

  • Active Users
  • **
  • Posts: 50
    • View Profile
Hi All (I originally posted this at the end of Asticles topic on Hair Instances, but I should probably have created a new post - so here it is)

I am struggling to EXPORT OBJECTS (only modified) for the BLENDER HAIR particles, (for a simple carpet type).

1000 hairs  is ok until I switch on INTERPOLATION(default settings) and then it is either never going to finish or the system is hanging.

Switching DEBUG on and off  is making no difference.

Could someone give me a rough idea on how long the EXPORT should take with the attached carpet.blend file, with an I7 920 and 8gig ram.

Many thanks

2017-05-14, 23:27:41
Reply #1

burnin

  • Active Users
  • **
  • Posts: 1537
    • View Profile
i guess 100x1000 children to render is an overkill or smthng, set to same as in preview (10x1000)
tho there are some bugs with hair generation:
- using Ribbon for Strand Shape produced and error
- lowering Render Path Steps to 2, produces an error / twice*

....
experimenting further... ;)

use scarcely (alpha stage, not really production ready), to be on the safe side rather Render Objects (also better control of the 'look') than Paths

Edit:
Basically am getting errors on the first time after changing few settings, then after, just switching some element on&off, error doesn't occur anymore... and so on.

here are Ribbons 50children250particles=125K hairs


Is there a size limit (polys/verts) per object for the exporter?
« Last Edit: 2017-05-15, 00:08:33 by burnin »

2017-05-14, 23:45:50
Reply #2

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
I might have a way to make it faster again, just running tests on it now.

2017-05-15, 00:18:21
Reply #3

burnin

  • Active Users
  • **
  • Posts: 1537
    • View Profile
*Error from lowering value of Hair Render Path Steps to 2:
Code: [Select]
Traceback (most recent call last):
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 356, in render
    render_start( self, scene)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 38, in render_start
    render_scene( engine, scene)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 195, in render_scene
    result = bpy.ops.corona.export()
  File "C:\programi\b278c\2.78\scripts\modules\bpy\ops.py", line 189, in __call__
    ret = op_call(self.idname_py(), None, kw)
RuntimeError: Error: Traceback (most recent call last):
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\operators\export.py", line 42, in execute
    result = export(self, scene, placeholders)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 290, in export
    return _write(self, scene, filepath, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 322, in _write
    result = future.result(timeout = None)
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\_base.py", line 405, in result
    return self.__get_result()
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\_base.py", line 357, in __get_result
    raise self._exception
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 372, in _export_object
    result = decide_format( self, full_path, obj, scene, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 258, in decide_format
    return write_binary_obj( self, obj_path, obj, scene, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 887, in write_binary_obj
    meshes.extend( get_hairs(ob, scene, psys, crv_ob, crv, material, mesh))
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 242, in get_hairs
    crv_ob.data = crv_data
AttributeError: Writing to ID classes in this context is not allowed: corona_hair_tmp_curve.004_ob, Object datablock, error setting Object.data

location: C:\programi\b278c\2.78\scripts\modules\bpy\ops.py:189



location: <unknown location>:-1


Thick, 3 Steps


----------

I might have a way to make it faster again, just running tests on it now.

Nice :)

2017-05-15, 00:27:45
Reply #4

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
That is a painful error, I will see what I can do, I think it is Blender freeing memory before we are finished with the objects.

2017-05-15, 01:16:31
Reply #5

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
New hair exporter is available.

Make sure you are using binary object export, export hair is checked and stream hair is checked.

You can see some of the improvement in the attached graph

2017-05-15, 01:48:26
Reply #6

burnin

  • Active Users
  • **
  • Posts: 1537
    • View Profile
Ah, ok... Nice to know, user friendly info always helps :)

Also found
Path Timing is partly broken. (Start & End are fine).
Random value corrupts the influenced children - their tips are joined/pulled into the world origin / coordinate center (0,0,0).
eg.


PS.
(Orange) "2 = Error" is from previously mentioned problem. (would be fine if lower value is blocked - 3 (default) as the lowest value).
« Last Edit: 2017-05-15, 02:04:02 by burnin »

2017-05-15, 02:15:02
Reply #7

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
Do you have a sample .blend for this? I can't reproduce your 2 error or the random error.

2017-05-15, 02:30:55
Reply #8

burnin

  • Active Users
  • **
  • Posts: 1537
    • View Profile
Yup, file attached...
... and with the latest exporter (5.7.1) this scene became totally unusable - error is all i get:
Code: [Select]
Traceback (most recent call last):
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 356, in render
    render_start( self, scene)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 38, in render_start
    render_scene( engine, scene)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 195, in render_scene
    result = bpy.ops.corona.export()
  File "C:\programi\b278c\2.78\scripts\modules\bpy\ops.py", line 189, in __call__
    ret = op_call(self.idname_py(), None, kw)
RuntimeError: Error: Traceback (most recent call last):
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\operators\export.py", line 42, in execute
    result = export(self, scene, placeholders)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 547, in export
    return _write(self, scene, filepath, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 580, in _write
    result = future.result(timeout = None)
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\_base.py", line 405, in result
    return self.__get_result()
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\_base.py", line 357, in __get_result
    raise self._exception
  File "C:\programi\b278c\2.78\python\lib\concurrent\futures\thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 637, in _export_object
    result = decide_format( self, full_path, obj, scene, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 515, in decide_format
    return write_binary_obj( self, obj_path, obj, scene, curves)
  File "C:\Users\py\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\export.py", line 1223, in write_binary_obj
    if faceuv or facecol:
UnboundLocalError: local variable 'faceuv' referenced before assignment

location: C:\programi\b278c\2.78\scripts\modules\bpy\ops.py:189



location: <unknown location>:-1


2017-05-15, 02:31:51
Reply #9

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona

2017-05-15, 02:42:03
Reply #10

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
faceuv error is now fixed, still can't reproduce your random error or step=2 (I can export down to 0) error sorry

2017-05-15, 02:54:57
Reply #11

burnin

  • Active Users
  • **
  • Posts: 1537
    • View Profile
:D No problem,  can't reproduce neither of the bugs anymore. Using 5.7.2. Fixed. :)
Thanks for everything and all best... going off for a bit longer moment now.

Cheers

Edit:
Couldn't let it go.
Can't turn off Parents from always Rendering & Random centrifuge seems to be back. File attached.
eg.

Parents: ON, Random: OFF


Parents: OFF, Random: ON

« Last Edit: 2017-05-15, 03:48:44 by burnin »

2017-05-15, 20:09:14
Reply #12

Rac Leborg

  • Active Users
  • **
  • Posts: 50
    • View Profile
Hi

Sorry to say that I am still having a problem exporting hairs. (50,000) with Version 5.7.3 (I don't know where to download 5.7.1)

I have attached the error message.

Thanks


2017-05-15, 21:42:34
Reply #13

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
Sorry to say that I am still having a problem exporting hairs. (50,000) with Version 5.7.3 (I don't know where to download 5.7.1)
v5.7.4 has fixed this issue.

@burnin I am looking at those two issues now!  Thanks for persisting :D

2017-05-15, 23:42:46
Reply #14

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 414
    • View Profile
    • Blender exporter for Corona
Thanks @burnin,

This highlighted an issue with parents and children and how they are counted/calculated.
The hairs converging into the center was another issue which is solved now too.