summaryrefslogtreecommitdiff
path: root/src/glsl/builtins/110_fs
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2010-08-11 16:53:52 -0700
committerIan Romanick <ian.d.romanick@intel.com>2010-08-13 19:09:36 -0700
commit43ff8f1a4b90554eae489cebb7e05f983dd9ad66 (patch)
treed9a63bb1ce1257b45aea4bbcae450959b75cc64c /src/glsl/builtins/110_fs
parentd802ba110f78c3eee9541867cde819ada1b2c449 (diff)
glsl2: Rework builtin function generation.
Each language version/extension and target now has a "profile" containing all of the available builtin function prototypes. These are written in GLSL, and come directly out of the GLSL spec (except for expanding genType). A new builtins/ir/ folder contains the hand-written IR for each builtin, regardless of what version includes it. Only those definitions that have prototypes in the profile will be included. The autogenerated IR for texture builtins is no longer written to disk, so there's no longer any confusion as to what's hand-written or generated. All scripts are now in python instead of perl.
Diffstat (limited to 'src/glsl/builtins/110_fs')
-rw-r--r--src/glsl/builtins/110_fs/derivatives73
-rw-r--r--src/glsl/builtins/110_fs/textures113
2 files changed, 0 insertions, 186 deletions
diff --git a/src/glsl/builtins/110_fs/derivatives b/src/glsl/builtins/110_fs/derivatives
deleted file mode 100644
index b79852ee1f..0000000000
--- a/src/glsl/builtins/110_fs/derivatives
+++ /dev/null
@@ -1,73 +0,0 @@
-((function dFdx
- (signature float
- (parameters
- (declare (in) float p))
- ((return (expression float dFdx (var_ref p)))))
-
- (signature vec2
- (parameters
- (declare (in) vec2 p))
- ((return (expression vec2 dFdx (var_ref p)))))
-
- (signature vec3
- (parameters
- (declare (in) vec3 p))
- ((return (expression vec3 dFdx (var_ref p)))))
-
- (signature vec4
- (parameters
- (declare (in) vec4 p))
- ((return (expression vec4 dFdx (var_ref p)))))
- )
-
- (function dFdy
- (signature float
- (parameters
- (declare (in) float p))
- ((return (expression float dFdy (var_ref p)))))
-
- (signature vec2
- (parameters
- (declare (in) vec2 p))
- ((return (expression vec2 dFdy (var_ref p)))))
-
- (signature vec3
- (parameters
- (declare (in) vec3 p))
- ((return (expression vec3 dFdy (var_ref p)))))
-
- (signature vec4
- (parameters
- (declare (in) vec4 p))
- ((return (expression vec4 dFdy (var_ref p)))))
- )
-
- (function fwidth
- (signature float
- (parameters
- (declare (in) float p))
- ((return (expression float +
- (expression float abs (expression float dFdx (var_ref p)))
- (expression float abs (expression float dFdy (var_ref p)))))))
-
- (signature vec2
- (parameters
- (declare (in) vec2 p))
- ((return (expression vec2 +
- (expression vec2 abs (expression vec2 dFdx (var_ref p)))
- (expression vec2 abs (expression vec2 dFdy (var_ref p)))))))
-
- (signature vec3
- (parameters
- (declare (in) vec3 p))
- ((return (expression vec3 +
- (expression vec3 abs (expression vec3 dFdx (var_ref p)))
- (expression vec3 abs (expression vec3 dFdy (var_ref p)))))))
-
- (signature vec4
- (parameters
- (declare (in) vec4 p))
- ((return (expression vec4 +
- (expression vec4 abs (expression vec4 dFdx (var_ref p)))
- (expression vec4 abs (expression vec4 dFdy (var_ref p)))))))
-))
diff --git a/src/glsl/builtins/110_fs/textures b/src/glsl/builtins/110_fs/textures
deleted file mode 100644
index 38f3787e9e..0000000000
--- a/src/glsl/builtins/110_fs/textures
+++ /dev/null
@@ -1,113 +0,0 @@
-((function texture1D
- (signature vec4
- (parameters
- (declare (in) sampler1D sampler)
- (declare (in) float P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))
-
-)
- (function texture1DProj
- (signature vec4
- (parameters
- (declare (in) sampler1D sampler)
- (declare (in) vec2 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref bias) ))))
-
- (signature vec4
- (parameters
- (declare (in) sampler1D sampler)
- (declare (in) vec4 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))
-
-)
- (function texture2D
- (signature vec4
- (parameters
- (declare (in) sampler2D sampler)
- (declare (in) vec2 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))
-
-)
- (function texture2DProj
- (signature vec4
- (parameters
- (declare (in) sampler2D sampler)
- (declare (in) vec3 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref bias) ))))
-
- (signature vec4
- (parameters
- (declare (in) sampler2D sampler)
- (declare (in) vec4 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))
-
-)
- (function texture3D
- (signature vec4
- (parameters
- (declare (in) sampler3D sampler)
- (declare (in) vec3 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))
-
-)
- (function texture3DProj
- (signature vec4
- (parameters
- (declare (in) sampler3D sampler)
- (declare (in) vec4 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))
-
-)
- (function textureCube
- (signature vec4
- (parameters
- (declare (in) samplerCube sampler)
- (declare (in) vec3 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))
-
-)
- (function shadow1D
- (signature vec4
- (parameters
- (declare (in) sampler1DShadow sampler)
- (declare (in) vec3 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref bias) ))))
-
-)
- (function shadow1DProj
- (signature vec4
- (parameters
- (declare (in) sampler1DShadow sampler)
- (declare (in) vec4 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))
-
-)
- (function shadow2D
- (signature vec4
- (parameters
- (declare (in) sampler2DShadow sampler)
- (declare (in) vec3 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref bias) ))))
-
-)
- (function shadow2DProj
- (signature vec4
- (parameters
- (declare (in) sampler2DShadow sampler)
- (declare (in) vec4 P)
- (declare (in) float bias) )
- ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))
-
-))