C++ OpenGL shading version error - GLSL x is not supported [Ubuntu 16.04] -


i working on project using opengl on ubuntu 16.04 , have run major issue. @ point have no idea feels have tried in order fix this.

for reason shader won't compile , returns following error:

failed compile vertex shader! 0:1(10): error: glsl 4.50 not supported. supported versions are: 1.10, 1.20, 1.30, 1.00 es, 3.00 es, 3.10 es, , 3.20 es` 

i have adjusted version in shader file without luck. #version 450 core etc. keep getting same result.

for reference, here output of sudo glxinfo | grep "opengl":

opengl vendor string: intel open source technology center opengl renderer string: mesa dri intel(r) hd graphics 520 (skylake gt2) opengl core profile version string: 4.5 (core profile) mesa 13.1.0-devel opengl core profile shading language version string: 4.50 opengl core profile context flags: (none) opengl core profile profile mask: core profile opengl core profile extensions: opengl version string: 3.0 mesa 13.1.0-devel opengl shading language version string: 1.30 opengl context flags: (none) opengl extensions: opengl es profile version string: opengl es 3.2 mesa 13.1.0-devel opengl es profile shading language version string: opengl es glsl es 3.20 opengl es profile extensions: 

the output glxinfo shows opengl core 4.5 installed, why not supported?

i have tried find current version of opengl used in project: std::cout << "opengl version: " << glgetstring(gl_version) << std::endl; results in blank return.

i have spent 10 hours on single issue until now, appreciated!

edit: there way force project/ubuntu use opengl , not glsl i.e. removing glsl (this part)?

opengl es profile version string: opengl es 3.2 mesa 13.1.0-devel opengl es profile shading language version string: opengl es glsl es 3.20 opengl es profile extensions: 

for else experiencing same issues, solution worked me:

glfwwindowhint(glfw_context_version_major, 4); glfwwindowhint(glfw_context_version_minor, 0); glfwwindowhint(glfw_opengl_profile, glfw_opengl_core_profile); 

Comments

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -