Planetside Software Forums

General => Terragen Discussion => Topic started by: Hannes on February 17, 2014, 11:36:24 AM

Title: Side projection (again?)
Post by: Hannes on February 17, 2014, 11:36:24 AM
I found a few tips here in the forum, but didn't manage to get the texture of an image map shader at the vertical wall of a simple shape shader displacement. I would appreciate very much if someone could have a look at this very simple file I attached. Just feed the image map shader with any texture.
I already tried both side projection types and also tried to use a redirect shader. Either the texture is stretched vertically or everything is black. >:(
Title: Re: Side projection (again?)
Post by: Tangled-Universe on February 17, 2014, 12:02:05 PM
Hi Hannes,

Your projection settings are correct.

The issue is that the supersteep displacement causes amazing stretch in the surfaces, as you explained.
The compute terrain needs to compute surfaces and UV/texture coordinates for this surface, but with a very large patch size it probably won't calculate the sudden steepness of the terrain correctly, resulting in these massively stretched textures.

What you need, and I tested this with your file, is to give the displacement a slightly soft edge to allow more polygons to be created over the patch of surfaces.
Consequently you need to make the patches for calculating these surfaces smaller and thus you would also need to decrease the compute terrain's gradient patch size.
So I have set the sss's softness to 0.5 metre and decreased gradient patch size of the compute terrain node to 0.1 metres.
Now my texture maps much much better.

This isn't really desirable though if you do much displacement before this node or especially when you have computed the terrain before this compute terrain @ 0.1 metre gradien patch size.
Displacements can be more tricky to control and/or render times will start to go through the roof.

So at the moment this seems the only way to do it.
You may find one of my recent feature requests in the alpha forums interesting as it deals with this problem.
However, the method I describe doesn't overcome this issue directly, but can be at least a nice improvement.

Cheers,
Martin
Title: Re: Side projection (again?)
Post by: j meyer on February 17, 2014, 12:11:05 PM
Reminds me of that
http://www.planetside.co.uk/forums/index.php/topic,16160.msg157567.html#msg157567
Title: Re: Side projection (again?)
Post by: Dune on February 17, 2014, 12:27:46 PM
You may find the new cube useful for that. Don't know, but it might..... just wait a little...
Title: Re: Side projection (again?)
Post by: Tangled-Universe on February 17, 2014, 01:13:26 PM
Quote from: j meyer on February 17, 2014, 12:11:05 PM
Reminds me of that
http://www.planetside.co.uk/forums/index.php/topic,16160.msg157567.html#msg157567

Didn't know that one yet, must have missed it somehow (magically). Thanks! :)

It works with this one as well.
Edit: you still need a softer edge though, but not the tiny patch size anymore.

Title: Re: Side projection (again?)
Post by: jaf on February 17, 2014, 03:17:33 PM
Is this an Alpha scene.  Just asking since I was trying to follow this thread and looked at the warning messages I received when I loaded the scene (unknown parameters.)
Title: Re: Side projection (again?)
Post by: Hannes on February 17, 2014, 05:17:47 PM
Thank you, guys! Smoothing and decreasing the patch size did the trick.

Oh, and yes, that was done with the alpha version. Sorry :-[