projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aeee683
)
compiler/spirv: handle 16-bit float in radians() and degrees()
author
Iago Toral Quiroga
<itoral@igalia.com>
Tue, 17 Apr 2018 09:39:48 +0000
(11:39 +0200)
committer
Iago Toral Quiroga
<itoral@igalia.com>
Wed, 2 Jan 2019 06:54:05 +0000
(07:54 +0100)
v2:
- use nir_imm_fmul helper (Jason)
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/nir/nir_builtin_builder.h
patch
|
blob
|
history
diff --git
a/src/compiler/nir/nir_builtin_builder.h
b/src/compiler/nir/nir_builtin_builder.h
index 0e5b9db462a38d572c0e78d39066aa9fe9a7b362..d1435b37fd43f2ce1452fd4da7fb2932d6fe3d9d 100644
(file)
--- a/
src/compiler/nir/nir_builtin_builder.h
+++ b/
src/compiler/nir/nir_builtin_builder.h
@@
-60,7
+60,7
@@
nir_uclamp(nir_builder *b,
static inline nir_ssa_def *
nir_degrees(nir_builder *b, nir_ssa_def *val)
{
- return nir_fmul
(b, val, nir_imm_float(b, 57.2957795131)
);
+ return nir_fmul
_imm(b, val, 57.2957795131
);
}
static inline nir_ssa_def *
@@
-78,7
+78,7
@@
nir_fast_normalize(nir_builder *b, nir_ssa_def *vec)
static inline nir_ssa_def *
nir_radians(nir_builder *b, nir_ssa_def *val)
{
- return nir_fmul
(b, val, nir_imm_float(b, 0.01745329251)
);
+ return nir_fmul
_imm(b, val, 0.01745329251
);
}
#endif /* NIR_BUILTIN_BUILDER_H */