diff options
author | Eric Anholt <[email protected]> | 2010-07-01 10:37:11 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2010-07-01 11:07:22 -0700 |
commit | d925c9173009e9e5d48df30b30aaef22753183aa (patch) | |
tree | e42ee590b44d75b69fb67ee7de8b42ce05ee1c11 /src/glsl/builtins | |
parent | 5e4dd061d17563828bcce5525400a0ce363aa15d (diff) |
glsl2: Add ir_unop_fract as an expression type.
Most backends will prefer seeing this to seeing (a - floor(a)), so
represent it explicitly.
Diffstat (limited to 'src/glsl/builtins')
-rw-r--r-- | src/glsl/builtins/110/fract | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/glsl/builtins/110/fract b/src/glsl/builtins/110/fract index 46741bb3cb4..3f0763d1b3e 100644 --- a/src/glsl/builtins/110/fract +++ b/src/glsl/builtins/110/fract @@ -2,21 +2,21 @@ (signature float (parameters (declare (in) float x)) - ((return (expression float - (var_ref x) (expression float floor (var_ref x)))))) + ((return (expression float fract (var_ref x))))) (signature vec2 (parameters (declare (in) vec2 x)) - ((return (expression vec2 - (var_ref x) (expression vec2 floor (var_ref x)))))) + ((return (expression vec2 fract (var_ref x))))) (signature vec3 (parameters (declare (in) vec3 x)) - ((return (expression vec3 - (var_ref x) (expression vec3 floor (var_ref x)))))) + ((return (expression vec3 fract (var_ref x))))) (signature vec4 (parameters (declare (in) vec4 x)) - ((return (expression vec4 - (var_ref x) (expression vec4 floor (var_ref x)))))) + ((return (expression vec4 fract (var_ref x))))) )) |