diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
commit | 36d22d82aa202bb199967e9512281e9a53db42c9 (patch) | |
tree | 105e8c98ddea1c1e4784a60a5a6410fa416be2de /dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2 | |
parent | Initial commit. (diff) | |
download | firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip |
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2')
27 files changed, 665 insertions, 0 deletions
diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_001_to_008.html b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_001_to_008.html new file mode 100644 index 0000000000..0c4be1d366 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_001_to_008.html @@ -0,0 +1,135 @@ +<!DOCTYPE html> +<!-- this file is auto-generated. DO NOT EDIT. --> +<!-- +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +--> +<html> +<head> +<meta charset="utf-8"> +<title>WebGL GLSL conformance test: exp2_001_to_008.html</title> +<link rel="stylesheet" href="../../../../resources/js-test-style.css" /> +<link rel="stylesheet" href="../../../../resources/ogles-tests.css" /> +<script src="../../../../js/js-test-pre.js"></script> +<script src="../../../../js/webgl-test-utils.js"></script> +<script src="../../ogles-utils.js"></script> +</head> +<body> +<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas> +<div id="description"></div> +<div id="console"></div> +</body> +<script> +"use strict"; +OpenGLESTestRunner.run({ + "tests": [ + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_float_frag_xvary_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_float_frag_xvary.frag" + }, + "name": "exp2_float_frag_xvary.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec2_frag_xvary_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec2_frag_xvary.frag" + }, + "name": "exp2_vec2_frag_xvary.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec3_frag_xvary_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec3_frag_xvary.frag" + }, + "name": "exp2_vec3_frag_xvary.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_float_frag_xvaryneg_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_float_frag_xvaryneg.frag" + }, + "name": "exp2_float_frag_xvaryneg.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec2_frag_xvaryneg_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec2_frag_xvaryneg.frag" + }, + "name": "exp2_vec2_frag_xvaryneg.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec3_frag_xvaryneg_ref.frag" + }, + "model": null, + "testProgram": { + "vertexShader": "../default/default.vert", + "fragmentShader": "exp2_vec3_frag_xvaryneg.frag" + }, + "name": "exp2_vec3_frag_xvaryneg.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "exp2_float_vert_xvary_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_float_vert_xvary.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_float_vert_xvary.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "exp2_vec2_vert_xvary_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_vec2_vert_xvary.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_vec2_vert_xvary.test.html", + "pattern": "compare" + } + ] +}); +var successfullyParsed = true; +</script> +</html> diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_009_to_012.html b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_009_to_012.html new file mode 100644 index 0000000000..331710c39c --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_009_to_012.html @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<!-- this file is auto-generated. DO NOT EDIT. --> +<!-- +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +--> +<html> +<head> +<meta charset="utf-8"> +<title>WebGL GLSL conformance test: exp2_009_to_012.html</title> +<link rel="stylesheet" href="../../../../resources/js-test-style.css" /> +<link rel="stylesheet" href="../../../../resources/ogles-tests.css" /> +<script src="../../../../js/js-test-pre.js"></script> +<script src="../../../../js/webgl-test-utils.js"></script> +<script src="../../ogles-utils.js"></script> +</head> +<body> +<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas> +<div id="description"></div> +<div id="console"></div> +</body> +<script> +"use strict"; +OpenGLESTestRunner.run({ + "tests": [ + { + "referenceProgram": { + "vertexShader": "exp2_vec3_vert_xvary_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_vec3_vert_xvary.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_vec3_vert_xvary.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "exp2_float_vert_xvaryneg_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_float_vert_xvaryneg.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_float_vert_xvaryneg.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "exp2_vec2_vert_xvaryneg_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_vec2_vert_xvaryneg.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_vec2_vert_xvaryneg.test.html", + "pattern": "compare" + }, + { + "referenceProgram": { + "vertexShader": "exp2_vec3_vert_xvaryneg_ref.vert", + "fragmentShader": "../default/default.frag" + }, + "model": "grid", + "testProgram": { + "vertexShader": "exp2_vec3_vert_xvaryneg.vert", + "fragmentShader": "../default/default.frag" + }, + "name": "exp2_vec3_vert_xvaryneg.test.html", + "pattern": "compare" + } + ] +}); +var successfullyParsed = true; +</script> +</html> diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary.frag new file mode 100644 index 0000000000..c3e2d04a6a --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + float c = color.r; + gl_FragColor = vec4(exp2(5.0 * c) / 32.0, 0.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary_ref.frag new file mode 100644 index 0000000000..cdad89f953 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvary_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + float c = color.r; + gl_FragColor = vec4(pow(2.0, 5.0 * c) / 32.0, 0.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg.frag new file mode 100644 index 0000000000..8d285849aa --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + float c = -color.r; + gl_FragColor = vec4(exp2(5.0 * c), 0.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg_ref.frag new file mode 100644 index 0000000000..efad77cddb --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_frag_xvaryneg_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + float c = color.r; + gl_FragColor = vec4(1.0 / pow(2.0, 5.0 * c), 0.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary.vert new file mode 100644 index 0000000000..393a4f42e6 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + float c = gtf_Color.r; + color = vec4(exp2(5.0 * c) / 32.0, 0.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary_ref.vert new file mode 100644 index 0000000000..3a95dc1a14 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvary_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + float c = gtf_Color.r; + color = vec4(pow(2.0, 5.0 * c) / 32.0, 0.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg.vert new file mode 100644 index 0000000000..5e3ce879ca --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + float c = -gtf_Color.r; + color = vec4(exp2(5.0 * c), 0.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg_ref.vert new file mode 100644 index 0000000000..4303b64954 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_float_vert_xvaryneg_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + float c = gtf_Color.r; + color = vec4(1.0 / pow(2.0, 5.0 * c), 0.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary.frag new file mode 100644 index 0000000000..436c856de2 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec2 c = color.rg; + gl_FragColor = vec4(exp2(5.0 * c) / 32.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary_ref.frag new file mode 100644 index 0000000000..58fc9b2a11 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvary_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec2 c = color.rg; + gl_FragColor = vec4(pow(vec2(2.0), 5.0 * c) / 32.0, 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg.frag new file mode 100644 index 0000000000..d3112c7991 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec2 c = -color.rg; + gl_FragColor = vec4(exp2(5.0 * c), 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg_ref.frag new file mode 100644 index 0000000000..ca1a4e2424 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_frag_xvaryneg_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec2 c = color.rg; + gl_FragColor = vec4(1.0 / pow(vec2(2.0), 5.0 * c), 0.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary.vert new file mode 100644 index 0000000000..dffd2f6b8a --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec2 c = gtf_Color.rg; + color = vec4(exp2(5.0 * c) / 32.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary_ref.vert new file mode 100644 index 0000000000..f9ae9fa180 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvary_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec2 c = gtf_Color.rg; + color = vec4(pow(vec2(2.0), 5.0 * c) / 32.0, 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg.vert new file mode 100644 index 0000000000..5b46f97f82 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec2 c = -gtf_Color.rg; + color = vec4(exp2(5.0 * c), 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg_ref.vert new file mode 100644 index 0000000000..15a19d450f --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec2_vert_xvaryneg_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec2 c = gtf_Color.rg; + color = vec4(1.0 / pow(vec2(2.0), 5.0 * c), 0.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary.frag new file mode 100644 index 0000000000..bbe41d3002 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec3 c = color.rgb; + gl_FragColor = vec4(exp2(5.0 * c) / 32.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary_ref.frag new file mode 100644 index 0000000000..51719fc226 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvary_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec3 c = color.rgb; + gl_FragColor = vec4(pow(vec3(2.0), 5.0 * c) / 32.0, 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg.frag new file mode 100644 index 0000000000..6f799874ce --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec3 c = -color.rgb; + gl_FragColor = vec4(exp2(5.0 * c), 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg_ref.frag b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg_ref.frag new file mode 100644 index 0000000000..b7807d4c6b --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_frag_xvaryneg_ref.frag @@ -0,0 +1,18 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +#ifdef GL_ES +precision mediump float; +#endif +varying vec4 color; + +void main (void) +{ + vec3 c = color.rgb; + gl_FragColor = vec4(1.0 / pow(vec3(2.0), 5.0 * c), 1.0); +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary.vert new file mode 100644 index 0000000000..ace9f91be0 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec3 c = gtf_Color.rgb; + color = vec4(exp2(5.0 * c) / 32.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary_ref.vert new file mode 100644 index 0000000000..020a56e708 --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvary_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec3 c = gtf_Color.rgb; + color = vec4(pow(vec3(2.0), 5.0 * c) / 32.0, 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg.vert new file mode 100644 index 0000000000..708cd0494c --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec3 c = -gtf_Color.rgb; + color = vec4(exp2(5.0 * c), 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg_ref.vert b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg_ref.vert new file mode 100644 index 0000000000..3a0238f59c --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/exp2_vec3_vert_xvaryneg_ref.vert @@ -0,0 +1,19 @@ + +/* +Copyright (c) 2019 The Khronos Group Inc. +Use of this source code is governed by an MIT-style license that can be +found in the LICENSE.txt file. +*/ + + +attribute vec4 gtf_Color; +attribute vec4 gtf_Vertex; +uniform mat4 gtf_ModelViewProjectionMatrix; +varying vec4 color; + +void main (void) +{ + vec3 c = gtf_Color.rgb; + color = vec4(1.0 / pow(vec3(2.0), 5.0 * c), 1.0); + gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex; +} diff --git a/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/input.run.txt b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/input.run.txt new file mode 100644 index 0000000000..f893cd413e --- /dev/null +++ b/dom/canvas/test/webgl-conf/checkout/conformance/ogles/GL/exp2/input.run.txt @@ -0,0 +1,3 @@ +# this file is auto-generated. DO NOT EDIT. +exp2_001_to_008.html +exp2_009_to_012.html |