Command line tool for finding the bounding box of an STL file
Hi does any one know of a command line tool in OpenFOAM or elsewhere that can print out the bounding box of an STL file's objects ?
I need to scale and offset an STL file that is input from a web based interface prior to creating a mesh with snappyHexMesh. Cheers Terry |
I can not provide you with a c
I can not provide you with a command line tool, but such a task should easily be managable with vtk, www.vtk.org. It provides all you need.
m* |
If the STL is ascii, do it you
If the STL is ascii, do it yourself! STL format is really trivial...
|
Hi,
you can use admesh tool
Hi,
you can use admesh tool to find out the bounding box of an STL file's object. It's a nice opensource code that you can download from the web. It is also really useful for a lot of other things like holes corrections, face normal reversing... I think it's worth trying.. let me know :-)! Regards Norman |
Load it with paraview and chec
Load it with paraview and check the statics.
It tells you the bounding box dimensions and the offset respect to the wcs! |
Thanks for all the replies.
T
Thanks for all the replies.
The admesh utility seems to do the job for me as I need a non-interactive solution for a web based interface and I have binary STL files. However I may need to move to using ASCII files as I was going to try using the new snappyHexMesh tool and the binary STL files generated by Blender do not work with it correctly. |
You could also use the surface
You could also use the surfaceCheck utility and parse its output?
It provides not only bounding box info, but also list how many different solid groups there are. |
bounding box
checkMesh | grep -i 'bounding box'
|
Bounding Box
type: surfaceCheck yourFigure.vtk | grep -i 'bounding box'
|
All times are GMT -4. The time now is 00:14. |