I think the equation should be top = near*tan(fovy/2) since the fovy goes above and below as an angle, while fovy/2 is the actual angle of the right triangle with near as an adjacent side.
I think the equation should be top = near*tan(fovy/2) since the fovy goes above and below as an angle, while fovy/2 is the actual angle of the right triangle with near as an adjacent side.