mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
#Fixed bug with GL_COLOR_WRITEMASK
This commit is contained in:
parent
783cdc351b
commit
2ecf6008fa
@ -884,9 +884,9 @@ void OpenGl_LayerList::UpdateOcclusion( const Handle(OpenGl_Workspace) & theWork
|
|||||||
|
|
||||||
|
|
||||||
// Remember global settings for glDepth mask and write mask
|
// Remember global settings for glDepth mask and write mask
|
||||||
GLboolean aPrevColorMask;
|
GLboolean aPrevColorMask[4];
|
||||||
GLboolean aPrevDepthMask;
|
GLboolean aPrevDepthMask;
|
||||||
aCtx->core11fwd->glGetBooleanv(GL_COLOR_WRITEMASK, &aPrevColorMask);
|
aCtx->core11fwd->glGetBooleanv(GL_COLOR_WRITEMASK, aPrevColorMask);
|
||||||
aCtx->core11fwd->glGetBooleanv(GL_DEPTH_WRITEMASK, &aPrevDepthMask);
|
aCtx->core11fwd->glGetBooleanv(GL_DEPTH_WRITEMASK, &aPrevDepthMask);
|
||||||
|
|
||||||
// Turn off writing to depth and color buffers
|
// Turn off writing to depth and color buffers
|
||||||
@ -930,7 +930,7 @@ void OpenGl_LayerList::UpdateOcclusion( const Handle(OpenGl_Workspace) & theWork
|
|||||||
|
|
||||||
// Back to prev settings
|
// Back to prev settings
|
||||||
aCtx->core11fwd->glDepthMask(aPrevDepthMask);
|
aCtx->core11fwd->glDepthMask(aPrevDepthMask);
|
||||||
aCtx->core11fwd->glColorMask(aPrevColorMask, aPrevColorMask, aPrevColorMask, aPrevColorMask);
|
aCtx->core11fwd->glColorMask(aPrevColorMask[0], aPrevColorMask[1], aPrevColorMask[2], aPrevColorMask[3]);
|
||||||
|
|
||||||
aTimer.Stop();
|
aTimer.Stop();
|
||||||
aStats->ActiveDataFrame()[Graphic3d_FrameStatsTimer_CpuCulling] = aTimer.UserTimeCPU();
|
aStats->ActiveDataFrame()[Graphic3d_FrameStatsTimer_CpuCulling] = aTimer.UserTimeCPU();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user