Page 1 of 1
Terrain blending and dlights
Posted: Fri Sep 17, 2010 9:26 pm
by neoplan
I was following socks tutorial about Terrain-Blending and ran into problems with dlights. In the last section of the tutorial, a third shader is used as a decal to get an even more realistic blend. Everything works fine but when the action finally begins, it looks like that:
[lvlshot]http://www.mypicx.com/uploadimg/519973398_09172010_1.jpg[/lvlshot]
Does somebody know why parts of the terrain are not affected by the rockets light?
Re: Terrain blending and dlights
Posted: Fri Sep 17, 2010 10:05 pm
by Delirium
do any of the shaders have surfaceparm nodlight in them? if not then add it in and it will remove dlights. but if they do then remove surfaceparm nodlight
Re: Terrain blending and dlights
Posted: Sun Sep 19, 2010 12:29 pm
by corsair
I think it may have to do with the amount of shader passes (or layers) on the specific area; you have the texture of this area, two of the adjacent areas' textures, and a decal map processing the appearance of the darker surface. This is already the maximum, so the lighting pass which you after, cannot be added.
If I'm not mistaken, then another row of polygons should be added so to distribute the blending of the three textures: every polygon should have only two textures (and decal) applied.
Re: Terrain blending and dlights
Posted: Sun Sep 19, 2010 9:23 pm
by neoplan
@Delirium: Nope, there is no surfaceparm nodlight. (does it even make sense to apply this here - it would result in no dlights at all - i dont want that)
Socks shader:
http://www.simonoc.com/pages/articles/terrain2_5.htm
@corsair: How to I get there? I don't exactly understand how you would do another row of polygons.
What's the matter of an additional decal if it totally fucks up the appearance?
Re: Terrain blending and dlights
Posted: Sun Sep 19, 2010 10:17 pm
by corsair
http://img801.imageshack.us/img801/2199/57650897.jpg
Green section blends with blue
Blue section blends with green, AND red (!)
Red section blends with blue
^^ your situation
http://img17.imageshack.us/img17/3144/53897208.jpg
Green section blends with blue
blue section1 blends with green
blue section2 blends with red
red section blends with blue section
^^ adding more brushes like this will keep areas from having to merge 3 textures.
I haven't setup a terrain per sock's example myself, but as far as the decal texture goes, I think it is intended for masking details; for instance to keep objects such as stones and pebbles sharp (and 100% opaque) when they blend with a grass or sand texture. (you dont want area's showing 50% rock and 50% grass on top of eachother, as its unnatural)
Re: Terrain blending and dlights
Posted: Tue Sep 21, 2010 4:09 am
by wattro
corsair, i have never been more turned on by mspaint than i am after seeing your .jpgs