.OBJ missing colors / textures and it's driving me crazy.

Started by Jgone, May 01, 2017, 04:24:45 AM

Previous topic - Next topic

Jgone

Hello again you wizards of Terragen.
Before i start my rant, i have tried searching the forums and google and everywhere. I have stumbled upon a few similar topics but they haven't been helpful to me at all.
Before i had the problem that models that i created in zbrush didn't have colors in them, i've figured that out. But nothing applies here.

When i open an .Obj , the textures won't load. They all show as white.
https://gyazo.com/8f74fad9f83657b9f4974c03cea55c59

When i go to the internal network of the object
https://gyazo.com/d6692d915136f688c79ea3329cde940b

Everything looks like this (as if there is nothing assigned to the .obj ??)
https://gyazo.com/b377d13fc343711fb3a1b30a573d678a

And in windows the .obj and .mtl files are right next to each other like this.
https://gyazo.com/af0c7c4b454d395289e5915e078e3526

What am i missing ? What needs to be done to get these models show properly ?
Sorry if i explained something wrong, please ask questions if needed to get this thing sorted out.
It's really bugging me  :-X


Edit: and also for those who don't know. Gyazo is a screenshot capturing software/site. So the links are safe.
Edit2: Apparently there are some error messages too: https://gyazo.com/59d0ffb808ec58173901f6adbba9543d

masonspappy

ok, going to make an assumption that your .OBJ and .MTL files reside in the same folder.
That being the case, can you open your .OBJ file with wordpad (or similar text editing app) and see where the MTLLIB is pointing to?
In example below the MTTLIB is pointing to Coffee_Pot.mtl, and because there is no path (for example 'C:\temp' or 'D:\CoffeePot') then the OBJ file assumes it doesn't need to look outside it's own directory for it.
If there is a path name qualifier, then delete it (or comment out), leaving only the MTL file name, then try to reload your OBJ file and see what happens.




Dune

You can of course assign the textures freshly in TG and save as tgc or tgo. Or try taking the obj through Poseray to check all. I gather you did UV or assign textures in ZB?

Jgone

Quote from: masonspappy on May 01, 2017, 09:04:44 AM
ok, going to make an assumption that your .OBJ and .MTL files reside in the same folder.
That being the case, can you open your .OBJ file with wordpad (or similar text editing app) and see where the MTLLIB is pointing to?
In example below the MTTLIB is pointing to Coffee_Pot.mtl, and because there is no path (for example 'C:\temp' or 'D:\CoffeePot') then the OBJ file assumes it doesn't need to look outside it's own directory for it.
If there is a path name qualifier, then delete it (or comment out), leaving only the MTL file name, then try to reload your OBJ file and see what happens.

Hey, it's pointing out to the proper .mtl file that is inside the same folder like i show'd in the screencap above. So this is one .obj opened in notepad++
https://gyazo.com/1f86653794e4474ef53e4a796fa70c51

And it's inside the folder like this
https://gyazo.com/26c19a50d49e9e03d0916e0c84eae870

So shouldn't everything be good right now ?
Quote from: Dune on May 01, 2017, 09:08:51 AM

You can of course assign the textures freshly in TG and save as tgc or tgo. Or try taking the obj through Poseray to check all. I gather you did UV or assign textures in ZB?
Sorry if i explained it wrong. I didn't create these files, but i have created files in ZB and figured out how i got the colors to work. But these are bought models from a trusted site. Legit .obj's that don't show textures for me currently.


luvsmuzik

Because I am wondering too, Is there a way to save these obj files with the textures packed inside a texture folder within the obj file where it doesn't matter about the directory (except the obj file itself) as the texture is inside the obj folder? Everything has become so portable with sharing and buying objects...

I have tried packing in Blender but then I start getting warnings if I want to change an original texture when I am experimenting making a new object.

Also in Poseray, (or my copy) the header is all about Poseray ...is it okay to put a simple text line, like made by "so and so" and "free for whatever use" or "not to be used for" under this header?

