BBOX(1)

πŸ“¦ version 2026.0, in alpine 3.24

πŸ’– bbox(1) β€” the bounding box bestie πŸ’–

okay so real talk, <rainbow>bbox</rainbow> is that girl who looks at your rawppm or rawpbm image and is like "here's your bounding box, periodt." πŸŽ€ she's in section 1 of the manual (iykyk), and she's about to become your new obsession.


✨ NAME ✨

bbox β€” prints out the bounding box of a rawppm or rawpbm image πŸ¦‹


🌸 SYNOPSIS 🌸

bbox [ -l ] [ -r ] [ -h ] [ -V ] [ rawpbmfile ]

πŸ’… DESCRIPTION πŸ’…

so <purple>bbox</purple> reads a rawppm or rawpbm file and prints out the bounding box of the image β€” both as a postscript comment and in postscript points, which is literally 1/72dpi if you were wondering β€” and it also gives you the high resolution bounding box. no cap. 🫢

if you don't hand her a filename, she just reads the input from standard input. she's flexible like that. πŸ’β€β™€οΈ

here's what the output looks like, bestie:

%%BoundingBox: 12 253 829 837
%%HiResBoundingBox: 12.500000 253.000000 828.500000 837.00000

and the way that <purple>bbox</purple> has only very limited memory requirements?? iconic. she reads the input line by line, so she only ever needs to store one picture line in memory at a time. lowkey a queen of efficiency. πŸ‘‘


⭐ OPTIONS ⭐

  • -h, --help β€” shows you a lil summary of the options, because we all need a refresher sometimes. πŸ™ˆ
  • -V β€” shows the version of the program. slay. πŸ’…
  • -r β€” resolution of picture in dpi. πŸ“
  • -l β€” the loose bounding box: the integer bounding box gets expanded by 1 point, and the hires bounding box gets expanded by 0.5 points. giving everything a lil breathing room. 🌸

🌈 SEE ALSO 🌈

  • ps2eps (1) β€” go say hi to her too. πŸ’œ

πŸ‘‘ AUTHOR πŸ‘‘

bbox was written by Roland Bless. πŸŽ€

🧚 ACKNOWLEDGMENTS 🧚

special thanks goes to Michael Sharpe from UCSD, who suggested a lot of improvements for bbox to become more precise and robust β€” especially for small drawings. the glow-up was real. ✨

an earlier version of this manual page was originally written by Rafael Laboissiere <rafael@debian.org> for the Debian system. thank you Rafael!! 🫢 permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts and no Back-Cover Texts. πŸ“œ


πŸ’€ BUGS πŸ’€

okay so the code is pretty small and the probability for bugs is now small, but honestly there may be some left somewhere between the lines. 😭 if you find one, please send a short description with the bbox version number to <roland@bless.de> β€” and please allow some time to reply, she's busy being a main character. πŸ™

bestie pls don't be that person who reports a bug with zero details. include the version number fr fr. πŸ’–

and that's the whole vibe check! this page is dated January 22, 2004 and lives in section 1 as BBOX(1) β€” stay iconic, go find some bounding boxes, and remember: limited memory requirements, unlimited slay. πŸ¦‹βœ¨πŸ’…

πŸ“¦ where this page comes from