First, I’m trying to create shaders for the very first time!
I’m trying to make a shader but the functions from OpenGL are not present? vc2013, so I can not seem to load create attach shader. ( Opengl is working fine right now in the project)
Right now it give me error’s on functions to do a shader:
3>------ Build started: Project: GL_View, Configuration: Debug x64 ------
3> GLShader.cpp
3>GLShader.cpp(40): error C3861: 'glCreateProgram': identifier not found
3>GLShader.cpp(41): error C3861: 'glAttachShader': identifier not found
3>GLShader.cpp(42): error C3861: 'glAttachShader': identifier not found
3>GLShader.cpp(43): error C3861: 'glLinkProgram': identifier not found
========== Build: 2 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
So I used DependencyWalker to look at the opengl Lib my apps are linked to.
( SO it appears this library doesn’t have it??)
Now possible update, but after searching via web, it seems that I have to first check my hardware to see if I can even use a shader.
I have a NVidia GeForce GTX 760 card ( NVidia’s control panel says Driver Version 432.0)
And it seems that you need to download the glewinfo.exe and visualinfo.exe to do a check as well.
-------------------------------Running glewinfo.exe -----------------------------------
and at the top it says:
---------------------------
GLEW Extension Info
---------------------------
GLEW version 2.2.0
Reporting capabilities of pixelformat 1
Running on a GeForce GTX 760/PCIe/SSE2 from NVIDIA Corporation
OpenGL version 4.6.0 NVIDIA 432.00 is supported
Then a ton a functions with OK or missing
It appears that GL_VERSION_4_6 is good up to here.
I did search this list and it doesn’t find: glCreateProgram
and the others…???
----------------------------Running visualinfo.exe---------------
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GTX 760/PCIe/SSE2
OpenGL version string: 4.6.0 NVIDIA 432.00
OpenGL extensions (GL_):
Then a bunch of stuff I'm not sure I understand----
OpenGL extensions (GL_): ( Bunch of functions here)
GLU version string: 1.2.2.0 Microsoft Corporation
GLU extensions (GLU_):
GL_EXT_bgra.
WGL extensions (WGL_):
Then a huge chart
https://www.khronos.org/registry/OpenGL/index_gl.php
- <GL/glext.h> - OpenGL 1.2 and above compatibility profile and extension interfaces.
- <GL/glcorearb.h> - OpenGL core profile and ARB extension interfaces, as described in appendix G.2 of the OpenGL 4.3 Specification. Does not include interfaces found only in the compatibility profile.
- <GL/glxext.h> - GLX 1.3 and above API and GLX extension interfaces.
- <GL/wglext.h> - WGL extension interfaces.
also <KHR/khrplatform.h>
SO finally my questions:
-
Since my system32 x64 has a bad Opengl can I replace that, and where for windows? What about the opengl headers/ lib ?
-
It appears to get those functions I have to include the registry files above after gl.h… glext.h etc? I did but the export ordinal was not there do I need to modify the gl.h file to tell it the correct version of gl(
/* Version */
#define GL_VERSION_1_1 1
)
NOTE: The *.dll of Opengl32.dll
( C:\WIndows\System32 doesn’t have those functions there in there.)
-
I did find others opengl32.
dll in C:\Windows\SysWOW64 but no functions
C:\Windows\WinSys ( I assume these are from other apps I have installed?) -
I have the latest driver for my video card so how do I get the appropriate Opengl lib / dll /headers etc