Object and terrain interactions

Started by iaminonsiner, February 06, 2019, 02:03:58 pm

Previous topic - Next topic

digitalguru

QuoteI don't think you can delete UV's in Poseray.


You can do it in Meshlab (free program) by loading the object and re-saving it with texcoord option turned off.

QuoteHave to try that, as I can imagine people won't like to get their objects stripped of UV's


If it's something like a rock, which would be much better procedurally shaded in Terragen it's no hassle to make a copy with the UV's deleted, though as that's something that might happen often it would be good too have a button to ignore UVs in the obj loader? - though being Terragen there might be another way around it  :)


sboerner

QuoteIf it's something like a rock, which would be much better procedurally shaded in Terragen it's no hassle to make a copy with the UV's deleted, though as that's something that might happen often it would be good too have a button to ignore UVs in the obj loader? - though being Terragen there might be another way around it


A option to select global coordinates for shading/displacements would be handy. But that doesn't address why the shells are breaking apart in the first place.

Interesting thread.

Oshyan

I'm pretty sure if you just bypass the Parts Shader you're working without UVs. This of course shades the entire object. You can't shade part of an object without UVs as far as I know.

- Oshyan

Dune

February 20, 2019, 02:54:49 am #18 Last Edit: February 20, 2019, 03:00:48 am by Dune
Strangely, I don't get the torn edges when rendering with UV, and with parts shader and default shader from your basic setup, but through transform shader. Though it's an older version of TG (3.7).
And they're not hidden behind that (bucket error) block  ;)

Matt

Quote from: digitalguru on February 19, 2019, 09:06:03 am
I did try a render with the teapot with UVs and the transform shader, but I get displacement cracks where the UV shells are:


The UVs (or lack of) would not cause this. It's an issue with the normals.
Just because milk is white doesn't mean that clouds are made of milk.

Matt

February 20, 2019, 03:10:58 am #20 Last Edit: February 20, 2019, 03:13:35 am by Matt
Quote from: Oshyan on February 19, 2019, 04:37:51 pm
I'm pretty sure if you just bypass the Parts Shader you're working without UVs. This of course shades the entire object. You can't shade part of an object without UVs as far as I know.


The Parts Shader's purpose for is for selective assignment of different materials to different parts of the object. That is a completely different thing from UVs, although UVs are often used to map different parts of an object into the same material. Bypassing the Parts Shader doesn't bypass UVs.
Just because milk is white doesn't mean that clouds are made of milk.

sboerner

QuoteStrangely, I don't get the torn edges when rendering with UV, and with parts shader and default shader from your basic setup, but through transform shader. Though it's an older version of TG (3.7).


Same result here with Terragen 4. Just downloaded and mapped the teapot and rendered with the displacement going through a transform shader. Digitalguru, would you mind sharing the model that was breaking apart? I'm curious to take a peek at those normals.


Oshyan

Quote from: Matt on February 20, 2019, 03:10:58 am
Quote from: Oshyan on February 19, 2019, 04:37:51 pm
I'm pretty sure if you just bypass the Parts Shader you're working without UVs. This of course shades the entire object. You can't shade part of an object without UVs as far as I know.


The Parts Shader's purpose for is for selective assignment of different materials to different parts of the object. That is a completely different thing from UVs, although UVs are often used to map different parts of an object into the same material. Bypassing the Parts Shader doesn't bypass UVs.


How are the Parts Shaders determined/derived in the first place then?

- Oshyan

digitalguru

February 20, 2019, 07:37:58 pm #23 Last Edit: February 20, 2019, 07:50:17 pm by digitalguru
Aha! I see what I did - I had the Transform shader after the default shader not going into function slots of the shader - works with UVs and no UVs now.

Matt

February 20, 2019, 11:32:25 pm #24 Last Edit: February 20, 2019, 11:34:48 pm by Matt
Quote from: Oshyan on February 20, 2019, 06:31:17 pm
How are the Parts Shaders determined/derived in the first place then?


There are various ways that object materials or groups can be defined in an OBJ file. If the OBJ has lines beginning with "usemtl" or "usemap", Terragen interprets those as material assignments and creates a "part" for each one. For example "usemtl leaf", "usemtl trunk" and so on. Also, OBJs sometimes contain "groups", and Terragen looks at those if it doesn't find any material-related commands that it knows about.

UVs are a completely different concept. They are the X,Y texture coordinates for each vertex. Every vertex should have a UV value attached if you want to do texture mapping.

UVs can be used to texture map an OBJ even if there was no material description. And materials/groups can be used to set up different shaders even if there are no UVs, as long as you don't need any texture maps.

Of course, most OBJs have both of these sets of data.
Just because milk is white doesn't mean that clouds are made of milk.

sboerner

QuoteAha! I see what I did - I had the Transform shader after the default shader not going into function slots of the shader - works with UVs and no UVs now.


Glad it's working!