must check gl extensions first
This commit is contained in:
parent
69ffcae6ff
commit
49b7ac2fac
|
|
@ -263,6 +263,27 @@ reset() {
|
|||
free_pointers();
|
||||
GraphicsStateGuardian::reset();
|
||||
|
||||
// Output the vendor and version strings.
|
||||
show_gl_string("GL_VENDOR", GL_VENDOR);
|
||||
show_gl_string("GL_RENDERER", GL_RENDERER);
|
||||
get_gl_version();
|
||||
|
||||
// Save the extensions tokens.
|
||||
save_extensions((const char *)glGetString(GL_EXTENSIONS));
|
||||
get_extra_extensions();
|
||||
report_extensions();
|
||||
|
||||
_supports_bgr = has_extension("GL_EXT_bgra");
|
||||
_supports_multisample = has_extension("GL_ARB_multisample");
|
||||
|
||||
_edge_clamp = GL_CLAMP;
|
||||
if (has_extension("GL_SGIS_texture_edge_clamp") ||
|
||||
is_at_least_version(1, 2)) {
|
||||
_edge_clamp = GL_CLAMP_TO_EDGE;
|
||||
}
|
||||
|
||||
report_my_gl_errors();
|
||||
|
||||
_buffer_mask = 0;
|
||||
|
||||
// All GL implementations have the following buffers. (?)
|
||||
|
|
@ -418,25 +439,6 @@ reset() {
|
|||
}
|
||||
}
|
||||
|
||||
// Output the vendor and version strings.
|
||||
show_gl_string("GL_VENDOR", GL_VENDOR);
|
||||
show_gl_string("GL_RENDERER", GL_RENDERER);
|
||||
get_gl_version();
|
||||
|
||||
// Save the extensions tokens.
|
||||
save_extensions((const char *)glGetString(GL_EXTENSIONS));
|
||||
get_extra_extensions();
|
||||
report_extensions();
|
||||
|
||||
_supports_bgr = has_extension("GL_EXT_bgra");
|
||||
_supports_multisample = has_extension("GL_ARB_multisample");
|
||||
|
||||
_edge_clamp = GL_CLAMP;
|
||||
if (has_extension("GL_SGIS_texture_edge_clamp") ||
|
||||
is_at_least_version(1, 2)) {
|
||||
_edge_clamp = GL_CLAMP_TO_EDGE;
|
||||
}
|
||||
|
||||
_error_count = 0;
|
||||
|
||||
report_my_gl_errors();
|
||||
|
|
|
|||
Loading…
Reference in New Issue