How to hide invisible elements of the 3d drawing?
问题 I'm trying to draw a 3d image that displays a ripple: function myFunc(x, y) { let zRipple = Math.pow(2, -0.005 * (Math.abs(x) + Math.abs(y))) * Math.cos(((x * x + y * y) * 2 * pi) / 180 / width) * height; return zRipple; } width and height here are constants that define a drawing area and are equal to 200 in my tests. My approach is based on what I recall from an article that I read 30 years ago and trying to recall now. The idea is to: split the whole drawing board into the 10-pixel grid for