aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/gl/GrGLRenderTarget.cpp
diff options
context:
space:
mode:
authorGravatar cdalton <cdalton@nvidia.com>2015-11-09 15:12:19 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-11-09 15:12:19 -0800
commit14184d5567b58085b6d8a6375796d405056f7f73 (patch)
treeecf4aa20672899b736d82dd99556087667b4b510 /src/gpu/gl/GrGLRenderTarget.cpp
parent60029a5397f75aae4bdb994f26bd297edc3e433c (diff)
Fix mixed samples stencil clip
Fixes rendering bugs and nondeterminism in gm. Before, mixed samples stencil clip would try to infer whether the draw wanted co-centered sample locations from within GrGLGpu, which caused various errors. This change reworks it so the draw itself can request the co-centered sample locations when it knows it will need them. Also reduces framebuffer binds by moving the code that enables GL_FRAMEBUFFER_PROGRAMMABLE_SAMPLE_LOCATIONS into flushRenderTarget. Review URL: https://codereview.chromium.org/1431593006
Diffstat (limited to 'src/gpu/gl/GrGLRenderTarget.cpp')
-rw-r--r--src/gpu/gl/GrGLRenderTarget.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gpu/gl/GrGLRenderTarget.cpp b/src/gpu/gl/GrGLRenderTarget.cpp
index d4585f6402..2c15887259 100644
--- a/src/gpu/gl/GrGLRenderTarget.cpp
+++ b/src/gpu/gl/GrGLRenderTarget.cpp
@@ -34,10 +34,11 @@ GrGLRenderTarget::GrGLRenderTarget(GrGLGpu* gpu, const GrSurfaceDesc& desc, cons
}
void GrGLRenderTarget::init(const GrSurfaceDesc& desc, const IDDesc& idDesc) {
- fRTFBOID = idDesc.fRTFBOID;
- fTexFBOID = idDesc.fTexFBOID;
- fMSColorRenderbufferID = idDesc.fMSColorRenderbufferID;
- fRTLifecycle = idDesc.fLifeCycle;
+ fRTFBOID = idDesc.fRTFBOID;
+ fTexFBOID = idDesc.fTexFBOID;
+ fMSColorRenderbufferID = idDesc.fMSColorRenderbufferID;
+ fRTLifecycle = idDesc.fLifeCycle;
+ fHasCoCenteredSamplesTimestamp = GrGpu::kExpiredTimestamp;
fViewport.fLeft = 0;
fViewport.fBottom = 0;