S2PLOT:Function List

From S2PLOT

Revision as of 04:12, 26 October 2007; view current revision
←Older revision | Newer revision→
Jump to: navigation, search


Contents

General

S2PLOTDescriptionPGPLOT
ColoursUseful colour definitions based on PGPlot default settings.
TexturesImportant information on using textures in S2PLOT.
struct XYZData structure for (x,y,z) coordinates.
struct COLOURData structure for (r,g,b) colour indices.

Opening, Closing and Selecting Devices

S2PLOTDescriptionPGPLOT
s2openOpen the S2PLOT device. PGOPEN
s2opendOpen the S2PLOT device (device string version). PGOPEN
s2opendoOpen the S2PLOT device (device string version, ignoring command line arguments). PGOPEN
s2ldevList the available S2PLOT devices on stdout. PGLDEV
s2showDraw the scene and enter interactive mode if interactive is non-zero.
s2dispDraw the scene, but return control when a timeout occurs or when 'TAB' key is pressed.
s2erasErase the geometry. PGERAS

Windows and Viewports

S2PLOTDescriptionPGPLOT
s2svpSet up the part of 3D space that is used for plotting. PGSVP
s2qvpQuery the device viewport range. PGQVP
s2swinSet up the world coordinate range for the device. PGSWIN
s2qwinQuery the world coordinate range. PGQWIN
s2envConvenience function which sets the plotting environment. PGENV

Primitives

S2PLOTDescriptionPGPLOT
s2lineDraw a poly line, n vertices at (xpts, ypts, zpts). PGLINE
s2circxyDraw a circle in the xy plane at a given z coordinate. PGCIRC
s2circxzDraw a circle in the xz plane at a given y coordinate. PGCIRC
s2circyzDraw a circle in the yz plane at a given x coordinate. PGCIRC
s2diskxyDraw a disk in the xy plane at a given z coordinate.
s2diskxzDraw a disk in the xz plane at a given y coordinate.
s2diskyzDraw a disk in the yz plane at a given x coordinate.
s2rectxyDraw a rectangle in the xy plane at a given z coordinate. PGRECT
s2rectxzDraw a rectangle in the xz plane at a given y coordinate. PGRECT
s2rectyzDraw a rectangle in the yz plane at a given x coordinate. PGRECT
s2pt1Draw a single point with a given symbol. PGPT1
s2ptDraw a set of points with a given symbol. PGPT
s2pntsDraw a set of points with different markers. PGPNTS
s2textxyDraw text in the xy plane at a fixed z coordinate. PGTEXT
s2textxzDraw text in the xz plane at a fixed y coordinate. PGTEXT
s2textyzDraw text in the yz plane at a fixed x coordinate. PGTEXT
s2textxyfDraw flipped text in the xy plane at a fixed z coordinate. PGTEXT
s2textxzfDraw flipped text in the xz plane at a fixed y coordinate. PGTEXT
s2textyzfDraw flipped text in the yz plane at a fixed x coordinate. PGTEXT
s2qtxtxyFind the bounding box of text drawn with s2textxy. PGQTXT
s2qtxtxzFind the bounding box of text drawn with s2textxz. PGQTXT
s2qtxtyzFind the bounding box of text drawn with s2textyz. PGQTXT
s2qtxtxyfFind the bounding box of text drawn with s2textxyf. PGQTXT
s2qtxtxzfFind the bounding box of text drawn with s2textxzf. PGQTXT
s2qtxtyzfFind the bounding box of text drawn with s2textyzf. PGQTXT
s2arroDraw an arrow from the point with world-coordinates (x1,y1,z1) to (x2,y2,z2). PGARRO

Attributes

S2PLOTDescriptionPGPLOT
s2sciSet the pen colour by index. PGSCI
s2scrSet colour representation, ie. define a colour associated with an index. PGSCR
s2qcrQuery colour representation. PGQCR
s2slwSet the linewidth in pixels. PGSLW
s2schSet the character height in "arbitrary" units. PGSCH
s2sahSet the style to be used for arrowheads drawn with s2arro. PGSAH

