OpenGL context recreation with GLFW

I'm currently thinking about handling the OpenGL context recreation.

But for now there is some bugs. Some of my objects fails to be reloaded and sometimes the engine simply crash.

I use GLFW library for OpenGL context creation and GL3W for the extensions loader.

My question is quite simple: should I consider to call gl3wInit() again when I'm rebuilding the context ?

Upvotes: 0

Views: 76

Answers (1)

HolyBlackCat
HolyBlackCat

Reputation: 96924

Yes, you might need to call it again.

I heard that at least on Windows, GL function pointers could be context-specific. If you make a new context, you need to obtain new function pointers (which is what gl3wInit() does).

Upvotes: 1

Related Questions