Planetside Software Forums

General => Terragen Discussion => Topic started by: Valentina on January 15, 2016, 11:02:16 AM

Title: Issue with material of an imported obj
Post by: Valentina on January 15, 2016, 11:02:16 AM
Hi, hope this is the right section for my question.
I'm trying and playing with imported obj, I've read that if I have a .mtl file, then Tg will be able to recognize different materials (also with their names). So I checked the correct flag and now I have a mtl file and in the internal node of part shader (of the object) I can see one Default shader and one object part for each material, even with their correct names. Issue is.. obj is rendered in grey, not with its own material. If I go inside I find
object >>> parts shader >>> obj part >>> default shader  but obj part and its default shader are not linked togheter. Maybe the problem is this, but I cannot fix it. in the default shader I can see the correct color, but it doesn't affect the object during rendering.
What am I doing wrong?
ps I think an image could help, but I don't know if I can post an image here since there is a "image sharing" section. let me know, many thanks as usual
Valentina
Title: Re: Issue with material of an imported obj
Post by: j meyer on January 15, 2016, 12:08:30 PM
An image would indeed be helpful. And of course you can post an illustrative
image in this section, no problem.
Title: Re: Issue with material of an imported obj
Post by: Valentina on January 15, 2016, 12:30:19 PM
ok, there it is
[attachimg=1]

with this situation, I have no material applied on my object.. (i see it grey while the material is red).
Title: Re: Issue with material of an imported obj
Post by: j meyer on January 15, 2016, 01:01:57 PM
And connecting both manually doesn't work?
Title: Re: Issue with material of an imported obj
Post by: TheBadger on January 15, 2016, 01:21:34 PM
kinda sounds like the default lambert is the surface that is showing. But the easiest thing to do is to post the TGD and related files here.

Can you just make a TGD and the object in the sense and post it? Can solve and explain then.

Title: Re: Issue with material of an imported obj
Post by: Valentina on January 15, 2016, 01:25:19 PM
here is the file..
it is the same thing if the object has 2 materials or more: all floating and if I connect manually it breaks the connection itself.
Title: Re: Issue with material of an imported obj
Post by: j meyer on January 15, 2016, 01:33:39 PM
Strange!
What I would try - just to be on the safe side - is to remove the / before the word red
in your object file and try again. You have to do that in your modeling software though.
Title: Re: Issue with material of an imported obj
Post by: Valentina on January 15, 2016, 01:37:12 PM
Thanks I'll try that and let you know. I've read just on this forum a user's topic about an obj from rhinoceros (that I use) and he/she successfull imported all the materials. I'm pretty sure there is no "/" in my original file, but worths a try.
Valentina
Title: Re: Issue with material of an imported obj
Post by: Valentina on January 15, 2016, 01:44:53 PM
Hey! I'm not a mothertongue so probably I didn't catch what you were suggesting. I checked in Rhinoceros and there were no /, but in terragen it seems that once removed the / from the items name it works!

thank you!! really  :D

Valentina
Title: Re: Issue with material of an imported obj
Post by: j meyer on January 15, 2016, 01:48:18 PM
Cool!  :)
Title: Re: Issue with material of an imported obj
Post by: bobbystahr on January 15, 2016, 07:16:50 PM
Quote from: j meyer on January 15, 2016, 01:48:18 PM
Cool!  :)

Well done...I missed that
Title: Re: Issue with material of an imported obj
Post by: Oshyan on January 15, 2016, 09:07:24 PM
Slashes / are used as path indicators, like with file paths, so they should not be used in node names.

- Oshyan
Title: Re: Issue with material of an imported obj
Post by: Valentina on January 16, 2016, 06:21:51 AM
yes, I didn't think about deleting slashes.. though, I didn't put the slashes, Terragen did. but it's a solution, thank you all.
Valentina