I am working on a water shader, using nodes to displace the waves of an ocean. Here is the simplified version using a checker texture to visualize my problem.
Since I want to make a cross section of the ocean ( waves on top, and a smooth glass shader on the sides to see the inside ) I need the top of the plane of the cube to displace on the z axis only, while the sides adjust their height accordingly to touch the top plane. Is it possible, and how if it is, to stop X and Y from going outwards?
My Blender version is 2.83