[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [1933] trunk/py/scripts/addons/ io_scene_x3d/export_x3d.py: fix [#27364] X3D Export of fog is incorrect
Campbell Barton
ideasman42 at gmail.com
Mon May 16 10:04:12 CEST 2011
Revision: 1933
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-extensions&revision=1933
Author: campbellbarton
Date: 2011-05-16 08:04:12 +0000 (Mon, 16 May 2011)
Log Message:
-----------
fix [#27364] X3D Export of fog is incorrect
corrections from Yaroslav Zubkov (yzubkov)
Modified Paths:
--------------
trunk/py/scripts/addons/io_scene_x3d/export_x3d.py
Modified: trunk/py/scripts/addons/io_scene_x3d/export_x3d.py
===================================================================
--- trunk/py/scripts/addons/io_scene_x3d/export_x3d.py 2011-05-16 07:52:45 UTC (rev 1932)
+++ trunk/py/scripts/addons/io_scene_x3d/export_x3d.py 2011-05-16 08:04:12 UTC (rev 1933)
@@ -175,12 +175,13 @@
mparam = world.mist_settings
else:
return
- if (mtype == 'LINEAR' or mtype == 'INVERSE_QUADRATIC'):
+
+ if mparam.use_mist:
mtype = 1 if mtype == 'LINEAR' else 2
# if (mtype == 1 or mtype == 2):
self.file.write("<Fog fogType=\"%s\" " % self.namesFog[mtype])
self.file.write("color=\"%s %s %s\" " % round_color(world.horizon_color, self.cp))
- self.file.write("visibilityRange=\"%s\" />\n\n" % round(mparam[2], self.cp))
+ self.file.write("visibilityRange=\"%s\" />\n\n" % round(mparam.depth, self.cp))
else:
return
More information about the Bf-extensions-cvs
mailing list