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

Unified Diff: cc/output/geometry_binding.cc

Issue 13206004: cc: Fix build issues for adding ‘chromium_code’: 1 to cc.gyp and cc_tests.gyp (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/output/delegating_renderer.cc ('k') | cc/output/gl_renderer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/geometry_binding.cc
diff --git a/cc/output/geometry_binding.cc b/cc/output/geometry_binding.cc
index 20bd666ca8cd705cf36b562016069bafdeab5019..f1092cebb8d36b637059131b561c4bbc4c21678b 100644
--- a/cc/output/geometry_binding.cc
+++ b/cc/output/geometry_binding.cc
@@ -16,14 +16,6 @@ GeometryBinding::GeometryBinding(WebKit::WebGraphicsContext3D* context,
: context_(context),
quad_vertices_vbo_(0),
quad_elements_vbo_(0) {
- float vertices[] = {
- quad_vertex_rect.x(), quad_vertex_rect.bottom(), 0.0f, 0.0f,
- 1.0f, quad_vertex_rect.x(), quad_vertex_rect.y(), 0.0f,
- 0.0f, 0.0f, quad_vertex_rect.right(), quad_vertex_rect.y(),
- 0.0f, 1.0f, 0.0f, quad_vertex_rect.right(),
- quad_vertex_rect.bottom(), 0.0f, 1.0f, 1.0f
- };
-
struct Vertex {
float a_position[3];
float a_texCoord[2];
@@ -47,18 +39,28 @@ GeometryBinding::GeometryBinding(WebKit::WebGraphicsContext3D* context,
Quad quad_list[8];
QuadIndex quad_index_list[8];
for (int i = 0; i < 8; i++) {
- Vertex v0 = { quad_vertex_rect.x(), quad_vertex_rect.bottom(), 0.0f, 0.0f,
- 1.0f, i * 4.0f + 0.0f };
- Vertex v1 = { quad_vertex_rect.x(), quad_vertex_rect.y(), 0.0f, 0.0f, 0.0f,
+ Vertex v0 = { { quad_vertex_rect.x(), quad_vertex_rect.bottom(), 0.0f, },
+ { 0.0f, 1.0f, },
+ i * 4.0f + 0.0f };
+ Vertex v1 = { { quad_vertex_rect.x(), quad_vertex_rect.y(), 0.0f, },
+ { 0.0f, 0.0f, },
i * 4.0f + 1.0f };
- Vertex v2 = { quad_vertex_rect.right(), quad_vertex_rect.y(), 0.0f, 1.0f,
- 0.0f, i * 4.0f + 2.0f };
- Vertex v3 = { quad_vertex_rect.right(), quad_vertex_rect.bottom(), 0.0f,
- 1.0f, 1.0f, i * 4.0f + 3.0f };
+ Vertex v2 = { { quad_vertex_rect.right(), quad_vertex_rect.y(), 0.0f, },
+ { 1.0f, .0f, },
+ i * 4.0f + 2.0f };
+ Vertex v3 = { { quad_vertex_rect.right(),
+ quad_vertex_rect.bottom(),
+ 0.0f, },
+ { 1.0f, 1.0f, },
+ i * 4.0f + 3.0f };
Quad x = { v0, v1, v2, v3 };
quad_list[i] = x;
- QuadIndex y = { 0 + 4 * i, 1 + 4 * i, 2 + 4 * i, 3 + 4 * i, 0 + 4 * i,
- 2 + 4 * i };
+ QuadIndex y = { { 0 + 4 * i,
+ 1 + 4 * i,
+ 2 + 4 * i,
+ 3 + 4 * i,
+ 0 + 4 * i,
+ 2 + 4 * i } };
quad_index_list[i] = y;
}
« no previous file with comments | « cc/output/delegating_renderer.cc ('k') | cc/output/gl_renderer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698