Displacements and Shader Detail Problem

Kerch

L1: Registered
Mar 10, 2011
20
21
I am having trouble with the lighting of my displacements.

With shader detail set to low, it looks as it should:

YLfGX.jpg


With shader detail set to high, there is a nasty seam between the two displacements:

X2ikd.jpg


Edit: Below is the first semi-successful attempt at a fix.

This is with shader detail high and one of the bump maps removed from the rock wall:

jkZrc.jpg
 
Last edited:

Blade x64

Logical insanity
aa
Sep 3, 2009
239
633
From what I can tell, for some reason blendrockgroundwallforest uses an SSbump for the grass bump map, even though the rock has a normal bump map and ssbump is not set to 1. To fix this, either remove the bump map assigned to the grass on the cliff or replace it with a more suitable bump map.
 

Kerch

L1: Registered
Mar 10, 2011
20
21
That sounds like a good explanation.

The theme isn't set in stone, so it might be easier for a novice like me to try a different texture combination.

I'm a bit confused though because in my decompiled version of Gorge they use the same texture combination but don't get this effect.
 

Kerch

L1: Registered
Mar 10, 2011
20
21
I've added a third image showing what happens when you remove the second bump map from "blendrockgroundwallforest" as follows:

Code:
"WorldVertexTransition"
{
	"$basetexture" "Nature/rockwall001forest"
	"$basetexture2" "Nature/grass_07"
	"%tooltexture" "editor-abs/blendttx/nature/blendrockgroundwallforest_ttx"
	"$blendmodulatetexture" "Nature/grass_blendmask"
	"$bumpmap" "Nature/rockwall001_normal"
	\\"$bumpmap2" "Nature/rockground002_height-ssbump"
	"%keywords" "tf"
	"$surfaceprop" "dirt"

}

The bump map in question seems to put a very strong highlight around the top of the rock texture so this is what gives that contrast with the grass.
 

Blade x64

Logical insanity
aa
Sep 3, 2009
239
633
The rock bump map is being applied to both textures, so just give the grass a neutral bump map. I tried to find out what special thing cp_gorge did as well, but couldn't find anything.
 

Rexy

The Kwisatz Haderach
aa
Dec 22, 2008
1,798
2,533
The answer is (I know from experience):

SSBumps change the brightness of a of a texture regardless of what the diffuse looks like. If you try to blend two textures together, and one is using an ssbump and another isn't (or 2 ssbumps with different grey brightness levels) you're going to have this brightness/darkness issue.

Open up "Nature/rockground002_height-ssbump" in your favorite .vtf editor and you will see that's a flat grey texture, meant for blending displacement textures together in the case that one of the two blend textures uses a detailed ssbump. This is the standard file valve uses when they want to do exactly this.

http://dl.dropbox.com/u/1293763/rockground002_height-ssbump.jpg

Take a look above at that.

If you need further matching of brightness between the two blends, use "$color2", and then offset the three rgb values from 255, to 225, then to 200 (until bright/dark line between them changes).