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

Side by Side Diff: cc/output/geometry_binding.cc

Issue 61553006: Rename WebKit namespace to blink (part 5) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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/output/geometry_binding.h ('k') | cc/output/gl_renderer.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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 #include "cc/output/geometry_binding.h" 5 #include "cc/output/geometry_binding.h"
6 6
7 #include "cc/output/gl_renderer.h" // For the GLC() macro. 7 #include "cc/output/gl_renderer.h" // For the GLC() macro.
8 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h" 8 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
9 #include "third_party/khronos/GLES2/gl2.h" 9 #include "third_party/khronos/GLES2/gl2.h"
10 #include "ui/gfx/rect_f.h" 10 #include "ui/gfx/rect_f.h"
11 11
12 namespace cc { 12 namespace cc {
13 13
14 GeometryBinding::GeometryBinding(WebKit::WebGraphicsContext3D* context, 14 GeometryBinding::GeometryBinding(blink::WebGraphicsContext3D* context,
15 const gfx::RectF& quad_vertex_rect) 15 const gfx::RectF& quad_vertex_rect)
16 : context_(context), 16 : context_(context),
17 quad_vertices_vbo_(0), 17 quad_vertices_vbo_(0),
18 quad_elements_vbo_(0) { 18 quad_elements_vbo_(0) {
19 struct Vertex { 19 struct Vertex {
20 float a_position[3]; 20 float a_position[3];
21 float a_texCoord[2]; 21 float a_texCoord[2];
22 // Index of the vertex, divide by 4 to have the matrix for this quad. 22 // Index of the vertex, divide by 4 to have the matrix for this quad.
23 float a_index; 23 float a_index;
24 }; 24 };
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 false, 113 false,
114 6 * sizeof(float), // NOLINT(runtime/sizeof) 114 6 * sizeof(float), // NOLINT(runtime/sizeof)
115 5 * sizeof(float))); // NOLINT(runtime/sizeof) 115 5 * sizeof(float))); // NOLINT(runtime/sizeof)
116 GLC(context_, context_->enableVertexAttribArray(PositionAttribLocation())); 116 GLC(context_, context_->enableVertexAttribArray(PositionAttribLocation()));
117 GLC(context_, context_->enableVertexAttribArray(TexCoordAttribLocation())); 117 GLC(context_, context_->enableVertexAttribArray(TexCoordAttribLocation()));
118 GLC(context_, 118 GLC(context_,
119 context_->enableVertexAttribArray(TriangleIndexAttribLocation())); 119 context_->enableVertexAttribArray(TriangleIndexAttribLocation()));
120 } 120 }
121 121
122 } // namespace cc 122 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/geometry_binding.h ('k') | cc/output/gl_renderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698