mirror of https://github.com/PCSX2/pcsx2.git
gsdx ogl: move the validation of the gl context in the window
This commit is contained in:
parent
b3836c58d2
commit
714fcaaadd
|
@ -54,7 +54,6 @@ FILE* GSDeviceOGL::m_debug_gl_file = NULL;
|
|||
GSDeviceOGL::GSDeviceOGL()
|
||||
: m_msaa(0)
|
||||
, m_force_texture_clear(0)
|
||||
, m_window(NULL)
|
||||
, m_fbo(0)
|
||||
, m_fbo_read(0)
|
||||
, m_va(NULL)
|
||||
|
@ -289,14 +288,6 @@ GSTexture* GSDeviceOGL::FetchSurface(int type, int w, int h, bool msaa, int form
|
|||
|
||||
bool GSDeviceOGL::Create(GSWnd* wnd)
|
||||
{
|
||||
if (m_window == NULL) {
|
||||
if (!GLLoader::check_gl_version(3, 3)) return false;
|
||||
|
||||
if (!GLLoader::check_gl_supported_extension()) return false;
|
||||
}
|
||||
|
||||
m_window = wnd;
|
||||
|
||||
// ****************************************************************
|
||||
// Debug helper
|
||||
// ****************************************************************
|
||||
|
|
|
@ -418,8 +418,6 @@ public:
|
|||
|
||||
bool m_disable_hw_gl_draw;
|
||||
|
||||
GSWnd* m_window;
|
||||
|
||||
GLuint m_fbo; // frame buffer container
|
||||
GLuint m_fbo_read; // frame buffer container only for reading
|
||||
|
||||
|
|
|
@ -178,4 +178,12 @@ void GSWndGL::PopulateGlFunction()
|
|||
GL_EXT_LOAD(glGenProgramPipelines);
|
||||
GL_EXT_LOAD(glGenerateMipmap);
|
||||
#endif
|
||||
|
||||
// Check openGL requirement as soon as possible so we can switch to another
|
||||
// renderer/device
|
||||
if (!GLLoader::check_gl_version(3, 3))
|
||||
throw GSDXRecoverableError();
|
||||
|
||||
if (!GLLoader::check_gl_supported_extension())
|
||||
throw GSDXRecoverableError();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue