RTP - Relief Terrain Pack with geometry blend on AssetStore

Released:
http://u3d.as/content/tomasz-stobierski/rtp-relief-terrain-pack

Please, take a look at documentation here for detailed description:
http://www.stobierski.pl/unity/RTP.pdf

Pre-release discussion here:
http://forum.unity3d.com/threads/152531-New-relief-mapping-techniques-%28fast%29/page2

Main features:

  • AAA look of terrain at great framerates
  • 8 POM textures with self shadowing in 1 pass
  • Hard, well defined blending between detail maps
  • Global normal / color maps
  • Built in geometry blend toolset for seamless merge terrain with your geometry
  • Adjustable via fallbacks for wide range of GPUs
  • Can be used on arbitrary mesh
  • Requires GPU with SM3.0. Does not require Unity PRO (only example scene has water).

EDIT - I’d like to update to version 1.0a with fot fixes for problematic cases. Please refer to the newest web player and check if fixes work.

I had to disable antialias postFX everywhere because it seems that this is what crashes some machines (and most probably has nothing to do with my shaders).

Version 1.0b update available → openGL hotfixes
Version 1.0c update available → openGL hotfixes, lightmapping issues
Version 2.0 update available:

  • Dynamic snow
  • 1-12 layers (4 layers or 8 layers in FirstPass now available)
  • New UI that makes your life easier
  • Terrain compositioning right inside inspector
  • Triplanar texturing (in 4 layers per pass mode)
  • Vertical map (global) texturing
  • Improved lightmapping (recovers bumpMapping in signle mode)
  • Geometry blend works for terrains AND arbitrary meshes (objects vs. Mesh terrains works now)
  • U4 DX11 compatible

Version 2.1 update available:
Substance to terrain layer texture export has been introduced and a few additional bugs detected&fixed. In Unity 4.1 substance textures export works in both Indie and Pro. In lower Unity versions user need to have Pro license to get the feature working.

RTP 2 features tour available here (with lots of screenshots)


Latest working demos

Below we’ve got whole set of WebPlayers with different set of features used. They can be easily adjusted via dedicated RTP_LODmanager script. This way you can use features you think are important for your project taking into account performance of end-user machine:

All effects turned on, 8 layers in one pass >>> webplayer

Like above, but with simple snow and superdetail turned off >>> webplayer

Still 8 layers per pass - simpliest version >>> webplayer

8 layers like above (simpliest set of features), but splited into two passes. You can judge what’s faster on your machine >>> webplayer

8 triplanar layers (4 in first-pass, 4 in add-pass). Note that triplanar disable parallax effects >>> webplayer

4 layers triplanar with vertical texturing. Good for geologicaly advanced scenes :slight_smile: >>> webplayer

Like above, but w/o triplanar, so we’ve got parallax effects (POM/PM shading working) >>> webplayer

4 layers - the most simple version. Only global colorMap normalMap used (can’t be turned off anyway), but we still got parallax effects and height blending adjustable realtime.
This could be version for low-mid range GPUs (better mobile could handle this I guess)>>> webplayer

Standalone - 8 layers with simple snow, PC version>>> zip file
Standalone - 8 layers with simple snow, Mac version>>> zip file

Standalone - 4 layers simpliest, PC version>>> zip file
Standalone - 4 layers simpliest, Mac version>>> zip file

I build it under Unity4, so PC versions should be able to get into DX11 mode (with better performance than DX9 I believe)

Is the shader: http://forum.unity3d.com/threads/160817-hi-poly-2-lo-poly-realtime-reconstruction included in this package?

looks great!

lars

It’s part of the other, twin product RSP (Relief Shaders Pack). I’m just about submitting it. Both constitutes the full horsepower of modern (quick) POM shading.

and runs pretty fast!

lars

Unfortunately, that webplayer locked up my lowly little MacBook Pro (Core Duo 2 with x1600 graphics) running latest version of Chrome. The system was completely frozen, had to force power down to restart. Never seen that in a webplayer before.:frowning: Just curious, which version of Unity are you using, 4.0?

It’s looking really weird, very detailed but (maybe it’s the too high detail?) it ends up looking weird when moving and looking far away (as if each pixel was changing color wildly each step), not sure how to describe this.

I’m on a MacBook Pro as well (Intel HD Graphics 3000). No crashes, but I see strange black streaks along the edges of polygons in the scene from some angles / LODs.

It’s done in Unity3.5.6 and the same time Unity4 ready (to handle multiple terrain per scene). I also experience lags and freezes from time to time in forced openGL mode on my PC. I don’t know what’s the issue, but will try to figure it out (maybe GLSL shaders are so complex that runtime compiler in openGL choke, only speculating now).

