diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-05-16 12:04:12 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-05-16 12:04:12 +0400 |
commit | 6010385319e8929bb66c230977ef594418504891 (patch) | |
tree | 141b373b52fa0d42c611937cd650af1274c4a247 /io_scene_x3d | |
parent | fca80ff61e8bbce39bc2584a6ad7e7659577d1b1 (diff) |
fix [#27364] X3D Export of fog is incorrect
corrections from Yaroslav Zubkov (yzubkov)
Diffstat (limited to 'io_scene_x3d')
-rw-r--r-- | io_scene_x3d/export_x3d.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/io_scene_x3d/export_x3d.py b/io_scene_x3d/export_x3d.py index 391f8ec3..4fa73b3b 100644 --- a/io_scene_x3d/export_x3d.py +++ b/io_scene_x3d/export_x3d.py @@ -175,12 +175,13 @@ class x3d_class: 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 |