| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 CanvasRenderingContext::ContextType getContextType() const override { re
turn CanvasRenderingContext::ContextWebgl; } | 46 CanvasRenderingContext::ContextType getContextType() const override { re
turn CanvasRenderingContext::ContextWebgl; } |
| 47 void onError(HTMLCanvasElement*, const String& error) override; | 47 void onError(HTMLCanvasElement*, const String& error) override; |
| 48 }; | 48 }; |
| 49 | 49 |
| 50 ~WebGLRenderingContext() override; | 50 ~WebGLRenderingContext() override; |
| 51 | 51 |
| 52 CanvasRenderingContext::ContextType getContextType() const override { return
CanvasRenderingContext::ContextWebgl; } | 52 CanvasRenderingContext::ContextType getContextType() const override { return
CanvasRenderingContext::ContextWebgl; } |
| 53 unsigned version() const override { return 1; } | 53 unsigned version() const override { return 1; } |
| 54 String contextName() const override { return "WebGLRenderingContext"; } | 54 String contextName() const override { return "WebGLRenderingContext"; } |
| 55 void registerContextExtensions() override; | 55 void registerContextExtensions() override; |
| 56 void setCanvasGetContextResult(RenderingContext&) final; |
| 56 | 57 |
| 57 EAGERLY_FINALIZE(); | 58 EAGERLY_FINALIZE(); |
| 58 DECLARE_VIRTUAL_TRACE(); | 59 DECLARE_VIRTUAL_TRACE(); |
| 59 | 60 |
| 60 private: | 61 private: |
| 61 WebGLRenderingContext(HTMLCanvasElement*, PassOwnPtr<WebGraphicsContext3D>,
const WebGLContextAttributes&); | 62 WebGLRenderingContext(HTMLCanvasElement*, PassOwnPtr<WebGraphicsContext3D>,
const WebGLContextAttributes&); |
| 62 | 63 |
| 63 // Enabled extension objects. | 64 // Enabled extension objects. |
| 64 PersistentWillBeMember<ANGLEInstancedArrays> m_angleInstancedArrays; | 65 PersistentWillBeMember<ANGLEInstancedArrays> m_angleInstancedArrays; |
| 65 PersistentWillBeMember<CHROMIUMSubscribeUniform> m_chromiumSubscribeUniform; | 66 PersistentWillBeMember<CHROMIUMSubscribeUniform> m_chromiumSubscribeUniform; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 88 PersistentWillBeMember<WebGLDepthTexture> m_webglDepthTexture; | 89 PersistentWillBeMember<WebGLDepthTexture> m_webglDepthTexture; |
| 89 }; | 90 }; |
| 90 | 91 |
| 91 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, | 92 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, |
| 92 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) == 1, | 93 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) == 1, |
| 93 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) == 1)
; | 94 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) == 1)
; |
| 94 | 95 |
| 95 } // namespace blink | 96 } // namespace blink |
| 96 | 97 |
| 97 #endif // WebGLRenderingContext_h | 98 #endif // WebGLRenderingContext_h |
| OLD | NEW |