diff options
author | Brian <brian@yutani.localnet.net> | 2007-02-03 17:21:33 -0700 |
---|---|---|
committer | Brian <brian@yutani.localnet.net> | 2007-02-03 17:21:33 -0700 |
commit | 5ee684cba9b1f63090e184125e5890da4fc1d28c (patch) | |
tree | 15c365454fd350fa20ba1140a95753af2ccd2ad0 /src/mesa/shader/slang/library/slang_common_builtin.gc | |
parent | 82f53f45d96871cdaba3886275be78162ef838f5 (diff) |
minor tweaks to distance() funcs
Diffstat (limited to 'src/mesa/shader/slang/library/slang_common_builtin.gc')
-rw-r--r-- | src/mesa/shader/slang/library/slang_common_builtin.gc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/mesa/shader/slang/library/slang_common_builtin.gc b/src/mesa/shader/slang/library/slang_common_builtin.gc index 5a25bbc30b..c8931d259e 100644 --- a/src/mesa/shader/slang/library/slang_common_builtin.gc +++ b/src/mesa/shader/slang/library/slang_common_builtin.gc @@ -1175,25 +1175,25 @@ float length(const vec4 v) float distance(const float x, const float y) { const float d = x - y; - return length(d); + __retVal = length(d); } float distance(const vec2 v, const vec2 u) { - const vec2 d = v - u; - return length(d); + const vec2 d2 = v - u; + __retVal = length(d2); } float distance(const vec3 v, const vec3 u) { - const vec3 d = v - u; - return length(d); + const vec3 d3 = v - u; + __retVal = length(d3); } float distance(const vec4 v, const vec4 u) { - const vec4 d = v - u; - return length(d); + const vec4 d4 = v - u; + __retVal = length(d4); } |