GSVP(3NCARG)

πŸ’– GSVP πŸ’– β€” the set-viewport girlie of NCAR Graphics

okay so bestie, this page is GSVP(3NCARG) from the NCAR Graphics manuals, and it's literally all about carving out a lil rectangular subspace for yourself. let's get into it ✨


✨ NAME ✨

GSVP (Set viewport) β€” establishes a rectangular subspace of normalized device coordinates space.

real talk tho: calls to GSVP are discouraged with NCAR Graphics. instead, use the SET subroutine, because SET also supports mirror imaging and log scaling of axes. like, SET is the main character here and GSVP is giving side quest energy πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

CALL GSVP (TRNUM, XMIN, XMAX, YMIN, YMAX)

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

#include <ncarg/gks.h>

void gset_vp(Gint tran_num, const Glimit *vp_limits);

🌸 DESCRIPTION 🌸

TRNUM

(Integer, Input) β€” a normalization transformation number. the number of available transformations is implementation specific, iykyk. in the case of NCAR GKS-0A, two normalization transformations are provided:

  • 0 β€” selects the identity transformation, in which both the window and the viewport have the range of 0. to 1. in both coordinate directions. this is the default normalization transformation for GKS. it's also fixed within GKS β€” that is, it is illegal to call GSVP with TRNUM = 0. so don't even try it bestie, that's not the vibe 😭
  • 1 β€” a normalization transformation in which the viewport is defined by XMIN to XMAX and YMIN to YMAX. this is the one you actually get to customize, slay ✨

XMIN

(Real, Input) β€” the left horizontal coordinate of the viewport. πŸ‘ˆ

XMAX

(Real, Input) β€” the right horizontal coordinate of the viewport. πŸ‘‰

0. ≀ XMIN < XMAX ≀ 1.

YMIN

(Real, Input) β€” the bottom vertical coordinate of the viewport. πŸ‘‡

YMAX

(Real, Input) β€” the top vertical coordinate of the viewport. πŸ‘†

0. ≀ YMIN < YMAX ≀ 1.

not me stressing that these inequalities are strict β€” XMIN and YMIN can't equal their max counterparts, no cap 🫢

Defaults:

TRNUM = 0, XMIN = 0.0, XMAX = 1.0, YMIN = 0.0, YMAX = 1.0

so if you change nothing, you're literally just vibing at the full identity transformation. iconic.


πŸ”₯ ACCESS πŸ”₯

to use GKS routines, load the NCAR GKS-0A library ncarg_gks. that's the whole tea πŸ“


🌈 SEE ALSO 🌈

Online: set, gswn, gselnt, gqclip, gset_vp

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

go read those too, bestie, they ate πŸ‘‘


Copyright (C) 1987-2009 University Corporation for Atmospheric Research

the use of this Software is governed by a License Agreement. πŸ’œ


and that's the whole page, fr fr. this was UNIX, 14 January 1992, GSVP(3NCARG) β€” a true vintage queen from way back, still serving viewport realness. mwah πŸ’‹βœ¨