Skip to content

Commit adaab4d

Browse files
committed
Add vector clipping.
1 parent 9ffdd8b commit adaab4d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

include/fixed_point/inline/vector.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,11 @@ MAKE_VEC_SCALAR_F(dv_shiftl, dvec3, int8_t, df_shiftl)
9595
*/
9696
MAKE_VEC_SCALAR_F(dv_shiftr, dvec3, int8_t, df_shiftr)
9797

98+
/**
99+
* Clip components between -b and b.
100+
*/
101+
MAKE_VEC_SCALAR_F(v_clip, vec3, frac, f_clip)
102+
98103
/**
99104
* Multiply single precicion vector by integer, yield extended precision vector.
100105
*/

0 commit comments

Comments
 (0)