We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GAMES101-HW/hw1/main.cpp
Line 51: float top = -tan(DEG2RAD(eye_fov/2.0f) * abs(zNear)); ①这里的括号可能是手误? 应该为tan(DEG2RAD(eye_fov/2.0f)) * abs(zNear);
Line 56: 0,0,(zNear+zFar)/(zNear-zFar),(2zNearzFar)/(zFar-zNear), ②4x4矩阵的第三行第四列,漏掉一个负号?refer to http://www.songho.ca/opengl/gl_projectionmatrix.html
The text was updated successfully, but these errors were encountered:
GAMES101-HW/hw1/main.cpp Line 51: float top = -tan(DEG2RAD(eye_fov/2.0f) * abs(zNear)); ①这里的括号可能是手误? 应该为tan(DEG2RAD(eye_fov/2.0f)) * abs(zNear); Line 56: 0,0,(zNear+zFar)/(zNear-zFar),(2_zNear_zFar)/(zFar-zNear), ②4x4矩阵的第三行第四列,漏掉一个负号?refer to http://www.songho.ca/opengl/gl_projectionmatrix.html
Line 56: 0,0,(zNear+zFar)/(zNear-zFar),(2_zNear_zFar)/(zFar-zNear), ②4x4矩阵的第三行第四列,漏掉一个负号?refer to http://www.songho.ca/opengl/gl_projectionmatrix.html
@NoSW 第一个问题,感觉确实是写错了; 第二个问题,其实是把负号放到分母上了。
(-zNear * zFar) / (zNear - zFar) = (zNear * zFar) / (zFar - zNear)
Sorry, something went wrong.
@NoSW 第一个应该是 float top = -tan(DEG2RAD(eye_fov/2.0f) * zNear;这样的话出来的三角形也是正的
No branches or pull requests
GAMES101-HW/hw1/main.cpp
Line 51: float top = -tan(DEG2RAD(eye_fov/2.0f) * abs(zNear));
①这里的括号可能是手误? 应该为tan(DEG2RAD(eye_fov/2.0f)) * abs(zNear);
Line 56: 0,0,(zNear+zFar)/(zNear-zFar),(2zNearzFar)/(zFar-zNear),
②4x4矩阵的第三行第四列,漏掉一个负号?refer to http://www.songho.ca/opengl/gl_projectionmatrix.html
The text was updated successfully, but these errors were encountered: