| 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 WebGLVertexArrayObjectBase_h | 5 #ifndef WebGLVertexArrayObjectBase_h |
| 6 #define WebGLVertexArrayObjectBase_h | 6 #define WebGLVertexArrayObjectBase_h |
| 7 | 7 |
| 8 #include "modules/webgl/WebGLBuffer.h" | 8 #include "modules/webgl/WebGLBuffer.h" |
| 9 #include "modules/webgl/WebGLContextObject.h" | 9 #include "modules/webgl/WebGLContextObject.h" |
| 10 #include "platform/heap/Handle.h" | 10 #include "platform/heap/Handle.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 bool getAttribEnabled(GLuint) const; | 38 bool getAttribEnabled(GLuint) const; |
| 39 bool isAllEnabledAttribBufferBound() const { | 39 bool isAllEnabledAttribBufferBound() const { |
| 40 return m_isAllEnabledAttribBufferBound; | 40 return m_isAllEnabledAttribBufferBound; |
| 41 } | 41 } |
| 42 void unbindBuffer(WebGLBuffer*); | 42 void unbindBuffer(WebGLBuffer*); |
| 43 | 43 |
| 44 virtual void visitChildDOMWrappers(v8::Isolate*, | 44 virtual void visitChildDOMWrappers(v8::Isolate*, |
| 45 const v8::Persistent<v8::Object>&); | 45 const v8::Persistent<v8::Object>&); |
| 46 | 46 |
| 47 DECLARE_VIRTUAL_TRACE(); | 47 DECLARE_VIRTUAL_TRACE(); |
| 48 DECLARE_VIRTUAL_TRACE_WRAPPERS(); |
| 48 | 49 |
| 49 protected: | 50 protected: |
| 50 WebGLVertexArrayObjectBase(WebGLRenderingContextBase*, VaoType); | 51 WebGLVertexArrayObjectBase(WebGLRenderingContextBase*, VaoType); |
| 51 | 52 |
| 52 private: | 53 private: |
| 53 void dispatchDetached(gpu::gles2::GLES2Interface*); | 54 void dispatchDetached(gpu::gles2::GLES2Interface*); |
| 54 bool hasObject() const override { return m_object != 0; } | 55 bool hasObject() const override { return m_object != 0; } |
| 55 void deleteObjectImpl(gpu::gles2::GLES2Interface*) override; | 56 void deleteObjectImpl(gpu::gles2::GLES2Interface*) override; |
| 56 | 57 |
| 57 void updateAttribBufferBoundStatus(); | 58 void updateAttribBufferBoundStatus(); |
| 58 | 59 |
| 59 GLuint m_object; | 60 GLuint m_object; |
| 60 | 61 |
| 61 VaoType m_type; | 62 VaoType m_type; |
| 62 bool m_hasEverBeenBound; | 63 bool m_hasEverBeenBound; |
| 63 bool m_destructionInProgress; | 64 bool m_destructionInProgress; |
| 64 Member<WebGLBuffer> m_boundElementArrayBuffer; | 65 Member<WebGLBuffer> m_boundElementArrayBuffer; |
| 65 HeapVector<Member<WebGLBuffer>> m_arrayBufferList; | 66 HeapVector<Member<WebGLBuffer>> m_arrayBufferList; |
| 66 Vector<bool> m_attribEnabled; | 67 Vector<bool> m_attribEnabled; |
| 67 bool m_isAllEnabledAttribBufferBound; | 68 bool m_isAllEnabledAttribBufferBound; |
| 68 }; | 69 }; |
| 69 | 70 |
| 70 } // namespace blink | 71 } // namespace blink |
| 71 | 72 |
| 72 #endif // WebGLVertexArrayObjectBase_h | 73 #endif // WebGLVertexArrayObjectBase_h |
| OLD | NEW |