PC, Mac, conf please. If it’s only possible, please attach screenshot. I’d like to have any idea what’s going wrong.

Screenshot please :slight_smile:

EDIT - tweaked something - please check again webplayer if streaks are still here.

Can’t wait to use this, now I just need to test upgrading my project to Unity 4.
One question: What’s the technical limitation that prevents 3.5 from handling more than one terrain?

Thanks tomas

In 3.5 we can’t provide terrain with additional parameters (textures, etc.). What we can do is using Shader.SetGlobal…() functions that set variables for all shaders in the scene. As different terrains need different params, we can’t do it in U3. In U4 we’ve got access (Terrain.textureTemplate - no docs but this is it) to material associated to terrain. This way we can inject params into specific material for specific terrain w/o necessity to use globals.

Meantime I’m working on compatibility issues with some openGL machines (no problems with PC machines). As you see some “black PR” above discourages people I guess :/.

PC, unity 4, nvidia 540M GT, windows 8X64 attaching a screenshot won’t help as any screenshot looks fine, it only looks weird “in motion”, will try to video capture it if you want but i’m not sure i can get the quality of the video high enough to see this, but it “does” look really weird so hope i can.

Hi,
is this straight line normal ?
Thanks

Normal :slight_smile: I just didn’t have time to uv map the “cube rock” model in the example without seams.

The good news is I think you fixed my issue with the black streaks.

The bad news is I got the total machine lockup the bigkahuna saw.

Here’s what I ended up with in the console. Looks pretty unhelpful, except perhaps the 0x0 image thing, but maybe it will mean something to you:

12/7/12 10:07:56.559 AM PluginProcess: CGImageCreateWithImageProvider: invalid image size: 0 x 0.
12/7/12 10:07:56.559 AM [0x0-0xea9ea9].com.apple.Safari: Dec 7 10:07:56 Garden-of-Pure-Ideology.local PluginProcess[42917] : CGImageCreateWithImageProvider: invalid image size: 0 x 0.
12/7/12 10:09:54.000 AM kernel: stampWait: Overflowed checking for stamp 0x168294b0 on MAIN ring: called from
12/7/12 10:09:54.000 AM kernel: timestamp = 0x168294ab
12/7/12 10:09:54.000 AM kernel: **** Debug info for possible hang in MAIN graphics engine ****
12/7/12 10:09:54.000 AM kernel: ring head = 0xc4a00cbc, wrap count = 1573
12/7/12 10:09:54.000 AM kernel: ring tail = 0x00000f30
12/7/12 10:09:54.000 AM kernel: ring control = 0x0000f001 enabled, auto report disabled, not waiting, semaphore not waiting, length = 0x010 4KB pages
12/7/12 10:09:54.000 AM kernel: timestamps = 0x168294ab
12/7/12 10:09:54.000 AM kernel: Semaphore register values:
12/7/12 10:09:54.000 AM kernel: VRSYNC: (0x12044) = 0x168294ab
12/7/12 10:09:54.000 AM kernel: BRSYNC: (0x22040) = 0x0
12/7/12 10:09:54.000 AM kernel: RVSYNC: (0x 2040) = 0x0
12/7/12 10:09:54.000 AM kernel: BVSYNC: (0x22044) = 0x0
12/7/12 10:09:54.000 AM kernel: RBSYNC: (0x 2044) = 0x0
12/7/12 10:09:54.000 AM kernel: VBSYNC: (0x12040) = 0x0

This could mean something to Unity core programming staff :).

However what crashed my laptop (Win7 buit-in HD3000) in openGL mode was antialias postFX… I had to disable it. It’s too problematic on many machines and most probably has nothing to do with my shaders. I believe that was bigkahuna problem, and yours.

Z-fighting problem (“streaks” - I assume it was this particular issue for some Mac users) has been detected I believe. Shadow collector passes + terrain multipass shading or rendertexture shading causes such problems on openGL (esp. in deferred). I believe now it should work. Please check the latest webplayer (the same link as previous).

Unfortunately I can’t refer to Ronan’s problem on Win8. (DX drivers, or … ?). Anyway on any PC I’ve tested it (laptop Win7, built in HD3000 or GT 540M, desktop Win XP GT240, desktop Win XP HD 4650) I had no issues.

Tom

Hi. I’ve added this to my Unity wallet, but didn’t buy yet because I still see artifacts on shader.
Terrain, artifacts no more, but on props like those rocks and bridge things are still pretty ugly, is this UV mapping issue?

Mac OGL.

No crash but the streaks are back.

Heh, BrUnO XaVIeR beat me to it.