summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2012-06-04 10:20:36 -0700
committerIan Romanick <[email protected]>2012-06-13 18:26:11 -0700
commit4bfdc8313592ec8a8794d6b7bc33a5c44df34ed4 (patch)
tree9051f4d2afd6293fa42c14db788a75e232f423cf
parentf18d3fe0cb459e5370625057024b84edbadfb097 (diff)
glsl: Fix pi/2 constant in acos built-in function
In single precision, 1.5707963 becomes 1.5707962513 which is too small. However, 1.5707964 becomes 1.5707963705 which is just right. The value 1.5707964 is already used in asin.ir. NOTE: This is a candidate for stable release branches. Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Olivier Galibert <[email protected]> Reviewed-by: Paul Berry <[email protected]>
-rw-r--r--src/glsl/builtins/ir/acos.ir8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/glsl/builtins/ir/acos.ir b/src/glsl/builtins/ir/acos.ir
index f0078f884e7..8c3797e9677 100644
--- a/src/glsl/builtins/ir/acos.ir
+++ b/src/glsl/builtins/ir/acos.ir
@@ -4,26 +4,26 @@
(declare (in) float x))
((declare () float s)
(call asin (var_ref s) ((var_ref x)))
- (return (expression float - (constant float (1.5707963)) (var_ref s)))))
+ (return (expression float - (constant float (1.5707964)) (var_ref s)))))
(signature vec2
(parameters
(declare (in) vec2 x))
((declare () vec2 s)
(call asin (var_ref s) ((var_ref x)))
- (return (expression vec2 - (constant float (1.5707963)) (var_ref s)))))
+ (return (expression vec2 - (constant float (1.5707964)) (var_ref s)))))
(signature vec3
(parameters
(declare (in) vec3 x))
((declare () vec3 s)
(call asin (var_ref s) ((var_ref x)))
- (return (expression vec3 - (constant float (1.5707963)) (var_ref s)))))
+ (return (expression vec3 - (constant float (1.5707964)) (var_ref s)))))
(signature vec4
(parameters
(declare (in) vec4 x))
((declare () vec4 s)
(call asin (var_ref s) ((var_ref x)))
- (return (expression vec4 - (constant float (1.5707963)) (var_ref s)))))
+ (return (expression vec4 - (constant float (1.5707964)) (var_ref s)))))
))