- #1
dilloncyh
- 39
- 0
Suppose I have already found the surface normal vectors to a set of points (x,y), how do I compute the surface height z(x,y)?
Basically what I have are the normal vectors at each point (x,y) on a square grid. Then I calculate the vectors u = (x+1,y,z(x+1,y)) - (x,y,z(x,y)) and v = (x,y+1,z(x,y+1)) - (x,y,z(x,y)), and use the facts that u and v are both orthogonal to the the normal vector at (x,y) to obtain a system of linear-equations which can be solved by using standard linear algebra. The problem is that since there are many points on the grid (the number of pixel on a 200x300 image), this system of equations is very very large, and the computational time is very slow. So I wonder if there are other methods to compute the surface height z(x,y) from the given set of normal vectors.
thanks
Basically what I have are the normal vectors at each point (x,y) on a square grid. Then I calculate the vectors u = (x+1,y,z(x+1,y)) - (x,y,z(x,y)) and v = (x,y+1,z(x,y+1)) - (x,y,z(x,y)), and use the facts that u and v are both orthogonal to the the normal vector at (x,y) to obtain a system of linear-equations which can be solved by using standard linear algebra. The problem is that since there are many points on the grid (the number of pixel on a 200x300 image), this system of equations is very very large, and the computational time is very slow. So I wonder if there are other methods to compute the surface height z(x,y) from the given set of normal vectors.
thanks