diff options
| author | Matias N. Goldberg <dark_sylinc@yahoo.com.ar> | 2023-09-24 19:37:33 -0300 |
|---|---|---|
| committer | Matias N. Goldberg <dark_sylinc@yahoo.com.ar> | 2023-09-24 19:37:33 -0300 |
| commit | ec0e6800bc567ce356bf696fe2dcaf6f4bd2d1a6 (patch) | |
| tree | d71a6bdebe68fae98149215b41fc9c1ea8d5f45f /modules | |
| parent | c12d63556b5c1da03a00dd4c45c40e60bd8d68c2 (diff) | |
| download | redot-engine-ec0e6800bc567ce356bf696fe2dcaf6f4bd2d1a6.tar.gz | |
Fix gltf importer forcing vertex colors on all materials
The importer already checks if a mesh has vertex colors and enables
vertex colors on the material using it.
Before this fix, GLTF importer would force shader generation to use
vertex colors even if the scene did not have vertex colors at all, or
did not need them; causing inefficient shader and PSO generation.
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/gltf/gltf_document.cpp | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/modules/gltf/gltf_document.cpp b/modules/gltf/gltf_document.cpp index e98b83359d..d5dbaf2239 100644 --- a/modules/gltf/gltf_document.cpp +++ b/modules/gltf/gltf_document.cpp @@ -3877,7 +3877,6 @@ Error GLTFDocument::_parse_materials(Ref<GLTFState> p_state) { } else { material->set_name(vformat("material_%s", itos(i))); } - material->set_flag(BaseMaterial3D::FLAG_ALBEDO_FROM_VERTEX_COLOR, true); Dictionary material_extensions; if (material_dict.has("extensions")) { material_extensions = material_dict["extensions"]; |
