Author Topic: .OBJ missing colors / textures and it's driving me crazy.  (Read 801 times)

Offline Jgone

  • Member
  • *
  • Posts: 42
.OBJ missing colors / textures and it's driving me crazy.
« on: May 01, 2017, 08:24:45 AM »
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
« Last Edit: May 01, 2017, 08:58:49 AM by Jgone »

Offline masonspappy

  • Member
  • *
  • Posts: 1716
  • "I am my own worst-case scenario"
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #1 on: May 01, 2017, 01:04:44 PM »
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.




Offline Dune

  • Member
  • *
  • Posts: 12827
  • Corkscrew Bird
    • www.ulco-art.nl
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #2 on: May 01, 2017, 01:08:51 PM »
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?
In case you still haven't seen enough of my work: www.ulco-art.nl

Offline Jgone

  • Member
  • *
  • Posts: 42
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #3 on: May 01, 2017, 01:21:16 PM »
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 ?

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.


Offline luvsmuzik

  • Member
  • *
  • Posts: 1595
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #4 on: May 01, 2017, 01:35:04 PM »
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?

Offline masonspappy

  • Member
  • *
  • Posts: 1716
  • "I am my own worst-case scenario"
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #5 on: May 01, 2017, 01:53:13 PM »
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.

Offline masonspappy

  • Member
  • *
  • Posts: 1716
  • "I am my own worst-case scenario"
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #6 on: May 01, 2017, 02:42:35 PM »
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
 

Offline Dune

  • Member
  • *
  • Posts: 12827
  • Corkscrew Bird
    • www.ulco-art.nl
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #7 on: May 01, 2017, 02:57:25 PM »
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.
In case you still haven't seen enough of my work: www.ulco-art.nl

Offline j meyer

  • Member
  • *
  • Posts: 2023
    • orkwarts
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #8 on: May 01, 2017, 05:12:26 PM »
Do you have the texture files (images) in the same folder as the .obj files?

Offline luvsmuzik

  • Member
  • *
  • Posts: 1595
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #9 on: May 01, 2017, 05:58:56 PM »
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

Offline Oshyan

  • Planetside Staff
  • *
  • Posts: 11796
  • Holy snagging ducks!
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #10 on: May 01, 2017, 07:53:39 PM »
Have you tried opening the .mtl files with a text editor and looked at the contents?

- Oshyan

Offline bobbystahr

  • Member
  • *
  • Posts: 8204
  • Turn, and face the Strange Ch Ch Changes...D Bowie
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #11 on: May 02, 2017, 02:54:58 AM »
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

bobbystahr

Offline Jgone

  • Member
  • *
  • Posts: 42
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #12 on: May 02, 2017, 12:11:34 PM »
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 :) !

Offline luvsmuzik

  • Member
  • *
  • Posts: 1595
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #13 on: May 02, 2017, 12:33:48 PM »
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.

Offline bobbystahr

  • Member
  • *
  • Posts: 8204
  • Turn, and face the Strange Ch Ch Changes...D Bowie
Re: .OBJ missing colors / textures and it's driving me crazy.
« Reply #14 on: May 02, 2017, 01:22:26 PM »
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

bobbystahr