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* create(HTMLCanvasElement*, const CanvasContextCr
eationAttributes&, Document&) override; | 46 CanvasRenderingContext* create(HTMLCanvasElement*, const CanvasContextCr
eationAttributes&, Document&) override; |
47 CanvasRenderingContext* create(ScriptState*, OffscreenCanvas*, const Can
vasContextCreationAttributes&) override; | 47 CanvasRenderingContext* create(ScriptState*, OffscreenCanvas*, const Can
vasContextCreationAttributes&) override; |
48 CanvasRenderingContext::ContextType getContextType() const override { re
turn CanvasRenderingContext::ContextWebgl; } | 48 CanvasRenderingContext::ContextType getContextType() const override { re
turn CanvasRenderingContext::ContextWebgl; } |
49 void onError(HTMLCanvasElement*, const String& error) override; | 49 void onError(HTMLCanvasElement*, const String& error) override; |
50 }; | 50 }; |
51 | 51 |
52 ~WebGLRenderingContext() override; | 52 ~WebGLRenderingContext() override; |
53 | 53 |
54 CanvasRenderingContext::ContextType getContextType() const override { return
CanvasRenderingContext::ContextWebgl; } | 54 CanvasRenderingContext::ContextType getContextType() const override { return
CanvasRenderingContext::ContextWebgl; } |
55 ImageBitmap* transferToImageBitmap(ExceptionState&) final; | 55 ImageBitmap* transferToImageBitmap(ExceptionState&) final; |
56 unsigned version() const override { return 1; } | |
57 String contextName() const override { return "WebGLRenderingContext"; } | 56 String contextName() const override { return "WebGLRenderingContext"; } |
58 void registerContextExtensions() override; | 57 void registerContextExtensions() override; |
59 void setCanvasGetContextResult(RenderingContext&) final; | 58 void setCanvasGetContextResult(RenderingContext&) final; |
60 void setOffscreenCanvasGetContextResult(OffscreenRenderingContext&) final; | 59 void setOffscreenCanvasGetContextResult(OffscreenRenderingContext&) final; |
61 | 60 |
62 EAGERLY_FINALIZE(); | 61 EAGERLY_FINALIZE(); |
63 DECLARE_VIRTUAL_TRACE(); | 62 DECLARE_VIRTUAL_TRACE(); |
64 | 63 |
65 DECLARE_VIRTUAL_TRACE_WRAPPERS(); | 64 DECLARE_VIRTUAL_TRACE_WRAPPERS(); |
66 | 65 |
(...skipping 28 matching lines...) Expand all Loading... |
95 Member<WebGLDepthTexture> m_webglDepthTexture; | 94 Member<WebGLDepthTexture> m_webglDepthTexture; |
96 }; | 95 }; |
97 | 96 |
98 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, | 97 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, |
99 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) == 1, | 98 context->is3d() && WebGLRenderingContextBase::getWebGLVersion(context) == 1, |
100 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) == 1)
; | 99 context.is3d() && WebGLRenderingContextBase::getWebGLVersion(&context) == 1)
; |
101 | 100 |
102 } // namespace blink | 101 } // namespace blink |
103 | 102 |
104 #endif // WebGLRenderingContext_h | 103 #endif // WebGLRenderingContext_h |
OLD | NEW |