diff options
author | Dmitriy Romanov <dimonasdf@inbox.ru> | 2018-04-03 22:05:13 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-03 22:05:13 +0300 |
commit | 0812468d0508f04a3890054774668391b27759a4 (patch) | |
tree | c07edb57326424a8acd34fcbb4e708d71ba50e9b /editor/import | |
parent | 0e844f6c91dfc421c573c6ab784e2a96903413e3 (diff) |
Fix Collada material roughness import function 4
Made import conversion linear.
Diffstat (limited to 'editor/import')
-rw-r--r-- | editor/import/editor_import_collada.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/import/editor_import_collada.cpp b/editor/import/editor_import_collada.cpp index 282da239cc..c1e897a04c 100644 --- a/editor/import/editor_import_collada.cpp +++ b/editor/import/editor_import_collada.cpp @@ -480,7 +480,7 @@ Error ColladaImport::_create_material(const String &p_target) { } } - float roughness = (512.0 * (1.0 - Math::sqrt(1.0 - ((Math::log(effect.shininess) / Math::log(2.0)) / 9.0)))) / 503.0; + float roughness = (effect.shininess - 1.0) / 510; material->set_roughness(roughness); if (effect.double_sided) { |