Title: [272155] branches/safari-611-branch/Source/WebCore
- Revision
- 272155
- Author
- [email protected]
- Date
- 2021-02-01 12:11:32 -0800 (Mon, 01 Feb 2021)
Log Message
Cherry-pick r271609. rdar://problem/73838888
REGRESSION (r270964): Hovering cursor over Earth animation causes flashing red distortion on GitHub.com
https://bugs.webkit.org/show_bug.cgi?id=220612
<rdar://problem/73175210>
Patch by Kimmo Kinnunen <[email protected]> on 2021-01-19
Reviewed by Dean Jackson.
When reading the display buffer for WebKit snapshots, use READ_FRAMEBUFFER on WebGL2 and
FRAMEBUFFER on WebGL1. Fixes the case where WebGL2 contexts would get broken because
taking a snapshot would overwrite the framebuffer attachment.
No new tests, snapshots are not tested at the moment.
* platform/graphics/angle/GraphicsContextGLANGLEUtilities.h:
(WebCore::ScopedRestoreReadFramebufferBinding::framebufferTarget const):
* platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
(WebCore::GraphicsContextGLOpenGL::readCompositedResults):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@271609 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Diff
Modified: branches/safari-611-branch/Source/WebCore/ChangeLog (272154 => 272155)
--- branches/safari-611-branch/Source/WebCore/ChangeLog 2021-02-01 20:06:26 UTC (rev 272154)
+++ branches/safari-611-branch/Source/WebCore/ChangeLog 2021-02-01 20:11:32 UTC (rev 272155)
@@ -1,3 +1,46 @@
+2021-02-01 Alan Coon <[email protected]>
+
+ Cherry-pick r271609. rdar://problem/73838888
+
+ REGRESSION (r270964): Hovering cursor over Earth animation causes flashing red distortion on GitHub.com
+ https://bugs.webkit.org/show_bug.cgi?id=220612
+ <rdar://problem/73175210>
+
+ Patch by Kimmo Kinnunen <[email protected]> on 2021-01-19
+ Reviewed by Dean Jackson.
+
+ When reading the display buffer for WebKit snapshots, use READ_FRAMEBUFFER on WebGL2 and
+ FRAMEBUFFER on WebGL1. Fixes the case where WebGL2 contexts would get broken because
+ taking a snapshot would overwrite the framebuffer attachment.
+
+ No new tests, snapshots are not tested at the moment.
+
+ * platform/graphics/angle/GraphicsContextGLANGLEUtilities.h:
+ (WebCore::ScopedRestoreReadFramebufferBinding::framebufferTarget const):
+ * platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
+ (WebCore::GraphicsContextGLOpenGL::readCompositedResults):
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@271609 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2021-01-19 Kimmo Kinnunen <[email protected]>
+
+ REGRESSION (r270964): Hovering cursor over Earth animation causes flashing red distortion on GitHub.com
+ https://bugs.webkit.org/show_bug.cgi?id=220612
+ <rdar://problem/73175210>
+
+ Reviewed by Dean Jackson.
+
+ When reading the display buffer for WebKit snapshots, use READ_FRAMEBUFFER on WebGL2 and
+ FRAMEBUFFER on WebGL1. Fixes the case where WebGL2 contexts would get broken because
+ taking a snapshot would overwrite the framebuffer attachment.
+
+ No new tests, snapshots are not tested at the moment.
+
+ * platform/graphics/angle/GraphicsContextGLANGLEUtilities.h:
+ (WebCore::ScopedRestoreReadFramebufferBinding::framebufferTarget const):
+ * platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
+ (WebCore::GraphicsContextGLOpenGL::readCompositedResults):
+
2021-01-29 Alan Coon <[email protected]>
Cherry-pick r271551. rdar://problem/73473686
Modified: branches/safari-611-branch/Source/WebCore/platform/graphics/angle/GraphicsContextGLANGLEUtilities.h (272154 => 272155)
--- branches/safari-611-branch/Source/WebCore/platform/graphics/angle/GraphicsContextGLANGLEUtilities.h 2021-02-01 20:06:26 UTC (rev 272154)
+++ branches/safari-611-branch/Source/WebCore/platform/graphics/angle/GraphicsContextGLANGLEUtilities.h 2021-02-01 20:11:32 UTC (rev 272155)
@@ -113,6 +113,7 @@
gl::BindFramebuffer(m_framebufferTarget, bindingValue);
m_bindingChanged = m_bindingValue != bindingValue;
}
+ GLuint framebufferTarget() const { return m_framebufferTarget; }
~ScopedRestoreReadFramebufferBinding()
{
if (m_bindingChanged)
Modified: branches/safari-611-branch/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm (272154 => 272155)
--- branches/safari-611-branch/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm 2021-02-01 20:06:26 UTC (rev 272154)
+++ branches/safari-611-branch/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm 2021-02-01 20:11:32 UTC (rev 272155)
@@ -753,8 +753,8 @@
gl::TexParameteri(textureTarget, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
ScopedFramebuffer fbo;
ScopedRestoreReadFramebufferBinding fboBinding(m_isForWebGL2, m_state.boundReadFBO, fbo);
- gl::FramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, textureTarget, texture, 0);
- ASSERT(gl::CheckFramebufferStatus(GL_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
+ gl::FramebufferTexture2D(fboBinding.framebufferTarget(), GL_COLOR_ATTACHMENT0, textureTarget, texture, 0);
+ ASSERT(gl::CheckFramebufferStatus(fboBinding.framebufferTarget()) == GL_FRAMEBUFFER_COMPLETE);
auto result = readPixelsForPaintResults();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes