Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: cc/stubs/GraphicsContext3D.h

Issue 10915074: Fix up cc stubs and bindings to work in windows (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/cc.gyp ('k') | cc/stubs/TextStream.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CC_STUBS_GRAPHICSCONTEXT3D_H_ 5 #ifndef CC_STUBS_GRAPHICSCONTEXT3D_H_
6 #define CC_STUBS_GRAPHICSCONTEXT3D_H_ 6 #define CC_STUBS_GRAPHICSCONTEXT3D_H_
7 7
8 #include "GraphicsTypes3D.h" 8 #include "GraphicsTypes3D.h"
9 #include "IntSize.h" 9 #include "IntSize.h"
10 #include "third_party/khronos/GLES2/gl2.h" 10 #include "third_party/khronos/GLES2/gl2.h"
11 11
12 #ifdef NO_ERROR
13 #undef NO_ERROR
14 #endif
15
12 namespace WebCore { 16 namespace WebCore {
13 17
14 class GraphicsContext3D { 18 class GraphicsContext3D {
15 public: 19 public:
16 enum SourceDataFormat { SourceFormatRGBA8, SourceFormatBGRA8 }; 20 enum SourceDataFormat { SourceFormatRGBA8, SourceFormatBGRA8 };
17 static bool computeFormatAndTypeParameters(unsigned, unsigned, unsigned* com ponentsPerPixel, unsigned* bytesPerComponent) 21 static bool computeFormatAndTypeParameters(unsigned, unsigned, unsigned* com ponentsPerPixel, unsigned* bytesPerComponent);
18 {
19 *componentsPerPixel = 4;
20 *bytesPerComponent = 1;
21 return true;
22 }
23 22
24 enum { 23 enum {
25 ARRAY_BUFFER = GL_ARRAY_BUFFER, 24 ARRAY_BUFFER = GL_ARRAY_BUFFER,
26 BLEND = GL_BLEND, 25 BLEND = GL_BLEND,
27 CLAMP_TO_EDGE = GL_CLAMP_TO_EDGE, 26 CLAMP_TO_EDGE = GL_CLAMP_TO_EDGE,
28 COLOR_ATTACHMENT0 = GL_COLOR_ATTACHMENT0, 27 COLOR_ATTACHMENT0 = GL_COLOR_ATTACHMENT0,
29 COLOR_BUFFER_BIT = GL_COLOR_BUFFER_BIT, 28 COLOR_BUFFER_BIT = GL_COLOR_BUFFER_BIT,
30 COMPILE_STATUS = GL_COMPILE_STATUS, 29 COMPILE_STATUS = GL_COMPILE_STATUS,
31 CULL_FACE = GL_CULL_FACE, 30 CULL_FACE = GL_CULL_FACE,
32 DEPTH_TEST = GL_DEPTH_TEST, 31 DEPTH_TEST = GL_DEPTH_TEST,
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 UNSIGNED_SHORT = GL_UNSIGNED_SHORT, 66 UNSIGNED_SHORT = GL_UNSIGNED_SHORT,
68 VERTEX_SHADER = GL_VERTEX_SHADER, 67 VERTEX_SHADER = GL_VERTEX_SHADER,
69 ZERO = GL_ZERO, 68 ZERO = GL_ZERO,
70 }; 69 };
71 }; 70 };
72 71
73 } 72 }
74 73
75 #endif // CC_STUBS_GRAPHICSCONTEXT3D_H_ 74 #endif // CC_STUBS_GRAPHICSCONTEXT3D_H_
76 75
OLDNEW
« no previous file with comments | « cc/cc.gyp ('k') | cc/stubs/TextStream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698