summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/glsl/builtin_function.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/glsl/builtin_function.cpp b/src/glsl/builtin_function.cpp
index cf0a2a3f829..bc368141053 100644
--- a/src/glsl/builtin_function.cpp
+++ b/src/glsl/builtin_function.cpp
@@ -714,9 +714,11 @@ static const char builtin_cross[] =
"((function cross\n"
" (signature vec3\n"
" (parameters\n"
- " (declare (in) vec3 arg0)\n"
- " (declare (in) vec3 arg1))\n"
- " ((return (expression vec3 cross (var_ref arg0) (var_ref arg1)))))\n"
+ " (declare (in) vec3 a)\n"
+ " (declare (in) vec3 b))\n"
+ " ((return (expression vec3 -\n"
+ " (expression vec3 * (swiz yzx (var_ref a)) (swiz zxy (var_ref b)))\n"
+ " (expression vec3 * (swiz zxy (var_ref a)) (swiz yzx (var_ref b)))))))\n"
"))\n"
""
;