diff options
author | Maurice Raybaud <mauriceraybaud@hotmail.fr> | 2013-12-15 17:25:14 +0400 |
---|---|---|
committer | Maurice Raybaud <mauriceraybaud@hotmail.fr> | 2013-12-15 17:25:14 +0400 |
commit | ec522f8d84f7d3005c99c179aa081fa367151dd4 (patch) | |
tree | fed5b379b02806c50eaf2f0bdffe97e8607e6e98 /render_povray | |
parent | e0b5cf1f21332ffc0f1d45247bc14ce7e86013d4 (diff) |
Fixed: 0 Hair amount error
Improved: exportable hair amount
Hair exported only the view percentage, full amount gets exported now. allowing much higher counts than what could get displayed. also since the lowest count (0) is no longer divided by the view percentage it removes a "division by 0" error.
Diffstat (limited to 'render_povray')
-rw-r--r-- | render_povray/render.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/render_povray/render.py b/render_povray/render.py index cdccf23c..05d7cabf 100644 --- a/render_povray/render.py +++ b/render_povray/render.py @@ -926,10 +926,10 @@ def write_pov(filename, scene=None, info_callback=None): file.write('#end\n') file.write('\n') - # Dynamically create a union of the hairs (or a subset of the hairs). - # By default use every 25th hair, which is usually ok for test renders. - - file.write('#ifndef(HairStep) #declare HairStep = %d; #end\n' % ((totalNumberOfHairs/(totalNumberOfHairs * pSys.settings.draw_percentage / 100)))) + # Dynamically create a union of the hairstrands (or a subset of them). + # By default use every hairstrand, commented line is for hand tweaking test renders. + file.write('//Increasing HairStep divides the amount of hair for test renders.\n') + file.write('#ifndef(HairStep) #declare HairStep = 1; #end\n') file.write('union{\n') file.write(' #local I = 0;\n') file.write(' #while (I < %i)\n' % totalNumberOfHairs) |