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

Unified Diff: trunk/src/cc/output/geometry_binding.cc

Issue 13316003: Revert 191364 "cc: Add ‘chromium_code’: 1 to cc.gyp and cc_t..." (Closed) Base URL: svn://svn.chromium.org/chrome/
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 | « trunk/src/cc/output/delegating_renderer.cc ('k') | trunk/src/cc/output/gl_renderer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/cc/output/geometry_binding.cc
===================================================================
--- trunk/src/cc/output/geometry_binding.cc (revision 191370)
+++ trunk/src/cc/output/geometry_binding.cc (working copy)
@@ -16,6 +16,14 @@
: 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];
@@ -39,28 +47,18 @@
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, .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,
+ 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 };
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 | « trunk/src/cc/output/delegating_renderer.cc ('k') | trunk/src/cc/output/gl_renderer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698