Axes, Boxes & Labels

S2PLOTDescriptionPGPLOT
s2boxDraw a labelled box around the world space. PGBOX
s2labDraw labels along the edges of bounding box. PGLAB

XY(Z) Plots

S2PLOTDescriptionPGPLOT
s2errbDraw error bars at the coordinates (xpts[i], ypts[i], zpts[i]). PGERRB
s2funtDraw a curve defined by parametric equations fx(t), fy(t) and fz(t). PGFUNT
s2funtcDraw a curve defined by parametric equations fx(t), fy(t) and fz(t) with colour control. PGFUNT
s2funxyDraw the surface described by the provided function fxy. PGFUNX
s2funxzDraw the surface described by the provided function fxz. PGFUNY
s2funyzDraw the surface described by the provided function fyz. PGFUNX
s2funxyrDraw surface as per s2funxy, but with explicit settings for the colour range mapping.
s2funxzrDraw surface as per s2funxz, but with explicit settings for the colour range mapping.
s2funyzrDraw surface as per s2funyz, but with explicit settings for the colour range mapping.
s2funuvPlot a parametric function (generally a surface) defined by functions fx(u,v), fy(u,v) and fz(u,v).

Images/Surfaces

S2PLOTDescriptionPGPLOT
s2surpDraw a colour surface representation of the 2-dimensional array, data, containing nx * ny values. PGIMAG
s2surpaDraw a colour surface representation of the 2-dimensional array, data, containing nx * ny values. PGIMAG
s2scirSet the range of colour indices used for shading. PGSCIR
s2qcirQuery the colour index range. PGQCIR
s2icmInstall various colour maps. PGSITF
s2wedgeDraw a colour wedge. PGWEDG

Vector Plots

S2PLOTDescriptionPGPLOT
s2vect3Draw a vector map of a 3D data array, with blanking. PGVECT

Miscellaneous Routines

S2PLOTDescriptionPGPLOT
s2idenWrite username, date, time and optional string at bottom of plot. PGIDEN

S2 "Native" Routines

S2PLOTDescriptionPGPLOT
ns2sphereDraw a sphere, with a given centre, radius and colour.
ns2vsphereDraw a sphere, with a given centre, radius and colour - vecotr input.
ns2spheretDraw a textured sphere, with given centre, radius, colour and texture filename.
ns2vspheretDraw a textured sphere, with given centre, radius, colour and texture filename - vector input.
ns2diskDraw an annulus with given centre, inner and out radii, and colour.
ns2vdiskDraw an annulus with given centre, inner and out radii, and colour - vector input.
ns2arcDraw an arc at (px,py,pz) with normal (nx,ny,nz) in current pen (thickness,colour).
ns2varcDraw an arc at (px,py,pz) with normal (nx,ny,nz) in current pen (thickness,colour) - vector input.
ns2textDraw text at a given position, with right and up vectors, a specific colour, and a text string of course.
ns2vtextDraw text at a given position, with right and up vectors, a specific colour, and a text string of course - vector input.
ns2pointDraw a point at the given position and colour.
ns2vpointDraw a point at the given position and colour - vector input.
ns2vnpointDraw multiple points at the given positions with one colour - vector input.
ns2thpointDraw a thick point at given position, in colour and thickness in pixels (not world coords).
ns2vthpointDraw a thick point at given position, in colour and thickness in pixels (not world coords) - vector input.
ns2iIllumination.
ns2viIllumination - vector input.
ns2lineDraw a line from one point to another in a specific colour.
ns2vlineDraw a line from one point to another in a specific colour - vector input.
ns2thlineDraw a thick line from one point to another in a specific colour.
ns2vthlineDraw a thick line from one point to another in a specific colour - vector input.
ns2clineDraw a coloured line, with colour blended between the two given colours along the line.
ns2vclineDraw a coloured line, with colour blended between the two given colours along the line - vector input.
ns2vf33-vertex facet with single colour and automatic normals.
ns2vf3n3-vertex facet with single colour and normals given.
ns2vf3c3-vertex facet with coloured vertices and autmoatic normals.
ns2vf3nc3-vertex facet with coloured vertices and normals given.
ns2vf44-vertex facet with single colour and automatic normals.
ns2vf4n4-vertex facet with single colour and normals given.
ns2vf4c4-vertex facet with coloured vertices and automatic normals.
ns2vf4nc4-vertex facet with coloured vertices and normals given.
ns2vf4tTextured 4-vertex facet, scale in [0,1]; trans = 'o' or 't'.
ns2vf4xDraw a textured 4-vertex facet using a texture id.
ns2vf4xtDraw a textured 4-vertex facet with alpha channel using a texture id.
ns2mDraw a marker
ns2vmDraw a marker - vector input

