#calculating normals on diagonal waves

8 messages · Page 1 of 1 (latest)

bitter vigil
#

PICTURE 1: wave with dir = vec2(1.0, 0.0) (working normal values + vertix displacement)

#

PICTURE 2: wave with dir = normalize(vec2(1.0, 0.0)) (working vertex displacement, not working normal values)
(2nd image is top view so you can see the (wrong) normal vector things)

#

instead of matching the diagonal waves, the normal maps make it seem like there are two waves going in perpendicular directions
can someone help me solve this one?
this is the video im basing it off of: https://www.youtube.com/watch?v=PH9q0HNBjT4

Get a free 30 day trial and 20% off an annual plan at
https://brilliant.org/acerola ! #ad

Many Acerola viewers ask the question: How do games render water? Well, real time water rendering might sound intimidating, but it turns out most video games (Final Fantasy XVI, Elden Ring, Genshin Impact, etc.) use a relatively simple technique. How conve...

▶ Play video
zealous mango
#

Why not just use central difference

#

Oh it's meant to be dynamic I see

#

Just take the partial derivatives with respect to x and y, built a tangent vector along each one, and use the cross product

bitter vigil
zealous mango
#

It's the same derivation so it shouldn't if done correctly