mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-18 17:40:26 +01:00
isl: Use CLAMP macro instead of MIN of MAX
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12177>
This commit is contained in:
parent
72259a870f
commit
9dfe7fbc6b
1 changed files with 2 additions and 2 deletions
|
|
@ -1191,8 +1191,8 @@ pack_channel(const union isl_color_value *value, unsigned i,
|
|||
packed = MIN(value->u32[i], u_uintN_max(layout->bits));
|
||||
break;
|
||||
case ISL_SINT:
|
||||
packed = MIN(MAX(value->u32[i], u_intN_min(layout->bits)),
|
||||
u_intN_max(layout->bits));
|
||||
packed = CLAMP(value->u32[i], u_intN_min(layout->bits),
|
||||
u_intN_max(layout->bits));
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue