Page 2 of 2

Re: No way to tell obj where to look for materials

Posted: Fri Nov 02, 2018 10:56 am
by phantombeta
Major Cooke wrote:But deprecating the skin property... How else are we supposed to provide the textures for it? How do you put them in and have them export via blender directly into the model then? I for one have seen NO signs of being able to ever do this. Please do tell me how! I'd love being able to avoid needing to export the skin as well.

Second, if you deprecate the skin property, I don't see how we'll be able to apply materials like specular, normals, and bright maps.
Nash has explained how to do this before, both here and on the ZDoom Discord server.

Re: No way to tell obj where to look for materials

Posted: Fri Nov 02, 2018 10:57 am
by Major Cooke
dpJudas: Being able to skip the TEXTURES definition would be appreciated. How about a "Diffuse" property where you can point to the texture file's location?

Phantom: Sweet! I'll check it out.

Re: No way to tell obj where to look for materials

Posted: Fri Nov 02, 2018 11:07 am
by Major Cooke
Okay, I took a look at it, but the big question is: can it support multiple materials being used? Or do I have to bake and unwrap it?
Because that's the problem I'm facing personally which makes mtl reading far more favorable for things like this. If I scale down the UVs, the textures grow far too large and making different resolutions of textures doesn't help one bit.

Re: No way to tell obj where to look for materials

Posted: Fri Nov 02, 2018 11:12 am
by dpJudas
Major Cooke wrote:dpJudas: Being able to skip the TEXTURES definition would be appreciated. How about a "Diffuse" property where you can point to the texture file's location?
What I'm saying here is that trying to automatically map the model format's material definitions to engine materials is often a bad idea as the data sets do not fully overlap. Even when they do, there's often problems because paths may not match, one tool might interpret it differently than the other. Subtle stuff like some properties will work, some won't. It is a can of worms.

For those reasons, I'm recommending not trying to support .mtl files directly - or at least only support for pulling out a base texture name for you. I'm not the maintainer of the obj feature, so I'm just voicing my opinion here.

Re: No way to tell obj where to look for materials

Posted: Fri Nov 02, 2018 11:23 am
by Graf Zahl
I think it should work like all other formats:

Use whatever is present in the model if no skin is set, and use a skin if one is set. This necessitates removing the error message, though.