crest icon indicating copy to clipboard operation
crest copied to clipboard

Add property to control normal map scrolling speed

Open ftejada17 opened this issue 5 years ago • 3 comments

I am using the latest Crest HDRP update from a few days ago. I have another question. Where does that normal map movement come from in the video come from? In the configuration that I show there were no waves in the water, only the normal map. Can you change that movement pattern to make it faster, slower or even stop it without having to set the Normals Strench parameter or 0?

Hub answered this on Discord: https://discord.com/channels/559866092546424832/577081395718127646/714113544295022684

Supporting images/mockups, or example reference videos are very helpful to communicate ideas. https://youtu.be/byi7G2PXrxk

ftejada17 avatar May 24 '20 14:05 ftejada17

Hi @ftejada17 , what are you looking to do?

The water would look very unnatural if the normals were frozen. I guess they could be slowed down. Do we want to add a material control for this? Alternatively we could point you to constants which you could change locally to experiment, if you are just looking to test different values.

We could expose it, it probably wont add significant cost, but every little bit counts and it would be good to make sure it needs to be exposed.

huwb avatar Jun 07 '20 12:06 huwb

Hi @huwb !! I understand ... Actually stopping that movement at 0 usually doesn't make much sense (although you can always get some playable mechanics out of it), but it does have a slider to lower or increase the scrolling speed. Another very important thing that I think would help solve the problem is having a third pass from Normal in a different direction than the 2 passes that the shader seems to have now. And have an exposed control (through a Vector3 / float3), of direction for each pass of normals, to be able to change the direction of movement of the normal in each pass. With this, these directions could be changed in real time constantly and produce a more natural and less repetitive effect.

I don't know if I'm explaining myself. If you don't understand what I mean, tell me.

The thing is, if you remove the OceanWavesSpectrum from the equation and just leave "the waves that normal ones produce," the motion they have looks very unnatural and repetitive. And for calm waters where you need to have very few waves created by the OceanWavesSpectrum or none like calm tropical waters, this shows a lot and is more of a problem than a good feature. But you also can't set the normal strength in the Crest shader to 0 because everything would be very bad

Would another pass more than normal in a third direction different from the two that already exist have much impact on performance?

Cheers

ftejada17 avatar Jun 13 '20 11:06 ftejada17

Taken from other issue:

the second interpretation which i think is referred to in 519 is connecting the normal maps to the spectrum values, it would be cool if the strength of the normal maps were connected to the spectrum values, so that when you turn down the spectrum the normal maps also go away. i guess they could be keyed off whatever spectrum values are below the current lowest LOD scale (i.e. if the current lods have waves down to 1m wavelength, the normal maps are keyed off the 0.5m wavelength spectrum slider?). it could be interesting to experiment with this to see if it works or not. what are your thoughts?

Sounds interesting. Would like to give this a go. This would also contribute towards the Beaufort Scale.

magenta404 avatar Jun 14 '20 09:06 magenta404