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

Unified Diff: third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h

Issue 2384593002: Encode frame number in pixel data for pose sync (Closed)
Patch Set: bajones #40: add sanity check + pointer zeroing Created 4 years, 2 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
Index: third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h
diff --git a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h
index 7361900ff6bc11242d0cfb4f13beead7719f6fc5..f1634335890d30b9660e505ba873b80c4cf69d24 100644
--- a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h
+++ b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.h
@@ -539,6 +539,18 @@ class MODULES_EXPORT WebGLRenderingContextBase : public CanvasRenderingContext {
void forceRestoreContext();
void loseContextImpl(LostContextMode, AutoRecoveryMethod);
+ // Utilities to restore GL state to match the rendering context's
+ // saved state. Use these after contextGL()-based state changes that
+ // bypass the rendering context.
+ void restoreScissorEnabled();
+ void restoreScissorBox();
+ void restoreClearColor();
+ void restoreClearDepthf();
+ void restoreClearStencil();
+ void restoreStencilMaskSeparate();
+ void restoreColorMask();
+ void restoreDepthMask();
+
gpu::gles2::GLES2Interface* contextGL() const {
DrawingBuffer* d = drawingBuffer();
if (!d)
@@ -762,6 +774,7 @@ class MODULES_EXPORT WebGLRenderingContextBase : public CanvasRenderingContext {
GLfloat m_clearColor[4];
bool m_scissorEnabled;
+ GLint m_scissorBox[4];
GLfloat m_clearDepth;
GLint m_clearStencil;
GLboolean m_colorMask[4];

Powered by Google App Engine
This is Rietveld 408576698