Closed 5-23 closed 3 weeks ago
Can you please provide a text description for this and update the tests to include the problem you are fixing
Can you please provide a text description for this and update the tests to include the problem you are fixing
This code eliminates the error that occurs when the length of vec2 is smaller than the minimum value of f32.
While playing with bevy_xpbd, an error occurred, so I searched for it and estimated the cause.
it would help if you can provide a working repro, in text, not an image. so by that I mean a vec2 which is normalized but fails the current is_normalized
check
I don't really think this change makes sense, at least it is inefficient because the code now calculates length_squared twice, adds an if statement and it makes the check potentially too narrow, but I would like to better understand the problem you are trying to fix.
Closing this, if you can provide some example code showing how is_normalized is doing something unexpected please open an issue.
Error correction of this way