diff options
Diffstat (limited to 'io_scene_obj/export_obj.py')
-rw-r--r-- | io_scene_obj/export_obj.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/io_scene_obj/export_obj.py b/io_scene_obj/export_obj.py index e7d646b0..00733dd1 100644 --- a/io_scene_obj/export_obj.py +++ b/io_scene_obj/export_obj.py @@ -79,14 +79,15 @@ def write_mtl(scene, filepath, path_mode, copy_set, mtl_dict): if mat.specular_shader == 'WARDISO': tspec = (0.4 - mat.specular_slope) / 0.0004 else: - tspec = (mat.specular_hardness - 1) * 1.9607843137254901 + tspec = (mat.specular_hardness - 1) / 0.51 fw('Ns %.6f\n' % tspec) del tspec + # Ambient if use_mirror: fw('Ka %.6f %.6f %.6f\n' % (mat.raytrace_mirror.reflect_factor * mat.mirror_color)[:]) else: - fw('Ka %.6f %.6f %.6f\n' % (mat.ambient * world_amb)[:]) # Ambient, uses mirror color, + fw('Ka %.6f %.6f %.6f\n' % mat.ambient[:]) # Do not use world color! fw('Kd %.6f %.6f %.6f\n' % (mat.diffuse_intensity * mat.diffuse_color)[:]) # Diffuse fw('Ks %.6f %.6f %.6f\n' % (mat.specular_intensity * mat.specular_color)[:]) # Specular if hasattr(mat, "raytrace_transparency") and hasattr(mat.raytrace_transparency, "ior"): |