TDCTRI(3NCARG)
π TDCTRI β bestie, we're cutting triangles today π
okay so this is TDCTRI, part of the NCAR GRAPHICS fam (section 3NCARG, for the record π). grab a snack, we're slicing geometry π
β¨ NAME β¨
TDCTRI β cut triangles defined by a triangle list. literally that's the whole job bestie π
β¨ SYNOPSIS β¨
CALL TDCTRI (RTRI, MTRI, NTRI, IAXS, RCUT)
π C-BINDING SYNOPSIS π
#include <ncarg/ncargC.h>
void c_tdctri(float *rtri, int mtri, int *ntri, int iaxs, float rcut)
π¦ DESCRIPTION π¦
so here's the vibe π: you hand this routine a list of NTRI triangles chillin' in the array RTRI, plus an axis id IAXS (1 => U axis, 2 => V axis, 3 => W axis), plus a value RCUT along that axis. and then β the way it cuts β it takes every single triangle that intersects the plane perpendicular to that identified axis at that specified value and slices it into two pieces, one on either side of the plane. it's giving scissors βοΈβ¨
why would you even want that? because it's useful when you're rendering the triangles in colors that depend on their position in U, V, or W. iykyk πΈ (peep the example "tdex04" if you wanna see it in the wild π)
the arguments of TDCTRI are as follows, no skips:
RTRIβ (an input/output array, of type REAL, dimensioned10 x MTRI) a list of triangles, probably created by means of calls to TDSTRI, TDITRI, and/or TDMTRI. and heads up bestie, the number of triangles in the list may increase as a result of calling TDCTRI. it grows. that's just what it does πMTRIβ (an input expression of type INTEGER) the second dimension ofRTRI, and thus the maximum number of triangles the triangle list will hold. it's the ceiling, the cap, the limit π«ΆNTRIβ (an input/output variable of type INTEGER) specifies the number of triangles currently in the list. and listen β it is the user's responsibility to zero this initially π. its value gets increased by each call to a triangle-generating routine like TDSTRI or TDITRI, and it may be increased by a call to TDCTRI too. so like, don't forget to zero it, fr fr.IAXSβ (an input variable of type INTEGER) specifies the axis to which the cut plane is perpendicular (1=> U axis,2=> V axis,3=> W axis). pick your fighter βRCUTβ (an input variable of type REAL) specifies that value of U, V, or W at which the cut plane intersects the axis. the exact spot, periodt π
πΈ C-BINDING DESCRIPTION πΈ
the C-binding argument descriptions are the same as the FORTRAN argument descriptions. no new lore, same energy, we love consistency π
β ACCESS β
to use TDCTRI or c_tdctri, load the NCAR Graphics libraries ncarg, ncarg_gks, and ncarg_c β preferably in that order. order matters bestie, don't play with it π₯
π SEE ALSO π
online, the whole squad:
tdclrs, tddtri, tdgeti, tdgetr, tdgrds, tdgrid, tdgtrs, tdinit, tditri, tdlbla, tdlbls, tdline, tdlnpa, tdmtri, tdpack, tdpack_params, tdpara, tdplch, tdprpa, tdprpi, tdprpt, tdseti, tdsetr, tdsort, tdstri, tdstrs
π COPYRIGHT π
Copyright (C) 1987-2009 University Corporation for Atmospheric Research
the use of this Software is governed by a License Agreement. π
ok that's the whole page bestie, go cut some triangles π¦βοΈ
kisses, this was TDCTRI(3NCARG) on UNIX, dated July 1997 β yeah she's an icon from the 90s and she still ate π ππ
π¦ where this page comes from
- epel 9: ncl-devel 6.6.2-59.el9 Β· LicenseRef-Callaway-BSD
- fedora 43: ncl-devel 6.6.2-58.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: ncl-devel 6.6.2-62.fc44 Β· LicenseRef-Callaway-BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms