[SOLVED] Issues converting unlit textures in GLTF 2.0 from Blender 2.8

I’ve recently upgraded to Blender 2.8, and while the interface is completely different from what I’ve worked with, I managed to get some textures applied and blender 2.8 already has a GLTF 2.0 exporter included. My issue is, when I convert though the SDK, I get black textures and an error in the console: “Could not find loader for extension KHR_materials_unlit”.
I can work around this by making an emission texture and setting the texture in place of the color. That loads in the engine properly, but the result is a brighter color on the avatar (it is emission/light, after all).

Basically: Is there a “proper” way to skin something in blender 2.8 in a way that the SDK’s converter will handle from GLTF 2 0? I am using SDK 3.2.4 as well.

My options come down to:

  1. Find the "right’ way to skin it.
  2. Find a way to add a loader into the SDK.
  3. Load the model (as gltf or any another format) into the engine one way or another and use it to save to .j3o.
  4. Import the model in its hacked-together state (with the “glowing”), make alterations through the engine and re-save it to .j3o.

Given that I’m using a new Blender version and a different format for interchange in my pipeline, there are a lot of other unaccounted variables. I just found it odd that there’s astoundingly little mention of “Could not find loader for extension KHR_materials_unlit” in the forums. I found one post where it was mentioned, but not really addressed.
Thank you for your patience.

I must preface my comments by telling you I am not as familiar with pbr as others. From what I gather, you are using a non pbr material type.


Looking at the error, KHR_materials_unlit materials are not supported by the engine.

This material type is used for toon type materials according to kronos.

By reading the docs it looks like you have toggled this selection from the materials tab,

when it should be principled bsdf, as is shown.

If you are using the principled bsdf shader and having this problem, then maybe this will help,

The exporter supports Metal/Rough PBR (core glTF) and Shadeless ( KHR_materials_unlit ) materials. It will construct a glTF material based on the nodes it recognizes in the Blender material. The material export process handles the settings described below.

I would open the node editor and look for a broken link. The blender manual linked to give pictures of what to look for. Im just guessing though, others could probably narrow it down to the right setting.


Note: sometime it would be nice if JME’s gltf importer could support the unlit material type.

Edit: that’s not directed at anyone in particular but it is a missing feature that someone might try to contribute if so inclined.

1 Like

So just to be sure, do you mean for GLTF KHR_materials_unlit it should use JME’s Unshaded.j3md material?

That’s what I was thinking. I haven’t looked at any of it so I don’t know if it makes sense… but it “seems” logical, eh? :slight_smile:

1 Like

That seems to do the trick! I’d tried a few different materials (Trying emission got me where I was).
I guess I hadn’t tried that one before. Well, now if someone else gets the error they can find your solution when they search along those lines.

1 Like