Created a "how to" video for this, you can find it bsky.app/profile/euri...
Euri Herasme
The "proper" way to generate an oobb from a set of points is to compute a covariance matrix, its eigenvalues, and eigenvectors, and so on. I thought of a naive / brute-force approach that gives good results and is much simpler to implement.