graphics: specify all necessary OpenGL ES libraries by default

This commit is contained in:
Simon Fels 2018-05-15 08:32:31 +02:00
commit 8b6ced19fe
4 changed files with 5 additions and 5 deletions

View file

@ -129,7 +129,7 @@ class SystemInformation {
}
void collect_graphics_info() {
auto gl_libs = anbox::graphics::emugl::default_gl_libraries(true);
auto gl_libs = anbox::graphics::emugl::default_gl_libraries();
if (!anbox::graphics::emugl::initialize(gl_libs, nullptr, nullptr)) {
return;
}

View file

@ -37,13 +37,13 @@ constexpr const char *default_glesv2_lib{"libGLESv2.so.2"};
namespace anbox {
namespace graphics {
namespace emugl {
std::vector<GLLibrary> default_gl_libraries(bool no_glesv1) {
std::vector<GLLibrary> default_gl_libraries() {
return std::vector<GLLibrary>{
{GLLibrary::Type::EGL, default_egl_lib},
// If environment doesn't provide a GLESv1 .so file we use the GLESv2
// implementation instead. If our stack allows it we can try to get
// rid of GLESv1 completely at a later point.
{GLLibrary::Type::GLESv1, no_glesv1 ? default_glesv2_lib : default_glesv1_lib},
{GLLibrary::Type::GLESv1, default_glesv1_lib},
{GLLibrary::Type::GLESv2, default_glesv2_lib},
};
}

View file

@ -37,7 +37,7 @@ struct GLLibrary {
boost::filesystem::path path;
};
std::vector<GLLibrary> default_gl_libraries(bool no_glesv1 = false);
std::vector<GLLibrary> default_gl_libraries();
bool initialize(const std::vector<GLLibrary> &libs, emugl_logger_struct *log_funcs, logger_t crash_func);
} // namespace emugl

View file

@ -76,7 +76,7 @@ GLRendererServer::GLRendererServer(const Config &config, const std::shared_ptr<w
composer_ = std::make_shared<LayerComposer>(renderer_, composer_strategy);
auto gl_libs = emugl::default_gl_libraries(true);
auto gl_libs = emugl::default_gl_libraries();
emugl_logger_struct log_funcs;
log_funcs.coarse = logger_write;