emulator: opengl: add initLibrary function to render library
This adds an initLibrary() function to libOpenglRender. It will be used by the emulator to fallback on software rendering if the library cannot be initialized properly, e.g. if it is not possible to load the host EGL/GLES libraries. Change-Id: I41e8ad73a315166e4a15cbee1db72c2552370f46
This commit is contained in:
@@ -107,24 +107,6 @@ bool FrameBuffer::initialize(int width, int height)
|
||||
return true;
|
||||
}
|
||||
|
||||
//
|
||||
// Load EGL Plugin
|
||||
//
|
||||
if (!init_egl_dispatch()) {
|
||||
// Failed to load EGL
|
||||
printf("Failed to init_egl_dispatch\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
//
|
||||
// Load GLES Plugin
|
||||
//
|
||||
if (!init_gl_dispatch()) {
|
||||
// Failed to load GLES
|
||||
ERR("Failed to init_gl_dispatch\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
//
|
||||
// allocate space for the FrameBuffer object
|
||||
//
|
||||
@@ -142,7 +124,7 @@ bool FrameBuffer::initialize(int width, int height)
|
||||
fb->m_caps.hasGL2 = false;
|
||||
}
|
||||
else {
|
||||
fb->m_caps.hasGL2 = init_gl2_dispatch();
|
||||
fb->m_caps.hasGL2 = s_gl2_enabled;
|
||||
}
|
||||
#else
|
||||
fb->m_caps.hasGL2 = false;
|
||||
|
||||
Reference in New Issue
Block a user