projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
918ef7f
)
glsl: fix atan(0, -1)
author
Brian Paul
<brianp@vmware.com>
Thu, 5 Aug 2010 22:38:22 +0000
(16:38 -0600)
committer
Brian Paul
<brianp@vmware.com>
Thu, 5 Aug 2010 22:39:09 +0000
(16:39 -0600)
Fixes fd.o bug 29388
NOTE: this is a candidate for the 7.8 branch.
src/mesa/slang/library/slang_common_builtin.gc
patch
|
blob
|
history
diff --git
a/src/mesa/slang/library/slang_common_builtin.gc
b/src/mesa/slang/library/slang_common_builtin.gc
index d75354deffe71909da2bc2482dfd535d5fff2043..1f5ddbc1ee272a20a34ba0def1c9db461b45167d 100644
(file)
--- a/
src/mesa/slang/library/slang_common_builtin.gc
+++ b/
src/mesa/slang/library/slang_common_builtin.gc
@@
-411,7
+411,7
@@
float atan(const float y, const float x)
if (abs(x) > 1.0e-4) {
r = atan(y / x);
if (x < 0.0) {
- r = r +
sign(y) * 3.141593
;
+ r = r +
3.141593 - 6.283186 * float(y < 0.0)
;
}
}
else {