GETSET(3NCARG)

✨ GETSET β€” the NCAR Graphics glow-up ✨

okay bestie, so this is GETSET from NCAR Graphics (manual page GETSET(3NCARG), we love her) πŸ’…


πŸ’– NAME πŸ’–

GETSET hands you back a whole set of values, and if you drop those values as arguments into a call to SET, you get normalization transformation 1, axis linear/log scaling (that's internal parameter 'LS'), and axis mirror imaging (that's internal parameter 'MI') all defined in a way that duplicates the combined effects of the current normalization transformation, axis scaling, and axis mirror imaging. like, it copies the vibe of your current setup into a fresh SET call. no cap. πŸͺžβœ¨


🌸 SYNOPSIS 🌸

CALL GETSET (VL,VR,VB,VT,WL,WR,WB,WT,LS)

πŸ¦‹ C-BINDING SYNOPSIS πŸ¦‹

#include <ncarg/ncargC.h>

void c_getset(float *vl, float *vr, float *vb, float *vt, float *wl,
float *wr, float *wb, float *wt, int *lf)

πŸ‘‘ DESCRIPTION πŸ‘‘

okay so every single one of these is an output variable, meaning they're the ones doing the giving and you're the one receiving. so generous of them 🫢

  • VL β€” an output variable of type REAL. she defines the left margin of the viewport, in fractional coordinates.
  • VR β€” an output variable of type REAL. right margin of the viewport, fractional coordinates.
  • VB β€” an output variable of type REAL. bottom margin of the viewport, fractional coordinates.
  • VT β€” an output variable of type REAL. top margin of the viewport, fractional coordinates.
  • WL β€” an output variable of type REAL. left margin of the window, in user coordinates this time.
  • WR β€” an output variable of type REAL. right margin of the window, user coordinates.
  • WB β€” an output variable of type REAL. bottom margin of the window, user coordinates.
  • WT β€” an output variable of type REAL. top margin of the window, user coordinates.
  • LS β€” an output variable of type INTEGER. she defines the linear/log nature of the mapping, and here's the whole menu, no skips:
    • 1 β€” linear X, linear Y
    • 2 β€” linear X, log Y
    • 3 β€” log X, linear Y
    • 4 β€” log X, log Y

πŸ’œ C-BINDING DESCRIPTION πŸ’œ

the C-binding argument descriptions are literally the same as the FORTRAN argument descriptions. same energy, different syntax. iconic behavior, honestly. 🌈


πŸ”₯ USAGE πŸ”₯

okay so here's the tea, and it's genuinely kind of iconic 🍡:

when you're setting the limits of the viewport and the window, the left margin can have a user coordinate value that is larger than the user coordinate value at the right margin. yes, fr fr. that means the X axis scale will run from a maximum value at the left to a minimum value at the right. like, going backwards on purpose. and same situation vertically: the bottom value can exceed the top value, meaning the Y axis can run from a maximum at the bottom to a minimum at the top. 😭

this reversal of the axes is called "mirror imaging". πŸͺž

and this is not a bug, bestie, this is a substantial functional enhancement over what's provided in GKS. that's exactly why NCAR Graphics SET calls using fractional and user coordinates are, in general, preferred over GKS calls to GSVP and GSWN using normalized device coordinates and world coordinates. periodt. πŸ’…


🌟 EXAMPLES 🌟

use the ncargex command to see the following relevant examples, all of them, in order: arex01, mpex07, mpex09, cpexcc. go look, they ate. ✨


πŸŽ€ ACCESS πŸŽ€

to use GETSET or c_getset, load the NCAR Graphics libraries ncarg, ncarg_gks, and ncarg_c β€” preferably in that order. the order matters, don't do your own thing here πŸ™ˆ


🌈 SEE ALSO 🌈

Online: gqnt, set, getusv, setusv, spps, spps_params, ncarg_cbind

Hardcopy: NCAR Graphics Fundamentals, UNIX Version; User's Guide for NCAR GKS-0A Graphics

iykyk, go read the friends too πŸ’–


Copyright (C) 1987-2009 University Corporation for Atmospheric Research The use of this Software is governed by a License Agreement.


okay that's the whole page bestie, nothing skipped, nothing dropped πŸ’€βœ¨

and that's a wrap on the UNIX, March 1993 edition of GETSET(3NCARG) β€” slay, bye, ily, go mirror some axes responsibly πŸ¦‹πŸŽ€πŸ’œ