masonspappy

I'm a bit confused.
in your first post, the last line indicates you are getting error messages, but these indicate that the system can't find a 'Grass_mowed_variant1.MTL'  which is associated to MTL file 'Grass_mowed_variant1.OBJ'.
But the files you were originally discussing were 'SI3D_0013_Ornamental_grass1_OBJ" which is associated to 'Ornamental_Grass1.MTL'.   (at least according to the error messages).
Maybe I'm missing something?
On the other hand, If you are using these strictly for Terragen then you could do as Dune previously suggested.

masonspappy

Quote from: luvsmuzik on May 01, 2017, 09:35:04 AM
Because I am wondering too, Is there a way to save these obj files with the textures packed inside a texture folder within the obj file where it doesn't matter about the directory (except the obj file itself) as the texture is inside the obj folder? Everything has become so portable with sharing and buying objects...
I have tried packing in Blender but then I start getting warnings if I want to change an original texture when I am experimenting making a new object.
Also in Poseray, (or my copy) the header is all about Poseray ...is it okay to put a simple text line, like made by "so and so" and "free for whatever use" or "not to be used for" under this header?
Don't know what kind of capabilities Poseray has, but I've often wished Blender has a function called "export as portable" which would create a folder for the OBJ & MTL file, put copies of the image files in the folder, then adjust the pathnames in OBJ and MTL files to point into that folder".
I also wish there was a Santa Clause and that I was rich....  ;D

Dune

Well, in Poseray you can assign textures to parts, and it exports a proper mtl file with the obj (so no problem if you use generic textures from way somewhere else). But you can also combine parts that have the same texture (which is very handy in DAZ figures e.g.), so you have less parts with default shaders in TG.

j meyer

Do you have the texture files (images) in the same folder as the .obj files?

luvsmuzik

Quote from: masonspappy on May 01, 2017, 10:42:35 AM
Quote from: luvsmuzik on May 01, 2017, 09:35:04 AM
Because I am wondering too, Is there a way to save these obj files with the textures packed inside a texture folder within the obj file where it doesn't matter about the directory (except the obj file itself) as the texture is inside the obj folder? Everything has become so portable with sharing and buying objects...
I have tried packing in Blender but then I start getting warnings if I want to change an original texture when I am experimenting making a new object.
Also in Poseray, (or my copy) the header is all about Poseray ...is it okay to put a simple text line, like made by "so and so" and "free for whatever use" or "not to be used for" under this header?
Don't know what kind of capabilities Poseray has, but I've often wished Blender has a function called "export as portable" which would create a folder for the OBJ & MTL file, put copies of the image files in the folder, then adjust the pathnames in OBJ and MTL files to point into that folder".
I also wish there was a Santa Clause and that I was rich....  ;D

What I often do is store a downloaded object in a "Never never change land" folder, then create a new folder for that object, copying everything from original, then import to Blender, checking everything texture-wise, then export back again to my new folder, giving me an mtl with my directory file instead of object original. This works until I forget and do some outlandish sorting, like dropping the object folder into a Terragen tgd project folder...so everything is together like a family ;D

Oshyan

Have you tried opening the .mtl files with a text editor and looked at the contents?

- Oshyan

bobbystahr

As I have that grass collection I went to the root folder and then to Textures for that species and I copied them all to the folder where the .obj and .mtl files live.
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

Jgone

For me the explanation was simple. I actually had to copy texture files separately from the package that i bought to the same folder.

I think i always thought that MTL files always automatically somehow included the textures, and this is obviously not the case.

Thanks for all the patient people who took time to help me out :) !

luvsmuzik

It depends on how many error messages you can live with too sometimes. I do not know if it is object by object, but if the mtl path and Terragen search disagree, you will get a message.

bobbystahr

What I've been trying to figure out, as I know what's in that package, is why you didn't just use the .tgo. as that pack of Walli grasses comes with them.
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist