Saving an obj object

Started by gregtee, February 23, 2014, 10:14:55 PM

Previous topic - Next topic

gregtee

How does one save an obj object? 

I've changed the surface settings of an obj object and now I want to bring that object into another terragen scene.  As near I can tell there's no option to save the altered obj into a new obj.  Am I missing something?

Thanks

Greg
Supervisor, Computer Graphics
D I G I T A L  D O M A I N

Hannes

Hi Greg, go into the node network and right click your object - "Save Object File".
There you go. You can choose between .obj, .tgo (which is the best solution when you want to use your object only inside TG), or .lwo.

j meyer

Or you could save as a clip file,that way you'd still have your
obj unaltered and can save positions etc.,too.

kaedorg

Yes you can save an object as a clip file and all its parameters will be saved (position, rotation, all internal nodes)

David

gregtee

Supervisor, Computer Graphics
D I G I T A L  D O M A I N

gregtee

So I tried to save the obj as a tgo and I keep getting an error about not finding something called a .mtl file.  Anyone know what this is?  It sounds like a material library but I have no idea where Terragen stores this information.

-Greg



Supervisor, Computer Graphics
D I G I T A L  D O M A I N

yossam

It is the material file associated with the .obj.  :)

gregtee

I'm not even sure what a .mtl file is.  Is this file saved somewhere, and if so, how is it applied?
Supervisor, Computer Graphics
D I G I T A L  D O M A I N

Upon Infinity

Quote from: gregtee on February 24, 2014, 02:39:12 PM
I'm not even sure what a .mtl file is.  Is this file saved somewhere, and if so, how is it applied?

They are created when an .obj file is saved or exported from a modelling program, at least if it has any surface properties.  It depends on the program, but they are typically saved in the same folder as the .obj file.  Even if you are saving a .tgo, you'll probably still need the .mtl file that originally went along with the .obj.  You will definitely need the texture images that were exported along with the .obj.  Was the object textured already, or did you do that in Terragen?

gregtee

It was partially textured when it came in but some of the other map channels weren't attached so I added them in Terragen, namely the spec and bump maps.  I also has to click off the unpremultiply checkbox under the Images tab and and select Use Alpha to get things to render correctly. 

Does the .mtl need to be updated to show these alterations?

Thanks

-Greg

Supervisor, Computer Graphics
D I G I T A L  D O M A I N

Upon Infinity

Quote from: gregtee on February 24, 2014, 04:34:44 PM
It was partially textured when it came in but some of the other map channels weren't attached so I added them in Terragen, namely the spec and bump maps.  I also has to click off the unpremultiply checkbox under the Images tab and and select Use Alpha to get things to render correctly. 

Does the .mtl need to be updated to show these alterations?

Thanks

-Greg

No.  Particularly if you're saving a .tgo.  If you save the .tgo in the same folder as the original .obj, you shouldn't have any problems.

gregtee

Alright I'll try it tonight when I get home.

Thanks for the help!

-Greg
Supervisor, Computer Graphics
D I G I T A L  D O M A I N

Oshyan

In general we suggest using Clip Files to save object modifications because TGOs can't be modified in other programs after saving (as no other programs support TGO). You can always convert non-protected TGOs to OBJ again later, but using a clip file has the advantages of TGO (saving Terragen node network info, internal texturing, etc.), while maintaining the ability to access the standard format OBJ directly later. The only disadvantage to the Clip File approach is you cannot populate Clip Files easily, but you can always add a population and just replace the object maker inside of it with your clip file for a relatively easy workaround...

- Oshyan

Matt

#13
If this is just a one-time thing you can just copy the nodes to the clipboard and then paste into the other project. If all of the object's associated shaders and other nodes are in the OBJ reader's internal network, just copy the OBJ reader node.

Think of it like a read node in Nuke.

Matt
Just because milk is white doesn't mean that clouds are made of milk.