Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(722)

Unified Diff: src/gpu/gl/GrGpuGL.cpp

Issue 574543002: Always disable the scissor test before BlitFrameBuffer (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGpuGL.cpp
diff --git a/src/gpu/gl/GrGpuGL.cpp b/src/gpu/gl/GrGpuGL.cpp
index 39cb84ecfe8247616b4bd10b77b67e5284c30031..c335e128c7a7b1bd8965f7b3397866405ff5edb0 100644
--- a/src/gpu/gl/GrGpuGL.cpp
+++ b/src/gpu/gl/GrGpuGL.cpp
@@ -1819,14 +1819,13 @@ void GrGpuGL::onResolveRenderTarget(GrRenderTarget* target) {
this->flushScissor(rt->getViewport(), rt->origin());
GL_CALL(ResolveMultisampleFramebuffer());
} else {
- if (GrGLCaps::kDesktop_EXT_MSFBOType == this->glCaps().msFBOType()) {
- // this respects the scissor during the blit, so disable it.
- asr.reset(&fScissorState);
- fScissorState.fEnabled = false;
- this->flushScissor(rt->getViewport(), rt->origin());
- }
int right = r.fLeft + r.fWidth;
int top = r.fBottom + r.fHeight;
+
+ // BlitFrameBuffer respects the scissor, so disable it.
+ asr.reset(&fScissorState);
+ fScissorState.fEnabled = false;
+ this->flushScissor(rt->getViewport(), rt->origin());
GL_CALL(BlitFramebuffer(r.fLeft, r.fBottom, right, top,
r.fLeft, r.fBottom, right, top,
GR_GL_COLOR_BUFFER_BIT, GR_GL_NEAREST));
@@ -2495,12 +2494,11 @@ bool GrGpuGL::onCopySurface(GrSurface* dst,
dst->origin());
GrAutoTRestore<ScissorState> asr;
- if (GrGLCaps::kDesktop_EXT_MSFBOType == this->glCaps().msFBOType()) {
- // The EXT version applies the scissor during the blit, so disable it.
- asr.reset(&fScissorState);
- fScissorState.fEnabled = false;
- this->flushScissor(dstGLRect, dst->origin());
- }
+ // BlitFrameBuffer respects the scissor, so disable it.
+ asr.reset(&fScissorState);
+ fScissorState.fEnabled = false;
+ this->flushScissor(dstGLRect, dst->origin());
+
GrGLint srcY0;
GrGLint srcY1;
// Does the blit need to y-mirror or not?
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698