summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-10-11 14:11:12 +0200
committerwm4 <wm4@nowhere>2015-10-11 14:11:12 +0200
commitb7ba2e2c578f9b7085adfc50d8db4b84183e8f2b (patch)
tree6a1278195723faf6c69061a21adac8e37d9f7fbc /video
parent52de5ea6addb62a89a79689397b055ba8fab1795 (diff)
downloadmpv-b7ba2e2c578f9b7085adfc50d8db4b84183e8f2b.tar.bz2
mpv-b7ba2e2c578f9b7085adfc50d8db4b84183e8f2b.tar.xz
DOCS/client_api_examples/qt_opengl: fix uninit
mpv_opengl_cb_uninit_gl() still needs the OpenGL context. It makes calls to free OpenGL objects. Strictly speaking, this is probably unnecessary, because the OpenGL context is destroyed afterwards (implicitly freeing all related objects). But mpv_opengl_cb_uninit_gl() does not require the destruction of the OpenGL context, and thus has to free resources manually. It's also true that OpenGL normally simply ignores API calls (or returns errors) if no context is set, but doing it properly is cleaner. That makeCurrent() can be called in the destructor is explicitly allowed and recommended for freeing GL resources in the Qt docs. This fixes a mpv error message on exit.
Diffstat (limited to 'video')
0 files changed, 0 insertions, 0 deletions