Build perpendicular vector
Is your feature request related to a problem? Please describe. Vector element should have a way already defined of build a perpendicular vector to it.
Describe the solution you'd like A proposed snippet is provided
private static Vector3 perpendicularVector(Vector3 v, bool IsClockWise) {
var angle = IsClockWise ? 90 : 270;
var t = new Transform(new Vector3(0,0,0), angle);
return t.OfVector(v);
}
Describe alternatives you've considered The vector built could have a dimension of 1 but it's not necessary, there's already a function for that.
Additional context It's a useful function that could be always available
I would argue for consistency's sake this should generally be done with a cross product rather than thought of rotationally?
For that we would need two vectors, which one are you thinking as the second one? (0,0,0)?
I think I'm going to close this because to @andrewheumann's point, this should be done with cross products and there are an infinite number of perpendicular vectors to a vector. It requires the user to know what they want to do in a given situation.