diff options
Diffstat (limited to 'src/glsl')
-rw-r--r-- | src/glsl/builtin_function.cpp | 120 |
1 files changed, 120 insertions, 0 deletions
diff --git a/src/glsl/builtin_function.cpp b/src/glsl/builtin_function.cpp index 490210cf9c9..f65f91f6b79 100644 --- a/src/glsl/builtin_function.cpp +++ b/src/glsl/builtin_function.cpp @@ -2550,6 +2550,54 @@ static const char *builtin_refract = "))\n" "" ; +static const char *builtin_round = + "((function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float arg0))\n" + " ((return (expression float round_even (var_ref arg0)))))\n" + "\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 arg0))\n" + " ((return (expression vec2 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 arg0))\n" + " ((return (expression vec3 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 arg0))\n" + " ((return (expression vec4 round_even (var_ref arg0)))))\n" + "))\n" + "" +; +static const char *builtin_roundEven = + "((function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float arg0))\n" + " ((return (expression float round_even (var_ref arg0)))))\n" + "\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 arg0))\n" + " ((return (expression vec2 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 arg0))\n" + " ((return (expression vec3 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 arg0))\n" + " ((return (expression vec4 round_even (var_ref arg0)))))\n" + "))\n" + "" +; static const char *builtin_shadow1D = "((function shadow1D\n" " (signature vec4\n" @@ -13267,6 +13315,40 @@ static const char *prototypes_for_130_frag = " (parameters\n" " (declare (in) vec4 x))\n" " ()))\n" + "(function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" "(function ceil\n" " (signature float\n" " (parameters\n" @@ -15876,6 +15958,8 @@ static const char *functions_for_130_frag [] = { builtin_radians, builtin_reflect, builtin_refract, + builtin_round, + builtin_roundEven, builtin_shadow1D, builtin_shadow1DLod, builtin_shadow1DProj, @@ -16348,6 +16432,40 @@ static const char *prototypes_for_130_vert = " (parameters\n" " (declare (in) vec4 x))\n" " ()))\n" + "(function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" "(function ceil\n" " (signature float\n" " (parameters\n" @@ -18908,6 +19026,8 @@ static const char *functions_for_130_vert [] = { builtin_radians, builtin_reflect, builtin_refract, + builtin_round, + builtin_roundEven, builtin_shadow1D, builtin_shadow1DLod, builtin_shadow1DProj, |