So, I was rewatching a couple handmade heroes episodes, and a something that I would like to understand more popped up when a viewer asked a question about linking to opengl32.lib.
Here's the video I'm talking about:
https://www.youtube.com/watch?v=5Klc9RZPG7M
The question is 1h08m into the video.
Casey explains to him that the only reason he calls GetProcAddress is because he would like to know if it fails.
This made me think, does it mean that I could just provide the function signature/prototype for a function I know GetProcAddress will return true, and use it directly instead of calling GetProcAddress?
So, I tried doing that and it didn't work, it left me with tons of unresolved symbols even though I was linking to the same libraries as when I was calling wglGetProcAddress(). What is different here?
Why must I get the function pointers via wglGetProcAddress()?