diff options
author | wm4 <wm4@nowhere> | 2017-08-05 15:17:18 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2017-08-05 16:27:09 +0200 |
commit | dddda6e4a5353f1e5518bca175b523f1231fa700 (patch) | |
tree | 7b3181c5b8a3497b96ae0bc4d5f5184ee810c0ae /libmpv/opengl_cb.h | |
parent | 333cae74ef0fa62e0355e85d21f0f41ced3963e7 (diff) | |
download | mpv-dddda6e4a5353f1e5518bca175b523f1231fa700.tar.bz2 mpv-dddda6e4a5353f1e5518bca175b523f1231fa700.tar.xz |
vo_opengl: move GL state resetting to vo_opengl_cb
This code is pretty much for the sake of vo_opengl_cb API users. It
resets certain state that either the user or our code doesn't reset
correctly. This is somewhat outdated. With GL implicit state being
so awfully large, it seems more reasonable require that any code
restores the default state when returning to the caller. Some
exceptions are defined in opengl_cb.h.
Diffstat (limited to 'libmpv/opengl_cb.h')
-rw-r--r-- | libmpv/opengl_cb.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libmpv/opengl_cb.h b/libmpv/opengl_cb.h index fb8b928889..7d3a64e604 100644 --- a/libmpv/opengl_cb.h +++ b/libmpv/opengl_cb.h @@ -69,6 +69,9 @@ extern "C" { * standard defaults. The following state is excluded from this: * * - the current viewport (can have/is set to an arbitrary value) + * - the glScissor state (but GL_SCISSOR_TEST is expected disabled) + * - glBlendFuncSeparate() state (but GL_BLEND is expected disabled) + * - mpv always disables GL_DITHER at init * * Messing with the state could be avoided by creating shared OpenGL contexts, * but this is avoided for the sake of compatibility and interoperability. |