Fallback for if GL_ARB_clip_control not available
If GL_ARB_clip_control not available then [znear, zfar] -> [1, -1] instead of [1, 0] in normalized device coordinates Thus, Z is still reversed, but not shifted, clipping should still work properly, and conversion to window coordinates does not cause accuracy regression compared to non-reversed Z rendering.
This commit is contained in:
@@ -1489,9 +1489,6 @@ void mjr_makeContext_offSize(const mjModel* m, mjrContext* con, int fontscale,
|
||||
if (!mjGLAD_GL_ARB_vertex_buffer_object) {
|
||||
mju_error("OpenGL ARB_vertex_buffer_object required");
|
||||
}
|
||||
if (!mjGLAD_GL_ARB_clip_control) {
|
||||
mju_error("OpenGL ARB_clip_control required");
|
||||
}
|
||||
if (!mjGLAD_GL_ARB_depth_buffer_float) {
|
||||
mju_error("OpenGL ARB_depth_buffer_float required");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user