Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Optimized Oriented Bounding Box (OOBB) #37

Open
TZwielehner opened this issue Jul 15, 2022 · 6 comments
Open

Feature Request: Optimized Oriented Bounding Box (OOBB) #37

TZwielehner opened this issue Jul 15, 2022 · 6 comments

Comments

@TZwielehner
Copy link

TZwielehner commented Jul 15, 2022

For analyzing topologies (cells in particular) I would need to calculate OOBB cells. Two versions would be great:
A) smallest BB (oriented freely in 3D space):
image

B) Z-axis is fixed:
image

1, 2, 3 being Width, Depth, Height of the resulting bounding box.

@wassimj
Copy link
Owner

wassimj commented Jul 21, 2022

Hi. Apologies for the delay in responding to your suggestion. I was on annual leave. This can be achieved through the Evolver node in Blender. In fact, their demo is exactly this issue: to find the smallest enclosing bounding box. Please take a look at:
https://nortikin.github.io/sverchok/docs/nodes/logic/evolver.html

@TZwielehner
Copy link
Author

Thank you! I thought there was maybe an analytical way to calculate it, I did not consider a numerical solution. Will have a look into that.

@wassimj
Copy link
Owner

wassimj commented Jul 21, 2022

Thank you! I thought there was maybe an analytical way to calculate it, I did not consider a numerical solution. Will have a look into that.

There may be an analytical way, but I don’t know it. If you find anything that can avoid using a GA, please let me know. I will see if I can add it.

@wassimj
Copy link
Owner

wassimj commented Jul 22, 2022

I found this implementation in Matlab. If you can convert the code to python, I would be happy to integrate it with Topologic:

https://github.com/chadogome/OptimalOBB

@TZwielehner
Copy link
Author

Still beyond my coding skill I'm afraid. I'll see if I can get my head around the example you provided.

@wassimj
Copy link
Owner

wassimj commented Oct 9, 2022

Dear @TZwielehner,
Apologies for the extensive delay in addressing this. I am glad to let you know that Optimized Oriented Bounding Box (OOBB) is now implemented in Topologic using the library pyobb (https://github.com/pboechat/pyobb). If possible, I kindly would like you to test it before I released it publicly. Please contact me at jabiw@cardiff.ac.uk to arrange access. Thank you.
oobb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants