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 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 class WebGLVertexArrayObjectOES; | 90 class WebGLVertexArrayObjectOES; |
91 | 91 |
92 class WebGLRenderingContextLostCallback; | 92 class WebGLRenderingContextLostCallback; |
93 class WebGLRenderingContextErrorMessageCallback; | 93 class WebGLRenderingContextErrorMessageCallback; |
94 | 94 |
95 class WebGLRenderingContext FINAL : public CanvasRenderingContext, public Active
DOMObject, private Page::MultisamplingChangedObserver { | 95 class WebGLRenderingContext FINAL : public CanvasRenderingContext, public Active
DOMObject, private Page::MultisamplingChangedObserver { |
96 public: | 96 public: |
97 static PassOwnPtr<WebGLRenderingContext> create(HTMLCanvasElement*, WebGLCon
textAttributes*); | 97 static PassOwnPtr<WebGLRenderingContext> create(HTMLCanvasElement*, WebGLCon
textAttributes*); |
98 virtual ~WebGLRenderingContext(); | 98 virtual ~WebGLRenderingContext(); |
99 | 99 |
100 virtual bool is3d() const { return true; } | 100 virtual bool is3d() const OVERRIDE { return true; } |
101 virtual bool isAccelerated() const OVERRIDE { return true; } | 101 virtual bool isAccelerated() const OVERRIDE { return true; } |
102 | 102 |
103 int drawingBufferWidth() const; | 103 int drawingBufferWidth() const; |
104 int drawingBufferHeight() const; | 104 int drawingBufferHeight() const; |
105 | 105 |
106 void activeTexture(GLenum texture); | 106 void activeTexture(GLenum texture); |
107 void attachShader(WebGLProgram*, WebGLShader*); | 107 void attachShader(WebGLProgram*, WebGLShader*); |
108 void bindAttribLocation(WebGLProgram*, GLuint index, const String& name); | 108 void bindAttribLocation(WebGLProgram*, GLuint index, const String& name); |
109 void bindBuffer(GLenum target, WebGLBuffer*); | 109 void bindBuffer(GLenum target, WebGLBuffer*); |
110 void bindFramebuffer(GLenum target, WebGLFramebuffer*); | 110 void bindFramebuffer(GLenum target, WebGLFramebuffer*); |
(...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
924 // If the vector is empty, return the maximum allowed active context number. | 924 // If the vector is empty, return the maximum allowed active context number. |
925 static size_t oldestContextIndex(); | 925 static size_t oldestContextIndex(); |
926 static IntSize oldestContextSize(); | 926 static IntSize oldestContextSize(); |
927 }; | 927 }; |
928 | 928 |
929 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, contex
t->is3d(), context.is3d()); | 929 DEFINE_TYPE_CASTS(WebGLRenderingContext, CanvasRenderingContext, context, contex
t->is3d(), context.is3d()); |
930 | 930 |
931 } // namespace WebCore | 931 } // namespace WebCore |
932 | 932 |
933 #endif | 933 #endif |
OLD | NEW |