SCALE(nged)

scale the current view by a uniform factor

πŸ“… published 7.44.0, from nixpkgs unstable

πŸ’… SCALE(nged) β€” the zoomies command πŸ¦‹

ok so bestie, welcome to scale from the BRL-CAD User Commands collection (nged) β€” this is the little cutie that changes how big stuff looks in your view without touching a single thing in your database. main character energy for zooming, zero drama for geometry. ✨


🌸 NAME 🌸

scale β€” scales the current view by a uniform factor. that's it, that's the whole vibe πŸ’–


✨ SYNOPSIS ✨

    scale sf
    sca sf

two ways to summon it, same energy: the full scale or the lil sca nickname πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

the scale command (it also answers to sca, adorable) multiplies the current view scale by the scale factor sf you hand it. so like:

  • a value greater than 1 zooms out β€” objects look smaller πŸ”
  • a value less than 1 zooms in β€” objects look bigger 🫢

and here's the part where you gotta pay attention, bestie, because the rules are strict: the scale factor must be a positive, finite number. zero? negative? infinite? nope β€” those get silently ignored. no error, no warning, just absolutely nothing happening. πŸ’€

the resulting view scale is clamped at a minimum value (BV_MINVIEWSIZE) so the view can never collapse all the way to zero. safety rails, we love to see it 🧚

🌈 important vibe check: this command scales the view only β€” it does not modify any geometry in the database. if you actually want to scale a primitive's attributes directly, go use pscale instead. don't @ me.

also: only a single (uniform) scale factor is accepted. if you try to give it three separate XYZ scale factors, it throws an error: "Can not scale xyz independently on a view." per-axis independent scaling is only a thing in MGED object-edit mode via the sca Tcl binding. iykyk 😌


πŸŽ€ EXAMPLES πŸŽ€

example 1 β€” zoom in by a factor of 2 πŸ‘‘

    mged> scale 0.5

this halves the view scale, which makes objects appear twice as large (zooming in). ate and left no crumbs πŸ”₯

example 2 β€” zoom out by a factor of 4 🌸

    mged> sca 4

this multiplies the view scale by 4, making objects appear four times smaller (zooming out). and yes, it used the short sca alias, because we're efficient πŸ’…

example 3 β€” restore a zoom after inspecting detail πŸ¦‹

    mged> set s [view size] mged> scale 0.1 mged> view size $s

ok this one is the icon of the group: it saves the current view size, zooms in to 10% of original scale so you can inspect detail, then restores the original view size. literally the "screenshot then put it back" of camera moves πŸŽ€


πŸ’œ AUTHOR πŸ’œ

BRL-CAD Team β€” the legends themselves πŸ‘‘


πŸ™ˆ BUG REPORTS πŸ™ˆ

found a bug or a problem? spill it via electronic mail to devs@brlcad.org πŸ“§ they wanna hear it fr fr


and that's the whole page, bestie!! no cap, every detail intact, every flag-less flag counted (there are no options, which is honestly so refreshing) πŸ’–βœ¨

sign-off: this gorgeous lil doc came from BRL-CAD, dropped on the SCALE(nged) page date. go zoom responsibly, mwah πŸ«ΆπŸ’…
πŸ“¦ where this page comes from