From: Steinar H. Gunderson Date: Sun, 23 Mar 2014 11:41:46 +0000 (+0100) Subject: Merge branch 'epoxy' of ssh://pannekake.samfundet.no/srv/git.sesse.net/www/movit... X-Git-Tag: 1.1~12^2~2 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=34036d849937f22c0addfcba44f65207c96deddc;hp=-c;p=movit Merge branch 'epoxy' of ssh://pannekake.samfundet.no/srv/git.sesse.net/www/movit into epoxy --- 34036d849937f22c0addfcba44f65207c96deddc diff --combined init.cpp index 4b8c970,b4e69b0..c37614e --- a/init.cpp +++ b/init.cpp @@@ -283,10 -283,13 +283,10 @@@ bool check_extensions( // GLES generally doesn't use extensions as actively as desktop OpenGL. // For now, we say that for GLES, we require GLES 3, which has everything // we need. - // - // Since we use implicit #version 100, we don't have round(). We will - // fix this at some later stage. if (!epoxy_is_desktop_gl()) { if (epoxy_gl_version() >= 30) { movit_srgb_textures_supported = true; - movit_shader_rounding_supported = false; + movit_shader_rounding_supported = true; } else { return false; } @@@ -359,6 -362,17 +359,17 @@@ double get_glsl_version( return glsl_version; } + void APIENTRY debug_callback(GLenum source, + GLenum type, + GLuint id, + GLenum severity, + GLsizei length, + const char *message, + const void *userParam) + { + printf("Debug: %s\n", message); + } + } // namespace bool init_movit(const string& data_directory, MovitDebugLevel debug_level) @@@ -375,6 -389,12 +386,12 @@@ glPixelStorei(GL_UNPACK_ALIGNMENT, 1); glDisable(GL_DITHER); + // You can turn this on if you want detailed debug messages from the driver. + // You should probably also ask for a debug context (see gtest_sdl_main.cpp), + // or you might not get much data back. + // glDebugMessageCallbackARB(callback, NULL); + // glDebugMessageControlARB(GL_DONT_CARE, GL_DONT_CARE, GL_DONT_CARE, 0, 0, GL_TRUE); + if (!check_extensions()) { return false; }