From 3f91615a2263f95fda40ae5cc427bcf67e2064f5 Mon Sep 17 00:00:00 2001 From: rdb Date: Fri, 23 Nov 2018 00:22:34 +0100 Subject: [PATCH] glgsg: reset color write mask before calling draw callback --- panda/src/glstuff/glGraphicsStateGuardian_src.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/panda/src/glstuff/glGraphicsStateGuardian_src.cxx b/panda/src/glstuff/glGraphicsStateGuardian_src.cxx index 4a80e7044a..8e9105de1c 100644 --- a/panda/src/glstuff/glGraphicsStateGuardian_src.cxx +++ b/panda/src/glstuff/glGraphicsStateGuardian_src.cxx @@ -3754,6 +3754,10 @@ clear_before_callback() { _glClientActiveTexture(GL_TEXTURE0); #endif + // It's also quite reasonable to presume there aren't any funny color write + // mask settings active. + clear_color_write_mask(); + // Clear the bound sampler object, so that we do not inadvertently override // the callback's desired sampler settings. #ifndef OPENGLES_1