| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef WebGL2RenderingContextBase_h | 5 #ifndef WebGL2RenderingContextBase_h |
| 6 #define WebGL2RenderingContextBase_h | 6 #define WebGL2RenderingContextBase_h |
| 7 | 7 |
| 8 #include "modules/webgl/WebGLExtension.h" | 8 #include "modules/webgl/WebGLExtension.h" |
| 9 #include "modules/webgl/WebGLRenderingContextBase.h" | 9 #include "modules/webgl/WebGLRenderingContextBase.h" |
| 10 | 10 |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 ScriptValue getIndexedParameter(ScriptState*, GLenum, GLuint); | 153 ScriptValue getIndexedParameter(ScriptState*, GLenum, GLuint); |
| 154 Vector<GLuint> getUniformIndices(WebGLProgram*, const Vector<String>&); | 154 Vector<GLuint> getUniformIndices(WebGLProgram*, const Vector<String>&); |
| 155 Vector<GLint> getActiveUniforms(WebGLProgram*, const Vector<GLuint>&, GLenum
); | 155 Vector<GLint> getActiveUniforms(WebGLProgram*, const Vector<GLuint>&, GLenum
); |
| 156 GLuint getUniformBlockIndex(WebGLProgram*, const String&); | 156 GLuint getUniformBlockIndex(WebGLProgram*, const String&); |
| 157 ScriptValue getActiveUniformBlockParameter(ScriptState*, WebGLProgram*, GLui
nt, GLenum); | 157 ScriptValue getActiveUniformBlockParameter(ScriptState*, WebGLProgram*, GLui
nt, GLenum); |
| 158 String getActiveUniformBlockName(WebGLProgram*, GLuint); | 158 String getActiveUniformBlockName(WebGLProgram*, GLuint); |
| 159 void uniformBlockBinding(WebGLProgram*, GLuint, GLuint); | 159 void uniformBlockBinding(WebGLProgram*, GLuint, GLuint); |
| 160 | 160 |
| 161 /* Vertex Array Objects */ | 161 /* Vertex Array Objects */ |
| 162 WebGLVertexArrayObject* createVertexArray(); | 162 WebGLVertexArrayObject* createVertexArray(); |
| 163 void deleteVertexArray(WebGLVertexArrayObject*); | 163 void deleteVertexArray(ScriptState*, WebGLVertexArrayObject*); |
| 164 GLboolean isVertexArray(WebGLVertexArrayObject*); | 164 GLboolean isVertexArray(WebGLVertexArrayObject*); |
| 165 void bindVertexArray(WebGLVertexArrayObject*); | 165 void bindVertexArray(ScriptState*, WebGLVertexArrayObject*); |
| 166 | 166 |
| 167 /* Reading */ | 167 /* Reading */ |
| 168 void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum form
at, GLenum type, long long offset); | 168 void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum form
at, GLenum type, long long offset); |
| 169 | 169 |
| 170 /* WebGLRenderingContextBase overrides */ | 170 /* WebGLRenderingContextBase overrides */ |
| 171 void initializeNewContext() override; | 171 void initializeNewContext() override; |
| 172 void bindFramebuffer(GLenum target, WebGLFramebuffer*) override; | 172 void bindFramebuffer(ScriptState*, GLenum target, WebGLFramebuffer*) overrid
e; |
| 173 void deleteFramebuffer(WebGLFramebuffer*) override; | 173 void deleteFramebuffer(WebGLFramebuffer*) override; |
| 174 ScriptValue getParameter(ScriptState*, GLenum pname) override; | 174 ScriptValue getParameter(ScriptState*, GLenum pname) override; |
| 175 ScriptValue getTexParameter(ScriptState*, GLenum target, GLenum pname) overr
ide; | 175 ScriptValue getTexParameter(ScriptState*, GLenum target, GLenum pname) overr
ide; |
| 176 ScriptValue getFramebufferAttachmentParameter(ScriptState*, GLenum target, G
Lenum attachment, GLenum pname) override; | 176 ScriptValue getFramebufferAttachmentParameter(ScriptState*, GLenum target, G
Lenum attachment, GLenum pname) override; |
| 177 void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum form
at, GLenum type, DOMArrayBufferView* pixels) override; | 177 void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum form
at, GLenum type, DOMArrayBufferView* pixels) override; |
| 178 void restoreCurrentFramebuffer() override; | 178 void restoreCurrentFramebuffer() override; |
| 179 | 179 |
| 180 EAGERLY_FINALIZE(); | 180 EAGERLY_FINALIZE(); |
| 181 DECLARE_VIRTUAL_TRACE(); | 181 DECLARE_VIRTUAL_TRACE(); |
| 182 | 182 |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 PersistentHeapVectorWillBeHeapVector<Member<WebGLSampler>> m_samplerUnits; | 254 PersistentHeapVectorWillBeHeapVector<Member<WebGLSampler>> m_samplerUnits; |
| 255 }; | 255 }; |
| 256 | 256 |
| 257 DEFINE_TYPE_CASTS(WebGL2RenderingContextBase, CanvasRenderingContext, context, | 257 DEFINE_TYPE_CASTS(WebGL2RenderingContextBase, CanvasRenderingContext, context, |
| 258 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) >= 2, | 258 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) >= 2, |
| 259 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) >= 2)
; | 259 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) >= 2)
; |
| 260 | 260 |
| 261 } // namespace blink | 261 } // namespace blink |
| 262 | 262 |
| 263 #endif | 263 #endif |
| OLD | NEW |