Overview
Clamps the values to an upper and a lower bound.
Dispatcher Prototype
void volk_32f_s32f_x2_clamp_32f(float* out,
const float* in,
const float min,
const float max,
unsigned int num_points)
Inputs
- in: Pointer to float values.
- min: Minimum value to clamp to.
- max: Maximum value to clamp to.
- num_points: The number of points in the vector.
Outputs
- out: Pointer to output values.
Example
float x[4] = {-2.f, -1.f, 1.f, 2.f};
float y[4];
volk_32f_s32f_x2_clamp_32f(y, x, -1.5f, 1.5f, 4);