Planetside Software Forums

General => Terragen Discussion => Topic started by: Dune on August 04, 2017, 10:10:29 AM

Title: reflective highlights under water
Post by: Dune on August 04, 2017, 10:10:29 AM
If you look down on water, could there be any of these under the water surface? I always use a minimum altitude (water level) for reflections on river banks to avoid the pinpricks of light on stones in deep water, as I think they shouldn't be there. With sloping rivers altitude can't be used, so I have a problem. In fact, perhaps it would be good to have (a switch in) the water shader blocking any highlights....
What do you guys (and girls) think?
Title: Re: reflective highlights under water
Post by: mhaze on August 04, 2017, 12:01:32 PM
Agreed!
Title: Re: reflective highlights under water
Post by: Tangled-Universe on August 04, 2017, 01:54:36 PM
Reflective highlights don't exist underwater, as highlights are an interaction between 2 media with different refraction indices.
An automatic function would be nice, but it's technically actually quite difficult to mask these exactly from a mathematical pov, because of this refractive index physics (meniscus effect etc.).
Matt could perhaps make this semi-automatic by having a setting where the user can specify how many (centi)meters above the waterline specular highlights can exist.
Title: Re: reflective highlights under water
Post by: Dune on August 05, 2017, 02:17:04 AM
Right, that's what I thought. I can also understand why it's difficult to include in a water shader, because it needs to read the distance between water level and ground level; water levels are not always virtually level (like in streams downhill). Come to think of it, that might be possible with a workaround with some blue nodes.... something to ponder over.
And highlights are nothing but concentrated light pixel areas, so how would you filter those out again after they've been calculated? Pretty hard I guess. Better to filter them out before they're being calculated.
Title: Re: reflective highlights under water
Post by: René on August 05, 2017, 05:11:29 AM
The only thing I can think of is using a mask to mask out the shiny stones below water level, and use another stones shader to replace them. Maybe you can create a mask from a top-down render of the rivers.