clamp_magnitude no longer outputs input x,y regardless of checks
parent
1df623e669
commit
494dbfedb3
|
@ -10,9 +10,10 @@ void clamp_magnitude(float* xx, float* yy, float max_magnitude) {
|
|||
if(m > max_magnitude) {
|
||||
x /= m; y /= m;
|
||||
x *= max_magnitude; y *= max_magnitude;
|
||||
}
|
||||
} else {
|
||||
*xx = x; *yy = y;
|
||||
}
|
||||
}
|
||||
|
||||
static inline
|
||||
void normalize(float* xx, float* yy) {
|
||||
|
|
Loading…
Reference in New Issue