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

Side by Side Diff: conformance/shaders/misc/shared-b.frag

Issue 8344024: Remove older revision of webgl conformance tests. (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/webgl/sdk/tests/
Patch Set: Created 9 years, 2 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 | « conformance/shaders/misc/shared-a.frag ('k') | conformance/shaders/reserved/00_shaders.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // shared fragment shader should succeed.
2 precision mediump float;
3 varying vec4 v_position;
4 varying vec2 v_texCoord;
5 varying vec3 v_surfaceToLight;
6
7 // #fogUniforms
8
9 vec4 lit(float l ,float h, float m) {
10 return vec4(1.0,
11 max(l, 0.0),
12 (l > 0.0) ? pow(max(0.0, h), m) : 0.0,
13 1.0);
14 }
15 void main() {
16 vec4 normalSpec = vec4(0,0,0,0); // #noNormalMap
17 vec4 reflection = vec4(0,0,0,0); // #noReflection
18 vec3 surfaceToLight = normalize(v_surfaceToLight);
19 vec4 skyColor = vec4(0.5,0.5,1,1); // #noReflection
20
21 vec3 halfVector = normalize(surfaceToLight);
22 vec4 litR = lit(1.0, 1.0, 10.0);
23 vec4 outColor = vec4(mix(
24 skyColor,
25 vec4(1,2,3,4) * (litR.y + litR.z * normalSpec.a),
26 1.0 - reflection.r).rgb,
27 1.0);
28 // #fogCode
29 gl_FragColor = outColor;
30 }
31
OLDNEW
« no previous file with comments | « conformance/shaders/misc/shared-a.frag ('k') | conformance/shaders/reserved/00_shaders.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698