BB(nged)

Report dimensional information about objects using Bounding Boxes

πŸ“… published 7.44.0, from nixpkgs unstable

πŸ’… BB(nged) β€” the bounding box bestie

okay so real talk, this is bb from the nged manual β€” that's BRL-CAD User Commands, for the uninitiated ✨. She's the one you call when you need to know how big a thing actually is, and honestly? She ate.


🌸 NAME 🌸

bb β€” reports dimensional information about objects using Bounding Boxes πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

bb [-c] [-q] [-v] object1 [object2 object3 ...]

πŸ’– DESCRIPTION πŸ’–

So bb calculates a bounding box for an object (or a whole lil squad of objects) that you pass as arguments, and then it reports info about the bounding box dimensions right at the MGED command prompt. She supports a bunch of options, and most of them just control what kind of info gets reported. She can also optionally create an ARB8 in a database that matches the bounding box of your object(s). By default it's an axis-aligned bounding box (AABB), but bestie, support for an oriented bounding box (OBB) is available too πŸ‘‘

The objects list is literally just one or more geometry objects in the current database. That's it. That's the vibe.


✨ OPTIONS ✨

  • -c bbox_object_name.s β€” Creates an ARB8 primitive in the current database with the dimensions of the bounding box of the object(s) you listed. Slay πŸ’…
  • -d β€” Reports dimensional information (length, width and height). This one's on by default, she's just always there 🫢
  • -e β€” Reports the extent of the bounding box using the min and max 3D points of the bounding box.
  • -m β€” Reports the midpoint / center (x y z) of the bounding box.
  • -o β€” Calculates an oriented bounding box instead of an axis aligned bounding box. This will produce tighter bounding volumes if the geometry is not symmetric to the XYZ grid πŸ”₯. Uses the algorithms and code from Barequet and Har-Peled β€” see the papers Efficiently Approximating the Minimum-Volume Bounding Box of a Point Set in Three Dimensions (http://valis.cs.uiuc.edu/~sariel/papers/98/bbox.html) (SODA 99) and A Practical Approach for Computing the Diameter of a Point-Set (http://valis.cs.uiuc.edu/~sariel/research/papers/00/diam.html) for details. iykyk πŸ“š
  • -q β€” Quiet mode, aka disable printing of the header, which is on by default. Super useful when you're processing output from bb. Lowkey essential ngl πŸ™ˆ
  • -u β€” Ignore air volumes when calculating the bounding box. Air? not invited to this party πŸ’€
  • -v β€” Print the volume of the bounding box. On by default, main character behavior.

🌈 EXAMPLES 🌈

Example 1 β€” determine the size of the bounding box for a Havoc helicopter 🚁

mged> bb havoc
Bounding Box Dimensions, Object(s) havoc:
X Length: 1988.4 cm
Y Length: 1683.6 cm
Z Length: 625.0 cm
Bounding Box Volume: 2092246392.4 cm^3

Example 2 β€” report only the min and max points of a bounding box

mged> bb -q -e havoc
min {-759.447479 -8437.866455 -890.000000} max {19124.621094 8397.693207 5360.000000}

Example 3 β€” bounding box for multiple components 🧩

mged> bb havoc_front havoc_middle havoc_tail
Bounding Box Dimensions, Object(s) havoc_front,  havoc_middle,  havoc_tail:
X Length: 1775.9 cm
Y Length: 358.0 cm
Z Length: 536.0 cm
Bounding Box Volume: 340782488.9 cm^3

Example 4 β€” create an ARB8 bounding box πŸŽ€

mged> bb -c havoc_parts_bbox.s havoc_front havoc_middle havoc_tail
Bounding Box Dimensions, Object(s) havoc_front,  havoc_middle,  havoc_tail:
X Length: 1775.9 cm
Y Length: 358.0 cm
Z Length: 536.0 cm
Bounding Box Volume: 340782488.9 cm^3

mged> l havoc_parts_bbox.s
havoc_parts_bbox.s:  ARB8
        1 (-75.9447, -158, -4.86374e-06)
        2 (-75.9447, -158, 536)
        3 (-75.9447, 200, 536)
        4 (-75.9447, 200, -4.86374e-06)
        5 (1700, -158, -4.86374e-06)
        6 (1700, -158, 536)
        7 (1700, 200, 536)
        8 (1700, 200, -4.86374e-06)

πŸ” SEE ALSO πŸ”

make_bb(nged) β€” go give her a look too 🫢


This software is Copyright (c) 2009-2026 United States Government as represented by the U.S. Army Research Laboratory. Respect the paperwork bestie πŸ“œ


πŸ’€ BUG REPORTS πŸ’€

Reports of bugs or problems should be submitted via electronic mail to bugs@brlcad.org. Not me being the messenger, but like… tell them, not me 😭


🌟 AUTHOR 🌟

BRL-CAD Team


and that's the whole page, bestie β€” brought to you by the BRL-CAD girlies, BB(nged), no cap πŸ’œβœ¨

πŸ“¦ where this page comes from