Callback and Handle System

S2PLOTDescriptionPGPLOT
cs2scbSet the callback function; can be null to cancel callback.
cs2ecbAnimation state - Enable callback.
cs2dcbAnimation state - Disable callback.
cs2tcbAnimation state - Toggle callback.
cs2sncbSet the function to call when number-keys pressed.
cs2socbRegister function that will draw direct OpenGL graphics when called.
cs2ahAdd a handle to allow interactive picking of objects
cs2shcbSet the handle callback function for when a handle is (de)selected
cs2thToggle the state of a named (dynamic) handle
cs2qhvQuery whether selection handles are currently visible

Advanced Texture and Colormap Handling

S2PLOTDescriptionPGPLOT
ss2ltLoad a texture for future (generally repeated) use.
ss2gtGet a pointer to an identified texture.
ss2ptReinstall a texture.
ss2lcmLoad a colourmap into memory.
ns2spherexDraw a textured sphere, with given centre, radius, colour and texture ID.
ns2vspherexDraw a textured sphere, with given centre, radius, colour and texture ID - vector input.

Environment and Rendering Attributes

S2PLOTDescriptionPGPLOT
ss2ssrSet sphere resolution.
ss2srmSet the rendering mode.
ss2qrmGet the rendering mode.
ss2slSet the entire lighting environment
ss2sbcSet the background colour.
ss2sfraSet the fisheye rotation angle (degrees).
ss2qptFetch the projection type of the device in use.

Advanced Camera Control

S2PLOTDescriptionPGPLOT
ss2scSet the camera position, up vector and view direction.
ss2qcQuery the camera position, up vector and view direction.
ss2sasStart/Stop the camera rotation.
ss2scfSet the camera mid/focus point.
ss2ucfUnset the camera mid/focus point - revert to auto mid-point.
ss2tcEnable/disable (1,0) camera translation.
ss2sssSet the spin / interaction speed
ss2qssGet the spin / interaction speed

Additional Primitives

S2PLOTDescriptionPGPLOT
s2chromaptsPlot points on a sphere using chromastereoscopic colouring for depth
s2chromacptsPlot cartesian points using chromastereoscopic colouring for depth

Functions in Testing/Development

S2PLOTDescriptionPGPLOT
s2latextureCreate a texture with LATEX commands.
ns2vf3a3-vertex facet with transparency
ns2cisCreate an isosurface object
ns2ciscCreate an isosurface object with a colour function
ns2disDraw an isosurface object
ns2sislChange the level of isosurface
ns2cvrCreate a volume rendering object
cs2thvToggle the current state of selection handles
ss2ctCreate a texture with specified width and height
ss2dtDelete a texture
ss2txhEnable/disable/toggle the visibility of the cursor cross-hair
ss2qxhQuery the visibility of the cursor cross-hair

Dynamic-Only Geometry Functions

S2PLOTDescriptionPGPLOT
ds2bbDraw a (dynamic) billboard: a textured facet that always faces the camera
ds2vbbDraw a (dynamic) billboard: a textured facet that always faces the camera - vector input
ds2tbDraw text that always faces the camera
ds2vtbDraw text that always faces the camera - vector input
ds2dvrDraw a volume render object from a dynamic callback

Deprecated Function Names (V1.48-V1.62)

Personal tools