You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
These methods are quite useful whenever you have to make sure that a value stays inside a specified range. Although there is f32::clamp and f64::clamp these are not stabilized yet so it would be nice to have them inside cgmath.
Just wanted to point out fXX::clamp is stable since Rust version 1.50.0. It would be nice to have it for the common use case of clamping the pitch angle of a camera (uhm, my current use case).
These methods are quite useful whenever you have to make sure that a value stays inside a specified range. Although there is
f32::clamp
andf64::clamp
these are not stabilized yet so it would be nice to have them insidecgmath
.wraparound
should have a signature like this:See also https://stackoverflow.com/questions/4633177/c-how-to-wrap-a-float-to-the-interval-pi-pi#
The text was updated successfully, but these errors were encountered: