GLTFExported model is way darker

Hey, made a tool to load all my json models one after the other and then export it via GLTFExporter. Some of my models dont have materials (via Clara.io) applied. When exporting im getting warnings that MeshStandardMaterial and MeshBasicMaterial are best for use when exporting to glTF. When I use my newly exported gltf models, they are all way darker then the original and they’re all using the MeshStandardMaterial, which makes them really metallic. Do i have to apply the MeshStandardMaterial before exporting myself and adjust values like metallness etc before exporting? And why is my texture getting darker? Im not getting it brighter with lights.
Also some models throw tHREE.WebGLState: Invalid blending: NormalBlending

Code https://gitlab.com/Robin3x60/gltf-converter

Thanks in advance

1 Like

From the GLTFLoader docs, you’ll want to set…

renderer.gammaOutput = true;
renderer.gammaFactor = 2.2;

… for correct colors. Or, alternatively, overwrite all the textures to .encoding = THREE.LinearEncoding after loading the models. If you’re including lights in models, you’ll also want renderer.physicallyCorrectLights=true.

glTF materials are either PBR or unlit, so it would be best to assign MeshStandardMaterial yourself and set metalness=0.

This thread may be helpful: https://github.com/mrdoob/three.js/pull/15552

3 Likes