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

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

Issue 15462003: Update references to Blink's Platform API headers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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/output/render_surface_filters_unittest.cc ('k') | cc/output/texture_copier.cc » ('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/shader.h" 5 #include "cc/output/shader.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
11 #include "cc/output/gl_renderer.h" // For the GLC() macro. 11 #include "cc/output/gl_renderer.h" // For the GLC() macro.
12 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3 D.h" 12 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
13 #include "third_party/khronos/GLES2/gl2.h" 13 #include "third_party/khronos/GLES2/gl2.h"
14 14
15 #define SHADER0(Src) #Src 15 #define SHADER0(Src) #Src
16 #define VERTEX_SHADER(Src) SetVertexTexCoordPrecision(SHADER0(Src)) 16 #define VERTEX_SHADER(Src) SetVertexTexCoordPrecision(SHADER0(Src))
17 #define FRAGMENT_SHADER(Src) SetFragTexCoordPrecision(precision, SHADER0(Src)) 17 #define FRAGMENT_SHADER(Src) SetFragTexCoordPrecision(precision, SHADER0(Src))
18 18
19 using WebKit::WebGraphicsContext3D; 19 using WebKit::WebGraphicsContext3D;
20 20
21 namespace cc { 21 namespace cc {
22 22
(...skipping 1470 matching lines...) Expand 10 before | Expand all | Expand 10 after
1493 vec2 texCoord = 1493 vec2 texCoord =
1494 clamp(v_texCoord, 0.0, 1.0) * texTransform.zw + texTransform.xy; 1494 clamp(v_texCoord, 0.0, 1.0) * texTransform.zw + texTransform.xy;
1495 vec2 coord = mod(floor(texCoord * frequency * 2.0), 2.0); 1495 vec2 coord = mod(floor(texCoord * frequency * 2.0), 2.0);
1496 float picker = abs(coord.x - coord.y); 1496 float picker = abs(coord.x - coord.y);
1497 gl_FragColor = mix(color1, color2, picker) * alpha; 1497 gl_FragColor = mix(color1, color2, picker) * alpha;
1498 } 1498 }
1499 ); // NOLINT(whitespace/parens) 1499 ); // NOLINT(whitespace/parens)
1500 } 1500 }
1501 1501
1502 } // namespace cc 1502 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/render_surface_filters_unittest.cc ('k') | cc/output/texture_copier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698