home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / unix / volume14 / vplot / part21 < prev    next >
Text File  |  1988-03-31  |  46KB  |  1,649 lines

  1. Subject:  v14i026:  Device-independant graphics system, with drivers
  2. Newsgroups: comp.sources.unix
  3. Sender: sources
  4. Approved: rsalz@uunet.UU.NET
  5.  
  6. Submitted-by: Joe Dellinger <joe@hanauma.STANFORD.EDU>
  7. Posting-number: Volume 14, Issue 26
  8. Archive-name: vplot/part21
  9.  
  10. #! /bin/sh
  11. # This is a shell archive.  Remove anything before this line, then unpack
  12. # it by saving it into a file and typing "sh file".  To overwrite existing
  13. # files, type "sh file -c".  You can also feed this as standard input via
  14. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  15. # will see the following message at the end:
  16. #        "End of archive 21 (of 24)."
  17. # Wrapped by rsalz@fig.bbn.com on Fri Mar 25 11:47:33 1988
  18. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  19. if test -f 'Vplot_Kernel/Documentation/libvplot.mn' -a "${1}" != "-c" ; then 
  20.   echo shar: Will not clobber existing file \"'Vplot_Kernel/Documentation/libvplot.mn'\"
  21. else
  22. echo shar: Extracting \"'Vplot_Kernel/Documentation/libvplot.mn'\" \(28451 characters\)
  23. sed "s/^X//" >'Vplot_Kernel/Documentation/libvplot.mn' <<'END_OF_FILE'
  24. X.TH libvplot 9 "6 June 1987" "Stanford Earth Sciences"
  25. X.SH NAME
  26. libvplot \- programmer's interface to the vplot - pen graphics system
  27. X.SH SYNOPSIS
  28. X.B #include <vplot.h>
  29. X.PP
  30. Use
  31. X
  32. X    {cc,f77} myprog.o -lvplot -lm
  33. X
  34. to link in the
  35. X.B libvplot
  36. functions.
  37. X.PP
  38. One of the functions {vp_file(), vp_filep(), or vp_unit()} must be called
  39. to initialize the output file.
  40. X.SH INTRODUCTION
  41. X.B Libvplot
  42. is a set of subroutines which write graphics calls
  43. in the
  44. X.B vplot(9)
  45. graphics language.
  46. The output file may be an ordinary file or a pipe to a
  47. X.B pen(9)
  48. display program.
  49. X.PP
  50. The subroutines are callable either from C or from FORTRAN.
  51. C function names have an embedded underbar (e.g., `vp_break()')
  52. while the corresponding FORTRAN name will not use the
  53. underbar (`CALL VPBREAK()').
  54. X.PP
  55. Input to
  56. X.B vplot
  57. plot files should be done ONLY through the
  58. X.B libvplot
  59. calls.
  60. Programs which write
  61. X.B vplot
  62. language directly are doomed to early
  63. obsolescence.
  64. Future versions of
  65. X.B vplot
  66. will provide backwards compatibility at the
  67. X.B libvplot
  68. subroutine call level, not necessarily at the
  69. X.B vplot
  70. language level.
  71. X.PP
  72. Separate functions are available to accept geometric arguments
  73. in inches and in arbitrary user units. 
  74. The routines which accept user units have `u' prepended to
  75. their root names.
  76. Absolute coordinates (x,y) in inches are computed internally
  77. from user coordinates (xu,yu) in user units via:
  78. X.PP
  79. X.br
  80. X       x = x0+(xu-xu0)*xscl
  81. X.br
  82. X       y = y0+(yu-yu0)*yscl
  83. X
  84. This transformation is set by calls to
  85. X.B vp_orig,
  86. which sets x0 and y0;
  87. X.B vp_uorig,
  88. which sets xu0 and yu0; and
  89. X.B vp_scale,
  90. which sets xscl and yscl.
  91. X.SH COORDINATES
  92. Vplot fits the largest rectangle with a 3 (high) by 4 (wide) aspect ratio
  93. X(SCREENRATIO in vplot.h) onto your device screen that it can.
  94. This window defines your output space.
  95. X(Although clipping is still done at the edges of the actual screen.)
  96. X.PP
  97. Two different coordinate system orientations are available, ``standard''
  98. and ``rotated''. In the standard coordinate orientation, the origin is
  99. in the lower left hand corner and the X axis is horizontal and the Y axis
  100. is vertical. In the rotated coordinate orientation, the origin is in the upper
  101. left hand corner and the X axis is vertical and the Y axis is horizontal.
  102. The standard coordinate orientation is the default. (See vp_style.)
  103. X.PP
  104. Two different scaling methods are available, ``relative'' and ``absolute''.
  105. Which mode is used can be set by the device, options to pen, or vp_style.
  106. In absolute mode inches in vplot correspond to real inches on the device
  107. display screen. In relative mode the plot is scaled to the size of the screen.
  108. In the standard coordinate system orientation the screen is considered to be
  109. X10.24 (STANDARD_HEIGHT) inches tall, and in the rotated coordinate orientation
  110. system the screen is considered to be 7.5 (ROTATED_HEIGHT) inches tall.
  111. X.PP
  112. The routine vp_stretch is a utility routine which calls vp_scale, vp_orig,
  113. and vp_uorig for you if you just want to ``fill the screen''.
  114. X.PP
  115. For more on coordinate systems and ``magic numbers'', refer to the Vplot
  116. manual page.
  117. X.SH FORTRAN
  118. All of these routines can also be called from FORTRAN. The argument types
  119. are given for C, but these can be easily converted to FORTRAN by the
  120. following table:
  121. X.br
  122. int x -- integer x
  123. X.br
  124. float y -- real y
  125. X.br
  126. float *x -- real x()  (unless otherwise noted)
  127. X.br
  128. int *y -- integer y()  (unless otherwise noted)
  129. X.br
  130. char *s -- character(*) s
  131. X.br
  132. unsigned char *a -- No Standard Fortran Equivalent
  133. X.PP
  134. X.SH SUBROUTINES
  135. X.PP
  136. X.ft 3
  137. X.ne 5
  138. geth
  139. X.br
  140. int geth (iop)
  141. X.br
  142. register    FILE * iop;
  143. X.ft 1
  144. X.RS
  145. X.PP
  146. Get a two-byte integer from file or pipe `iop'.
  147. Uses the same byte order on all machines. (This is important!)
  148. Usually called by other
  149. X.B libvplot
  150. functions, not by user programs.
  151. X.RE
  152. X.PP
  153. X.ne 5
  154. X.ft 3
  155. puth (w, iop)
  156. X.br
  157. register int    w;
  158. X.br
  159. register    FILE * iop;
  160. X.ft 1
  161. X.RS
  162. X.PP
  163. Put the low two bytes of `w' on stream `iop'.
  164. Uses the same byte order on all machines.
  165. Usually called by other
  166. X.B libvplot
  167. functions, not by user programs.
  168. X.RE
  169. X.PP
  170. X.ft 3
  171. X.ne 6
  172. vp_area(xp, yp, lp, fat, xmask, ymask)
  173. X.br
  174. vp_uarea(xp, yp, lp, fat, xmask, ymask)
  175. X.br
  176. float  *xp, *yp;
  177. X.br
  178. int     lp, fat, xmask, ymask;
  179. X.ft 1
  180. X.RS
  181. X.PP
  182. Fill the area within the polygon defined by the points
  183. in the `xp' and `yp' arrays.  Uses the
  184. X.B VP_OLDAREA
  185. vplot command, which knows how to do solid fills or simple
  186. halftone-style stipples.  `Lp' is the number of
  187. vertices.  `Fat' is the fatness of the border line.  If
  188. fat<0, no border is drawn.  The filling style varies
  189. depending on whether or not the device has color.
  190. If the device has color, the fill is done solidly
  191. using the current drawing color.  If the device is
  192. monochrome, the masks tell how many blank pixels
  193. to use to pad each pixel to be drawn.
  194. Filling is done by tiling the area with
  195. rectangles of size `xmask' by `ymask', with only
  196. the lower right pixel turned on.  Thus, both
  197. masks 1 gives a solid fill; xmask=1 and ymask=2 produces
  198. horizontal lines spaced one pixel apart; xmask=4, ymask=4 gives
  199. a 9.1% `gray' color.  If either xmask or ymask is zero, then
  200. the interior is not filled (even on color devices).
  201. X.RE
  202. X.PP
  203. X.ft 3
  204. X.ne 5
  205. vp_arrow(x0, y0, x, y, r)
  206. X.br
  207. vp_uarrow(x0, y0, x, y, r)
  208. X.br
  209. float   x0, y0, x, y, r;
  210. X.ft 1
  211. X.RS
  212. X.PP
  213. Plot an arrow from (x0,y0) to (x,y) with arrowhead-size `r'.
  214. The arrowhead is half a square.  `r' is the length of a side of
  215. the square.  If `r' is negative, the arrowhead is not filled.
  216. If (x0,y0) = (x,y), a centered box is drawn of size r.
  217. All sizes are in inches (vp_arrow) or user units (vp_uarrow).
  218. If your user-unit coordinate system is not square, you'll probably
  219. want to use vp_where and vp_arrow instead of vp_uarrow.
  220. X.RE
  221. X.PP
  222. X.ft 3
  223. X.ne 7
  224. vp_bgroup(string)
  225. X.br
  226. char *string;
  227. X.ft1
  228. X.RS
  229. X.PP
  230. Begin a new group. Groups are used to combine several vplot
  231. primitives into one entity. Groups may be nested. Groups
  232. may not contain an erase.
  233. X.TP 10
  234. string:
  235. The name of this group.
  236. X.RE
  237. X.PP
  238. X.ft 3
  239. X.ne 7
  240. vp_egroup()
  241. X.ft1
  242. X.RS
  243. X.PP
  244. End a group. Each begin group must be paired with an end group,
  245. like parenthesis in formulas.
  246. X.RE
  247. X.PP
  248. X.ft 3
  249. X.ne 3
  250. vp_break()
  251. X.ft 1
  252. X.RS
  253. X.PP
  254. Interrupt the output processing of the vplot file.
  255. Prompt the user (or pause, depending on the `pause' argument to
  256. X.B pen(9)
  257. X) allow interaction, and reset global plotting parameters,
  258. but don't erase the previous output.
  259. X.RE
  260. X.PP
  261. X.ft 3
  262. X.ne 5
  263. vp_clip(xmin, ymin, xmax, ymax)
  264. X.br
  265. vp_uclip(xmin,ymin,xmax,ymax)
  266. X.br
  267. float xmin,ymin,xmax,ymax;
  268. X.ft 1
  269. X.RS
  270. X.PP
  271. Define the current clipping rectangle, in inches or in user
  272. units. There is currently no call for simply turning off clipping.
  273. Just define a clipping window larger than the space you're working in.
  274. The best way to do this is with the call
  275. X.br
  276. vp_clip(-VP_MAX, -VP_MAX, VP_MAX, VP_MAX).
  277. VP_MAX is defined in vplot.h.
  278. X.RE
  279. X.PP
  280. X.ft 3
  281. X.ne 4
  282. vp_color(col)
  283. X.br
  284. int col;
  285. X.ft 1
  286. X.RS
  287. X.PP
  288. Set the current drawing color to a number
  289. X`col' between 0 and 511 (MAX_COL in params.h).
  290. The first eight colors are predefined:
  291. X
  292. X.ta 0.5i 1.7i
  293. X.br
  294. X    BLACK    0
  295. X.br
  296. X    BLUE    1
  297. X.br
  298. X    RED    2
  299. X.br
  300. X    PURPLE    3
  301. X.br
  302. X    GREEN    4
  303. X.br
  304. X    CYAN    5
  305. X.br
  306. X    YELLOW    6
  307. X.br
  308. X    WHITE    7
  309. X.br
  310. X
  311. X.PP
  312. These numbers are defined in <vplot.h>, so the color name
  313. X(all in caps) can be used instead of the number (within the to-be-compiled
  314. program, NOT as input to plas).
  315. These 8 colors may be re-assigned, if desired, but usually aren't.
  316. Color 0 is always the background color; drawing in color 0 erases.
  317. Color/pattern numbers larger than 7 should be set by the program,
  318. using the
  319. X.B
  320. vp_coltab()
  321. call, before being used (what color you get when you plot with an unset
  322. color is device-dependent).
  323. The numbers 0-511 are used both for colors and for area-fill patterns.
  324. The user is responsible for keeping
  325. track of how the color/pattern table is set.
  326. See the descriptions of
  327. X.ft 3
  328. vp_fill(), vp_area(), vp_patload(),
  329. X.ft 1
  330. and
  331. X.B vp_hatchload()
  332. for more information.
  333. X.RE
  334. X.PP
  335. X.ft 3
  336. X.ne 5
  337. vp_coltab(col, red, green, blue)
  338. X.br
  339. int col;
  340. X.br
  341. float red, green, blue;
  342. X.ft 1
  343. X.RS
  344. X.PP
  345. Color number `col' is set to have the color
  346. X(red, green, blue).  The color levels are all between
  347. X0. and 1.  Thus, (1.,1.,1.) is white and (1.,1.,0.) is
  348. yellow.  `col' is between 0 and 511 (MAX_COL in params.h).
  349. X(The handling of colors on devices that don't have many colors, or
  350. don't have settable colors at all is a tricky business. In general Vplot
  351. will try to take care of all of this for you and come as close as is
  352. possible to what you want. Read the Vplotraster manual page to find
  353. out more about this.) Color table settings last until changed by the
  354. user, except that colors 0 through 7 are reset to the default when a
  355. pen filter is first fired up. Normally colors 0 through 7 are
  356. left at their default settings, so that simple plots using only
  357. those colors can be freely interspersed with a complex many-hued
  358. plot without problems. Color 0 defines the background color.
  359. X.RE
  360. X.PP
  361. X.ft 3
  362. X.ne 4
  363. vp_dash(dash1, gap1, dash2, gap2)
  364. X.br
  365. float dash1, gap1, dash2, gap2;
  366. X.ft 1
  367. X.RS
  368. X.PP
  369. Set the current line style, by defining a special line type.
  370. X`Dash' and `gap' are in inches. This dashing is done within
  371. vplotlib itself, and so these dashes are guaranteed to scale with
  372. the rest of the plot.
  373. X.B Vp_setdash
  374. allows a more complicated (and efficient) dashed line pattern to be defined.
  375. X.RE
  376. X.PP
  377. X.ft 3
  378. X.ne 5
  379. vp_draw(x, y)
  380. X.br
  381. vp_udraw(x, y)
  382. X.br
  383. float   x, y;
  384. X.ft1
  385. X.RS
  386. X.PP
  387. Draw from the current position to (x,y) using the current
  388. color, fatness, and line style.
  389. X.RE
  390. X.PP
  391. X.ft 3
  392. X.ne 3
  393. vp_endplot()
  394. X.ft1
  395. X.RS
  396. X.PP
  397. Close the plot file (output stream).
  398. X.RE
  399. X.PP
  400. X.ft 3
  401. X.ne 3
  402. vp_erase()
  403. X.ft1
  404. X.RS
  405. X.PP
  406. Clear the screen, feed a page of paper, or flush a raster file to the
  407. output stream. Reset most global plotting parameters to their default values.
  408. Prompt the user (or pause, depending on the `pause' argument to
  409. X.B pen(9)
  410. X) and allow interaction.
  411. Normally every plot file should start with
  412. a
  413. X.B vp_erase
  414. call, as the very first thing (after opening the output file). A common
  415. mistake is to call routines
  416. like vp_style, vp_fat, etc, and only THEN vp_erase to erase the screen before
  417. actually drawing something. This is a mistake, as the vp_erase command
  418. will start a new frame. This is not noticeable on most screen devices (unless
  419. you are pausing between frames),
  420. but it will be very noticeable on hardcopy devices that will spit out
  421. a blank first page before ``doing the plot''.
  422. Since
  423. X.B vp_erase
  424. resets most of the vplot global parameters (fatness, current color,
  425. text attributes, current clipping window, dash line pattern, etc),
  426. you should set these to
  427. their desired values again after every call. Color table settings are NOT
  428. reset at erases.
  429. X.RE
  430. X.PP
  431. X.ft 3
  432. X.ne 4
  433. vp_fat(fatness)
  434. X.br
  435. int fatness;
  436. X.ft1
  437. X.RS
  438. X.PP
  439. Set the line width, 200 (FATPERIN) per inch.  Default: 0, which is
  440. the thinnest line possible on the device.
  441. X.RE
  442. X.PP
  443. X.ft 3
  444. X.ne 4
  445. vp_file(filename)
  446. X.br
  447. char *filename;
  448. X.ft1
  449. X.RS
  450. X.PP
  451. Open the file called `filename' as the output stream.
  452. Works for C and for FORTRAN.
  453. One of the functions {
  454. X.B vp_file(), vp_filep(), 
  455. or
  456. X.B vp_unit()
  457. X} MUST be called
  458. to initialize the output.
  459. X.RE
  460. X.PP
  461. X.ft 3
  462. X.ne 4
  463. vp_filep(filepntr)
  464. X.br
  465. FILE *filepntr;
  466. X.ft1
  467. X.RS
  468. X.PP
  469. Connect the already-open stream pointer `filepntr' to the output stream.
  470. C language only. (Example: vp_filep(stdout).)
  471. One of the functions {
  472. X.B vp_file(), vp_filep(), 
  473. or
  474. X.B vp_unit()
  475. X} MUST be called
  476. to initialize the output.
  477. X.RE
  478. X.PP
  479. X.ft 3
  480. X.ne 4
  481. vp_unit(lunit)
  482. X.br
  483. int *lunit;
  484. X.ft1
  485. X.RS
  486. X.PP
  487. Connect the Fortran logical unit `lunit' to the output stream.
  488. Works for 4.2/4.3 BSD Unix only.  This routine was written using details
  489. of the Berkeley Fortran implementation, which have been changed
  490. in ports to some machines other than VAXes.
  491. One of the functions {
  492. X.B vp_file(), vp_filep(), 
  493. or
  494. X.B vp_unit()
  495. X} MUST be called
  496. to initialize the output.
  497. X.RE
  498. X.PP
  499. X.ft 3
  500. X.ne 6
  501. vp_fill(xp, yp, npts)
  502. X.br
  503. vp_ufill(xp, yp, npts)
  504. X.br
  505. float *xp, *yp;
  506. X.br
  507. int npts;
  508. X.ft1
  509. X.RS
  510. X.PP
  511. Fill the area within the polygon defined by the points in
  512. the `xp' and `yp' arrays using the
  513. X.B VP_AREA
  514. vplot command.  The polygon
  515. fill style is determined by the current fill pattern, which is
  516. the loaded pattern with the same index number as the current
  517. drawing color.  Patterns are loaded with the
  518. X.B
  519. vp_patload()
  520. and
  521. X.B vp_hatchload()
  522. calls.  If no pattern has been loaded for this
  523. number, the polygon will be filled solidly with the current
  524. drawing color.
  525. X`Npts' is the number of vertices of the bounding polygon.
  526. X.RE
  527. X.PP
  528. X.ft 3
  529. X.ne 5
  530. vp_hatchload(angle, numhatch, ipat, array);
  531. X.br
  532. int angle, numhatch, ipat;
  533. X.br
  534. int *array;
  535. X.ft1
  536. X.RS
  537. X.PP
  538. Load a hatch pattern as pattern number `ipat'.  (When the
  539. current drawing color is number `ipat', this is the pattern
  540. that will be used with the
  541. X.B vp_fill()
  542. call.) The hatch
  543. pattern consists of `numhatch' sets of lines drawn at an angle
  544. of `angle' to each of the two coordinate axes.
  545. For each set of lines (numhatch * 2 of them),
  546. the array contains 4 elements specifying: `fatness', `color',
  547. X`offset', `repeat interval'. (Thus the array is of dimension
  548. numhatch * 2 * 4.)
  549. The `repeat interval' determines the distance between
  550. the lines in a set.  The `offset' parameter is used to shift all
  551. the lines in the set.
  552. Both of these parameters
  553. are in units of 1/100'ths of an inch (HATCHPERIN in vplot.h).
  554. Color and fatness are just as you'd expect.
  555. X.RE
  556. X.PP
  557. X.ft 3
  558. X.ne 5
  559. vp_message(string)
  560. X.br
  561. char *string;
  562. X.ft1
  563. X.RS
  564. X.PP
  565. Have the vplot filter issue the message given in ``string''.
  566. X.RE
  567. X.PP
  568. X.ft 3
  569. X.ne 5
  570. vp_move(x, y)
  571. X.br
  572. vp_umove(x, y)
  573. X.br
  574. float   x, y;
  575. X.ft1
  576. X.RS
  577. X.PP
  578. Resets the current position to (x,y),
  579. but doesn't actually draw anything. Used in conjunction with vp_draw(),
  580. vp_udraw(), or vp_where().
  581. Units are inches (vp_move) or user units (vp_umove).
  582. X.RE
  583. X.PP
  584. X.ft 3
  585. X.ne 4
  586. vp_orig(x0, y0)
  587. X.br
  588. float   x0, y0;
  589. X.ft1
  590. X.RS
  591. X.PP
  592. Sets where on the device screen (in inches) the origin
  593. of the user coordinate system will be plotted.
  594. The initial reference point is the lower left corner of
  595. the display area for style=STANDARD, and the upper left
  596. corner for style=ROTATED.
  597. X.RE
  598. X.PP
  599. X.ft 3
  600. X.ne 4
  601. vp_uorig(x0, y0)
  602. X.br
  603. float   x0, y0;
  604. X.ft1
  605. X.RS
  606. X.PP
  607. Assigns values, in user units, to the origin of the user coordinate
  608. system, whose location on the screen was set by the
  609. X.B vp_orig()
  610. command.
  611. X.RE
  612. X.PP
  613. X.ft 3
  614. X.ne 5
  615. vp_patload(ppi, nx, ny, ipat, raster)
  616. X.br
  617. int ppi, nx, ny, ipat;
  618. X.br
  619. int *raster;
  620. X.ft1
  621. X.RS
  622. X.PP
  623. Load a raster pattern as pattern number `ipat'.
  624. The pattern is designed at `ppi' pixels per inch.
  625. The raster pattern itself is in the array `raster',
  626. which is an array of color table numbers.
  627. It will be represented on the display scanned TV-style, starting
  628. in the upper left hand corner and working left-to-right (up to ny)
  629. and then top-to-bottom (up to nx scan lines).
  630. X.RE
  631. X.PP
  632. X.ft 3
  633. X.ne 5
  634. vp_pendn(x, y)
  635. X.br
  636. vp_upendn(x, y)
  637. X.br
  638. float   x, y;
  639. X.ft1
  640. X.RS
  641. X.PP
  642. Move to the location (x, y) in inches (vp_pendn) or user units
  643. X(vp_upendn) and then put the pen down.
  644. X.RE
  645. X.PP
  646. X.ft 3
  647. X.ne 4
  648. vp_penup()
  649. X.ft1
  650. X.RS
  651. X.PP
  652. Pick the pen up.
  653. X.RE
  654. X.PP
  655. X.ft 3
  656. X.ne 6
  657. vp_pline(xp, yp, npts)
  658. X.br
  659. vp_upline(xp, yp, npts)
  660. X.br
  661. float *xp, *yp;
  662. X.br
  663. int npts;
  664. X.ft1
  665. X.RS
  666. X.PP
  667. Draw a polyline through the points given in the `xp' and `yp'
  668. arrays.
  669. X.RE
  670. X.PP
  671. X.ne 6
  672. X.ft 3
  673. vp_plot(x,y,down)
  674. X.br
  675. vp_uplot(x,y,down)
  676. X.br
  677. float x, y;
  678. X.br
  679. int down;
  680. X.ft1
  681. X.RS
  682. X.PP
  683. Draw a vector from the current position to (x, y) with the
  684. pen up (`down' = 0) or down (`down' = 1).  Uses the current line
  685. style.  (Fat, dashed lines may look odd on some devices.)
  686. Usually called by other
  687. X.B libvplot
  688. functions, not by user programs.
  689. X.RE
  690. X.PP
  691. X.ft 3
  692. X.ne 7
  693. vp_pmark(npts, mtype, msize, xp, yp)
  694. X.br
  695. vp_upmark(npts, mtype, msize, xp, yp)
  696. X.br
  697. int npts, mtype, msize;
  698. X.br
  699. float *xp, *yp;
  700. X.ft1
  701. X.RS
  702. X.PP
  703. Plot `npts' polymarkers, of type `mtype' and size `msize'.
  704. X`xp' and `yp' are arrays of x and y values in inches (vp_pmark)
  705. or user units (vp_upmark).  `msize' is in vplot text height units.
  706. X`Mtype' gives the following special symbols from font 15
  707. for these special values:
  708. X2, plus; 3, asterisk; 4, circle; 5, cross; 20, square;
  709. X21, triangle; 22, diamond; 23, star.
  710. X`mtype' = 0 or 1 sets a single pixel, the smallest displayable dot.
  711. Other values of `mtype' refer to glyph numbers in the
  712. current font (which should be compatible with ASCII for most fonts).
  713. X.RE
  714. X.PP
  715. X.ft 3
  716. X.ne 3
  717. vp_purge()
  718. X.ft 1
  719. X.RS
  720. X.br
  721. Flush the output buffer.  Flushes both the vplot stream and the
  722. device stream.
  723. X.RE
  724. X.ft 3
  725. X.ne 7
  726. vp_raster (array, blast, bit, offset, xpix, ypix, xll, yll,
  727. ppi, xur, yur, orient, invert)
  728. X.br
  729. vp_uraster (array, blast, bit, offset, xpix, ypix, xll, yll,
  730. ppi, xur, yur, orient, invert)
  731. X.br
  732. unsigned char  *array;
  733. X.br
  734. float   xll, yll, *xur, *yur, ppi;
  735. X.br
  736. int     xpix, ypix, bit, offset, blast, orient, invert;
  737. X.ft1
  738. X.RS
  739. X.PP
  740. Display the raster data pointed to by `array'.
  741. X.TP 10
  742. blast
  743. If `blast' = 1, don't try to compact the output.  If `blast' = 0,
  744. compaction will be done. Compaction
  745. does run-length encoding and compacts repeated lines.
  746. Compaction can make the vplot file considerably smaller, but
  747. it also takes longer to create the file.
  748. X.TP 10
  749. bit
  750. If `bit' = 1, the raster is saved as one bit per pixel;
  751. if `bit' = 0, as one byte per pixel.  Byte raster is faster!
  752. X.TP 10
  753. X[xy]pix
  754. X`xpix', `ypix': Number of pixels in each direction.
  755. X.TP 10
  756. X[xy]ll
  757. X`xll', `yll': The display coordinates of the lower left corner of the
  758. array, in inches (vp_raster) or user units (vp_uraster).
  759. X.TP 10
  760. ppi
  761. X`ppi': If `ppi' is non-zero, scale the image by duplicating or 
  762. dropping image pixels to a factor of `ppi' output pixels per inch.
  763. The point (xur, yur) is returned as the upper right hand corner.
  764. If `ppi' is zero, use whatever resolution is required to make
  765. X(xur, yur), which must then be supplied, the upper right hand corner.
  766. X.TP 10
  767. X[xy]ur
  768. X`xur', `yur': The display coordinates of the upper right corner (Well,
  769. actually, not quite. Read the vplotraster manual page.).
  770. Either in inches (vp_raster) or
  771. user units (vp_uraster). These two variables should NOT be arrays in
  772. FORTRAN, despite being declared `float *' for C.
  773. Note that `xll' <= `xur', `yll' <= `yur'.
  774. X.TP 10
  775. array
  776. X`array': The `array' contains values from 0 to 255.  For byte raster
  777. these values have `offset' added to them and then they
  778. are interpreted as color values.  For bit raster, a value
  779. of 0 is interpreted as color 0, and anything else is interpreted
  780. as color `offset'.
  781. X.TP 10
  782. orient
  783. For `orient' = 0 and `invert' = 0, the array
  784. is drawn on the screen television style.  The filling starts
  785. from the upper left and works to the right and then down.
  786. X`Orient' 1 rotates this 90 degrees clockwise, `orient' 2 180 
  787. degrees, etc.
  788. X.TP 10
  789. invert
  790. X`Invert' reverses the `array' over the slow axis.  The data
  791. occupies the same area of the output regardless of the value
  792. of `orient' and `invert'.
  793. X.RS
  794. Note that the point (xll, yll) is the lower
  795. leftmost pixel of the data, whereas the point (xur, yur) is
  796. one to the right and above the upper rightmost pixel of the 
  797. data.
  798. This is so that (xur-xll) and (yur-yll) give the length of the
  799. two dimensions of the data box.
  800. X.RE
  801. X.TP 10
  802. offset
  803. The `offset' parameter is provided so that several different raster
  804. color tables can be maintained at once, perhaps from 0-255 for ordinary
  805. colors and from 256-511 for a gray scale.
  806. X.RE
  807. X.PP
  808. X.ft 3
  809. X.ne 6
  810. vp_scale(xscl,yscl)
  811. X.br
  812. float xscl, yscl;
  813. X.ft1
  814. X.RS
  815. X.PP
  816. Set the scale of user units for the plot, in inches per user unit.
  817. X.RE
  818. X.PP
  819. X.ft 3
  820. X.ne 6
  821. vp_setdash(dashp,gapp,lp)
  822. X.br
  823. float *dashp, *gapp;
  824. X.br
  825. int   lp;
  826. X.ft1
  827. X.RS
  828. X.PP
  829. Set the dashed line pattern. The pattern is set to 
  830. dashp[0], gapp[0], dashp[1], gapp[1], ..., dashp[lp-1], gapp[lp-1],
  831. where dashp contains the lengths of the solid-line segments (dashes) of the
  832. pattern and gapp contains the lengths of the gaps between
  833. dashes. All lengths must be specified in INCHES. This dashing will be done
  834. either by the device hardware itself or by code in the pen filter. This
  835. dash pattern will be of the specified size in inches regardless of any
  836. scaling done to the plot as a whole!
  837. X.PP
  838. Generally, unless you have some reason to require that the dash pattern
  839. scale exactly with the size of the plot, vp_setdash is preferable to vp_dash.
  840. This is especially true when using devices that support
  841. fat dashed lines in hardware.
  842. X.RE
  843. X.PP
  844. X.ft 3
  845. X.ne 6
  846. vp_stretch(xmin,ymin,xmax,ymax)
  847. X.br
  848. float xmin, ymin, xmax, ymax;
  849. X.ft1
  850. X.RS
  851. X.PP
  852. This routine makes calls to vp_orig, vp_uorig, and vp_scale for you so that
  853. X(xmin,ymin) is the user coordinate of the lower left hand corner of the output
  854. space and (xmax,ymax) is the user coordinate of the upper right hand corner.
  855. X.PP
  856. As an example, suppose that you want to display everything in the unit box
  857. X(0. to 1.) on both axes, but that you also want your coordinate system to
  858. remain isotropic. You would call
  859. X.br
  860. vp_stretch(0.,0.,1./SCREENRATIO,1.);
  861. X.RE
  862. X.PP
  863. X.ft 3
  864. X.ne 4
  865. vp_style(st)
  866. X.br
  867. int     st;
  868. X.ft1
  869. X.RS
  870. X.PP
  871. Set the overall display style.  Choices are:
  872. X    
  873. X.TP 13
  874. STANDARD
  875. X(default, for terminals) Origin in lower left,
  876. scaled so that the maximum Y value (top of the screen)
  877. is 10.24 (STANDARD_HEIGHT) `inches'.
  878. X.TP 13
  879. ABSOLUTE
  880. X(default, for plotters) Origin in lower left,
  881. plotted in actual inches on the device.
  882. X.TP 13
  883. ROTATED
  884. Origin in upper left, Y-axis horizontal increasing to the right,
  885. XX-axis vertical and increasing down,
  886. scaled so that the maximum X value (bottom of the screen) is
  887. X7.5 (ROTATED_HEIGHT) `inches'. 
  888. X.RE
  889. X.PP
  890. I write `inches' because unless absolute scaling is being used vplot's
  891. X`inches' do not correspond to real, physical inches on the device screen.
  892. X.PP
  893. Note that the STANDARD style scales the output so a square
  894. X10.24 inches on a side will fit on the terminal screen.
  895. This allows a full 8.5x11-inch image to be shown on most
  896. terminals.
  897. The magic numbers 10.24 and 7.5 are defined in
  898. X.B vplot.h.
  899. More about coordinate systems can be found in the Vplot manual page.
  900. The plot style reverts to the default at the start of every frame.
  901. X.RE
  902. X.PP
  903. X.ft 3
  904. X.ne 7
  905. vp_text(x, y, size, orient, string)
  906. X.br
  907. vp_utext(x, y, size, orient, string)
  908. X.br
  909. float x, y;
  910. X.br
  911. int size, orient;
  912. X.br
  913. char *string;
  914. X.ft1
  915. X.RS
  916. X.PP
  917. Display text, using the currently-defined font, precision, and
  918. text alignment.
  919. X.TP 10
  920. x, y:
  921. The coordinates of the reference point for the string.
  922. Either in inches (vp_text) or user units (vp_utext).
  923. X.TP 10
  924. size:
  925. Height of a character, 33 (TXPERIN in vplot.h) units per inch (!!!).
  926. X.TP 10
  927. orient:
  928. Text drawing direction, in degrees counter-clockwise
  929. from horizontal, right-facing.
  930. X.TP 10
  931. string:
  932. The text string that is to be displayed.
  933. X`man vplottext' explains the many special escape sequences
  934. recognized by the generic vplot text routine gentext.
  935. X.RE
  936. X.PP
  937. X.ft 3
  938. X.ne 7
  939. vp_gtext(x, y, xpath, ypath, xup, yup, string)
  940. X.br
  941. vp_ugtext(x, y, xpath, ypath, xup, yup, string)
  942. X.br
  943. float x, y;
  944. X.br
  945. float xpath, ypath;
  946. X.br
  947. float xup, yup;
  948. X.br
  949. char *string;
  950. X.ft1
  951. X.RS
  952. X.PP
  953. Display text, using the currently-defined font, precision, and
  954. text alignment. The text coordinate system is defined in the GKS
  955. standard.
  956. X.TP 10
  957. x, y:
  958. The coordinates of the reference point for the string.
  959. Either in inches (vp_gtext) or user units (vp_ugtext).
  960. X.TP 10
  961. xpath, ypath:
  962. A vector pointing in the direction the text string will extend.
  963. Either in inches (vp_gtext) or user units (vp_ugtext).
  964. X.TP 10
  965. xup, yup:
  966. A vector pointing in the ``up'' direction for individual letters.
  967. Either in inches (vp_gtext) or user units (vp_ugtext).
  968. X.PP
  969. For normal, unstretched text, the up vector is 90 degrees
  970. counterclockwise from the path vector, and both vectors are the
  971. same length. This length is the text size. Projecting
  972. these two vectors will project the entire text string accordingly.
  973. X.TP 10
  974. string:
  975. The text string to be displayed, just as in the other text command.
  976. X.RE
  977. X.PP
  978. X.ft 3
  979. X.ne 4
  980. vp_tfont(font, prec, ovly)
  981. X.br
  982. int font, prec, ovly;
  983. X.ft1
  984. X.RS
  985. X.PP
  986. Choose the font to be used for output. (All the following values
  987. are defined in vplot.h.)
  988. X.TP 10
  989. font:
  990. Which font to use.  Sixteen software fonts are defined (if you have
  991. the Hershey fonts installed, otherwise you've only got font 0. You may
  992. also have hardware fonts starting at 100 (NUMGENFONT in params.h)
  993. available on some devices).
  994. The fonts names are defined in vplot.h.
  995. Font 0 (PEN in vplot.h), the traditional
  996. vplot font, is fastest and is the default on terminals (unless they have
  997. an even faster hardware font).
  998. Another better-looking font should be the default on hard copy devices.
  999. NO_CHANGE leaves the font unchanged from that in effect before the call.
  1000. X.TP 10
  1001. prec:
  1002. Font precision. This doesn't matter much if you're using a software
  1003. font to begin with. `Prec' is one of
  1004. X.RS
  1005. X.TP 13
  1006. STRING
  1007. Use the hardware text capabilities to write the whole string. 
  1008. The default for screen devices.
  1009. X.TP 13
  1010. CHAR
  1011. Use hardware characters, but position them individually.
  1012. X.TP 13
  1013. STROKE
  1014. Software text. This should be the default for hardcopy devices.
  1015. Ligatures in the Vplot software fonts are only enabled at STROKE
  1016. precision. (See the vplottext manual page for more about this.)
  1017. X.TP 13
  1018. NO_CHANGE
  1019. Use the previous value.
  1020. X.RE
  1021. X.TP 10
  1022. ovly:
  1023. Overlay mode:
  1024. X.RS
  1025. X.TP 13
  1026. OVLY_NORMAL:
  1027. just draw the text over what's there in the standard way;
  1028. X.TP 13
  1029. OVLY_BOX:
  1030. draw a box around the text first;
  1031. X.TP 13
  1032. OVLY_SHADE:
  1033. clear a box under the text first;
  1034. X.TP 13
  1035. OVLY_SHADE_BOX:
  1036. box the text and clear under it too;
  1037. X.TP 13
  1038. NO_CHANGE:
  1039. use the previous value.
  1040. X.RE
  1041. X.RE
  1042. X.PP
  1043. X.ft 3
  1044. X.ne 4
  1045. vp_tjust(hjust, vjust)
  1046. X.br
  1047. int hjust, vjust;
  1048. X.ft1
  1049. X.RS
  1050. X.PP
  1051. Set the position of the reference point for locating strings or
  1052. characters.  Choices are (these are defined in vplot.h):
  1053. X
  1054. hjust:
  1055. X.RS
  1056. X.TP 14
  1057. TH_NORMAL
  1058. Use the default.
  1059. X.TP 14
  1060. TH_LEFT
  1061. Left justify.
  1062. X.TP 14
  1063. TH_CENTER
  1064. Center the string.
  1065. X.TP 14
  1066. TH_RIGHT
  1067. Right justify.
  1068. X.TP 14
  1069. TH_SYMBOL
  1070. Position the character for use as a symbol marking the point.
  1071. X.br
  1072. X.RE
  1073. X
  1074. vjust:
  1075. X.RS
  1076. X.TP 14
  1077. TV_NORMAL
  1078. Use the default.
  1079. X.TP 14
  1080. TV_BOTTOM
  1081. Reference point is at the bottom of the letters.
  1082. X.TP 14
  1083. TV_BASE
  1084. Reference point is at the bottom of the
  1085. descenders.
  1086. X.TP 14
  1087. TV_HALF
  1088. Centered.
  1089. X.TP 14
  1090. TV_TOP
  1091. Reference point at the top of the writing area,
  1092. including space above letters.
  1093. X.TP 14
  1094. TV_CAP
  1095. Reference point is at the tops of capital
  1096. letters.
  1097. X.TP 14
  1098. TV_SYMBOL
  1099. Position the character for use as a symbol marking the point.
  1100. X.RE
  1101. X
  1102. X.br
  1103. It is possible to change font size, change font, and do many other
  1104. tricks ``on the fly'' by including escape codes in the text string.
  1105. See the vplottext manual page for information about the details of
  1106. interpretation of special characters within vplot text.
  1107. X.RE
  1108. X.PP
  1109. X.ft 3
  1110. X.ne 4
  1111. vp_where(x,y)
  1112. X.br
  1113. float *x, *y;
  1114. X.PP
  1115. X.ft 1
  1116. X.RS
  1117. Return the current position, in inches. Fortran users note that x and y
  1118. are not arrays, despite being declared `float *' in C.
  1119. X.RE
  1120. X.SH ACCESSING VPLOTLIB VARIABLES
  1121. X.PP
  1122. At present, few inquiry functions are provided by
  1123. X.B libvplot.
  1124. It would be wonderful if someone could turn the one-way
  1125. pipes into two-way sockets and provide some. The changes required to
  1126. the pen filters themselves would be minimal, as the required device
  1127. dependent structures already exist.
  1128. X.PP
  1129. The current values of the global parameters used in libvplot
  1130. are stored in the external structure
  1131. X.B vp_pc.
  1132. This structure is defined
  1133. in the file vp_pc.h, which is ``#include''ed by the libvplot routines
  1134. that need to refer to the variables in vp_pc. User programs should
  1135. probably have no need to do this.
  1136. X.SH MAGIC NUMBERS
  1137. The magic numbers (200, 100, 33, 7.5, 10.24, etc) used in this
  1138. document are subject to being changed at new sites. At Stanford we
  1139. are forced to live with these off-the-wall numbers in order to not
  1140. break a large mass of ancient code. They are all defined in ``vplot.h''
  1141. X(which should be in /usr/include, and which you should probably #include)
  1142. and ``params.h'' (which you probably don't need to worry about).
  1143. X
  1144. I would have loved to have turned everything into inches or centimeters,
  1145. but it just wasn't possible here. It is especially annoying that text
  1146. is currently quantized in such rough units. Sometimes it is impossible to get
  1147. text the exact size you need!
  1148. X.SH COPYRIGHT
  1149. The Vplot code is copyrighted. Refer to the Vplot manual page for the
  1150. official copyright notice.
  1151. X.SH SEE ALSO
  1152. pen(9), vplot(9), vplottext(9), vplotraster(9), plas, pldb
  1153. X.SH AUTHOR
  1154. Dave Hale, Joe Dellinger, Chuck Karish, and Steve Cole
  1155. X.SH LIMITATIONS
  1156. X.PP
  1157. Vector fonts and hardware fonts cannot be intermixed in a single
  1158. string.
  1159. X.PP
  1160. Inquiry functions should be provided.
  1161. X.PP
  1162. Vpunit() only works under 4.x BSD FORTRAN.
  1163. X.PP
  1164. Vplot.h should have defines for the various special markers.
  1165. X.SH BUGS
  1166. X.PP
  1167. None, that I know of. It is likely that some of the lesser-used FORTRAN
  1168. routines still harbor bugs.
  1169. END_OF_FILE
  1170. if test 28451 -ne `wc -c <'Vplot_Kernel/Documentation/libvplot.mn'`; then
  1171.     echo shar: \"'Vplot_Kernel/Documentation/libvplot.mn'\" unpacked with wrong size!
  1172. fi
  1173. # end of 'Vplot_Kernel/Documentation/libvplot.mn'
  1174. fi
  1175. if test -f 'Vplot_Kernel/lvplot/vp_ufill.c' -a "${1}" != "-c" ; then 
  1176.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_ufill.c'\"
  1177. else
  1178. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_ufill.c'\" \(627 characters\)
  1179. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_ufill.c' <<'END_OF_FILE'
  1180. X/*
  1181. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1182. X * University. Official permission to use this software is included in
  1183. X * the documentation. It authorizes you to use this file for any
  1184. X * non-commercial purpose, provided that this copyright notice is not
  1185. X * removed and that any modifications made to this file are commented
  1186. X * and dated in the style of my example below.
  1187. X */
  1188. X
  1189. X/*
  1190. X *
  1191. X *  source file:   ./lvplot/vp_ufill.c
  1192. X *
  1193. X * Joe Dellinger (SEP), June 11 1987
  1194. X *    Inserted this sample edit history entry.
  1195. X *    Please log any further modifications made to this file:
  1196. X */
  1197. X
  1198. X#define UUU
  1199. X#include "vp_fill.c"
  1200. END_OF_FILE
  1201. if test 627 -ne `wc -c <'Vplot_Kernel/lvplot/vp_ufill.c'`; then
  1202.     echo shar: \"'Vplot_Kernel/lvplot/vp_ufill.c'\" unpacked with wrong size!
  1203. fi
  1204. # end of 'Vplot_Kernel/lvplot/vp_ufill.c'
  1205. fi
  1206. if test -f 'Vplot_Kernel/lvplot/vp_umove.c' -a "${1}" != "-c" ; then 
  1207.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_umove.c'\"
  1208. else
  1209. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_umove.c'\" \(627 characters\)
  1210. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_umove.c' <<'END_OF_FILE'
  1211. X/*
  1212. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1213. X * University. Official permission to use this software is included in
  1214. X * the documentation. It authorizes you to use this file for any
  1215. X * non-commercial purpose, provided that this copyright notice is not
  1216. X * removed and that any modifications made to this file are commented
  1217. X * and dated in the style of my example below.
  1218. X */
  1219. X
  1220. X/*
  1221. X *
  1222. X *  source file:   ./lvplot/vp_umove.c
  1223. X *
  1224. X * Joe Dellinger (SEP), June 11 1987
  1225. X *    Inserted this sample edit history entry.
  1226. X *    Please log any further modifications made to this file:
  1227. X */
  1228. X
  1229. X#define UUU
  1230. X#include "vp_move.c"
  1231. END_OF_FILE
  1232. if test 627 -ne `wc -c <'Vplot_Kernel/lvplot/vp_umove.c'`; then
  1233.     echo shar: \"'Vplot_Kernel/lvplot/vp_umove.c'\" unpacked with wrong size!
  1234. fi
  1235. # end of 'Vplot_Kernel/lvplot/vp_umove.c'
  1236. fi
  1237. if test -f 'Vplot_Kernel/lvplot/vp_uorig.c' -a "${1}" != "-c" ; then 
  1238.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_uorig.c'\"
  1239. else
  1240. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_uorig.c'\" \(627 characters\)
  1241. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_uorig.c' <<'END_OF_FILE'
  1242. X/*
  1243. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1244. X * University. Official permission to use this software is included in
  1245. X * the documentation. It authorizes you to use this file for any
  1246. X * non-commercial purpose, provided that this copyright notice is not
  1247. X * removed and that any modifications made to this file are commented
  1248. X * and dated in the style of my example below.
  1249. X */
  1250. X
  1251. X/*
  1252. X *
  1253. X *  source file:   ./lvplot/vp_uorig.c
  1254. X *
  1255. X * Joe Dellinger (SEP), June 11 1987
  1256. X *    Inserted this sample edit history entry.
  1257. X *    Please log any further modifications made to this file:
  1258. X */
  1259. X
  1260. X#define UUU
  1261. X#include "vp_orig.c"
  1262. END_OF_FILE
  1263. if test 627 -ne `wc -c <'Vplot_Kernel/lvplot/vp_uorig.c'`; then
  1264.     echo shar: \"'Vplot_Kernel/lvplot/vp_uorig.c'\" unpacked with wrong size!
  1265. fi
  1266. # end of 'Vplot_Kernel/lvplot/vp_uorig.c'
  1267. fi
  1268. if test -f 'Vplot_Kernel/lvplot/vp_upendn.c' -a "${1}" != "-c" ; then 
  1269.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_upendn.c'\"
  1270. else
  1271. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_upendn.c'\" \(629 characters\)
  1272. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_upendn.c' <<'END_OF_FILE'
  1273. X/*
  1274. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1275. X * University. Official permission to use this software is included in
  1276. X * the documentation. It authorizes you to use this file for any
  1277. X * non-commercial purpose, provided that this copyright notice is not
  1278. X * removed and that any modifications made to this file are commented
  1279. X * and dated in the style of my example below.
  1280. X */
  1281. X
  1282. X/*
  1283. X *
  1284. X *  source file:   ./lvplot/vp_upendn.c
  1285. X *
  1286. X * Joe Dellinger (SEP), June 11 1987
  1287. X *    Inserted this sample edit history entry.
  1288. X *    Please log any further modifications made to this file:
  1289. X */
  1290. X
  1291. X#define UUU
  1292. X#include "vp_pendn.c"
  1293. END_OF_FILE
  1294. if test 629 -ne `wc -c <'Vplot_Kernel/lvplot/vp_upendn.c'`; then
  1295.     echo shar: \"'Vplot_Kernel/lvplot/vp_upendn.c'\" unpacked with wrong size!
  1296. fi
  1297. # end of 'Vplot_Kernel/lvplot/vp_upendn.c'
  1298. fi
  1299. if test -f 'Vplot_Kernel/lvplot/vp_upline.c' -a "${1}" != "-c" ; then 
  1300.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_upline.c'\"
  1301. else
  1302. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_upline.c'\" \(629 characters\)
  1303. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_upline.c' <<'END_OF_FILE'
  1304. X/*
  1305. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1306. X * University. Official permission to use this software is included in
  1307. X * the documentation. It authorizes you to use this file for any
  1308. X * non-commercial purpose, provided that this copyright notice is not
  1309. X * removed and that any modifications made to this file are commented
  1310. X * and dated in the style of my example below.
  1311. X */
  1312. X
  1313. X/*
  1314. X *
  1315. X *  source file:   ./lvplot/vp_upline.c
  1316. X *
  1317. X * Joe Dellinger (SEP), June 11 1987
  1318. X *    Inserted this sample edit history entry.
  1319. X *    Please log any further modifications made to this file:
  1320. X */
  1321. X
  1322. X#define UUU
  1323. X#include "vp_pline.c"
  1324. END_OF_FILE
  1325. if test 629 -ne `wc -c <'Vplot_Kernel/lvplot/vp_upline.c'`; then
  1326.     echo shar: \"'Vplot_Kernel/lvplot/vp_upline.c'\" unpacked with wrong size!
  1327. fi
  1328. # end of 'Vplot_Kernel/lvplot/vp_upline.c'
  1329. fi
  1330. if test -f 'Vplot_Kernel/lvplot/vp_upmark.c' -a "${1}" != "-c" ; then 
  1331.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_upmark.c'\"
  1332. else
  1333. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_upmark.c'\" \(629 characters\)
  1334. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_upmark.c' <<'END_OF_FILE'
  1335. X/*
  1336. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1337. X * University. Official permission to use this software is included in
  1338. X * the documentation. It authorizes you to use this file for any
  1339. X * non-commercial purpose, provided that this copyright notice is not
  1340. X * removed and that any modifications made to this file are commented
  1341. X * and dated in the style of my example below.
  1342. X */
  1343. X
  1344. X/*
  1345. X *
  1346. X *  source file:   ./lvplot/vp_upmark.c
  1347. X *
  1348. X * Joe Dellinger (SEP), June 11 1987
  1349. X *    Inserted this sample edit history entry.
  1350. X *    Please log any further modifications made to this file:
  1351. X */
  1352. X
  1353. X#define UUU
  1354. X#include "vp_pmark.c"
  1355. END_OF_FILE
  1356. if test 629 -ne `wc -c <'Vplot_Kernel/lvplot/vp_upmark.c'`; then
  1357.     echo shar: \"'Vplot_Kernel/lvplot/vp_upmark.c'\" unpacked with wrong size!
  1358. fi
  1359. # end of 'Vplot_Kernel/lvplot/vp_upmark.c'
  1360. fi
  1361. if test -f 'Vplot_Kernel/lvplot/vp_where.c' -a "${1}" != "-c" ; then 
  1362.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_where.c'\"
  1363. else
  1364. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_where.c'\" \(819 characters\)
  1365. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_where.c' <<'END_OF_FILE'
  1366. X/*
  1367. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1368. X * University. Official permission to use this software is included in
  1369. X * the documentation. It authorizes you to use this file for any
  1370. X * non-commercial purpose, provided that this copyright notice is not
  1371. X * removed and that any modifications made to this file are commented
  1372. X * and dated in the style of my example below.
  1373. X */
  1374. X
  1375. X/*
  1376. X *
  1377. X *  source file:   ./lvplot/vp_where.c
  1378. X *
  1379. X * Joe Dellinger (SEP), June 11 1987
  1380. X *    Inserted this sample edit history entry.
  1381. X *    Please log any further modifications made to this file:
  1382. X */
  1383. X
  1384. X#include <stdio.h>
  1385. X#include <vplot.h>
  1386. X#include "vp_pc.h"
  1387. X
  1388. X#ifdef FORTRAN
  1389. X
  1390. X#define WHERE vpwhere_
  1391. X
  1392. X#else
  1393. X
  1394. X#define WHERE vp_where
  1395. X
  1396. X#endif
  1397. X
  1398. WHERE (x, y)
  1399. X    float          *x, *y;
  1400. X{
  1401. X    *x = vp_pc._xold;
  1402. X    *y = vp_pc._yold;
  1403. X}
  1404. END_OF_FILE
  1405. if test 819 -ne `wc -c <'Vplot_Kernel/lvplot/vp_where.c'`; then
  1406.     echo shar: \"'Vplot_Kernel/lvplot/vp_where.c'\" unpacked with wrong size!
  1407. fi
  1408. # end of 'Vplot_Kernel/lvplot/vp_where.c'
  1409. fi
  1410. if test -f 'Vplot_Kernel/util/README' -a "${1}" != "-c" ; then 
  1411.   echo shar: Will not clobber existing file \"'Vplot_Kernel/util/README'\"
  1412. else
  1413. echo shar: Extracting \"'Vplot_Kernel/util/README'\" \(710 characters\)
  1414. sed "s/^X//" >'Vplot_Kernel/util/README' <<'END_OF_FILE'
  1415. This directory contains some utility routines which are useful
  1416. when editing vplot files by hand. They self document.
  1417. X
  1418. You will need to edit the makefile to tailor it to your machine.
  1419. X
  1420. X"tube.example" is provided as an example of a simple shell that can
  1421. pick the proper Vplot filter for you, so you can just type "tube"
  1422. and have it work on any device.
  1423. X
  1424. X"Ta2vplot.c" is provided (it may be missing in your copy) as an example
  1425. of a program that scrambles the order of the colors for raster so that
  1426. the most important colors occupy the lowest part of the color table.
  1427. X(See the vplotraster manual page.) It is a SEPlib program, so don't
  1428. expect it to compile if you don't have SEPlib on your system.
  1429. X
  1430. X- Joe Dellinger
  1431. END_OF_FILE
  1432. if test 710 -ne `wc -c <'Vplot_Kernel/util/README'`; then
  1433.     echo shar: \"'Vplot_Kernel/util/README'\" unpacked with wrong size!
  1434. fi
  1435. # end of 'Vplot_Kernel/util/README'
  1436. fi
  1437. if test -f 'Vplot_Kernel/filters/loclib/sepwhere.c' -a "${1}" != "-c" ; then 
  1438.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/loclib/sepwhere.c'\"
  1439. else
  1440. echo shar: Extracting \"'Vplot_Kernel/filters/loclib/sepwhere.c'\" \(513 characters\)
  1441. sed "s/^X//" >'Vplot_Kernel/filters/loclib/sepwhere.c' <<'END_OF_FILE'
  1442. X/*
  1443. X *
  1444. X *  source file:   ./filters/loclib/sepwhere.c
  1445. X *
  1446. X * Joe Dellinger (SEP), Feb 12 1988
  1447. X *    Inserted this sample edit history entry.
  1448. X *    Please log any further modifications made to this file:
  1449. X */
  1450. X
  1451. X/*
  1452. X * If for some reason the default places for the output and header to
  1453. X * go aren't suitable, link in your own version of this routine
  1454. X * ahead of this one.
  1455. X */
  1456. char            sepoutwhere[] = "/dev/tty";
  1457. char            sepheadwhere[] = "/dev/null";
  1458. X
  1459. X/* Make linker happy that it found it. */
  1460. sepwhere ()
  1461. X{
  1462. X};
  1463. END_OF_FILE
  1464. if test 513 -ne `wc -c <'Vplot_Kernel/filters/loclib/sepwhere.c'`; then
  1465.     echo shar: \"'Vplot_Kernel/filters/loclib/sepwhere.c'\" unpacked with wrong size!
  1466. fi
  1467. # end of 'Vplot_Kernel/filters/loclib/sepwhere.c'
  1468. fi
  1469. if test -f 'Vplot_Kernel/filters/makedist' -a "${1}" != "-c" ; then 
  1470.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/makedist'\"
  1471. else
  1472. echo shar: Extracting \"'Vplot_Kernel/filters/makedist'\" \(478 characters\)
  1473. sed "s/^X//" >'Vplot_Kernel/filters/makedist' <<'END_OF_FILE'
  1474. X    #!/bin/sh
  1475. X    #
  1476. X    # Write a vplot distribution tar file.
  1477. X    #
  1478. X    # Usage:
  1479. X    # makedist outfile
  1480. X    #
  1481. X    # This will write a tar file to disk.
  1482. X    #
  1483. X    # Author - Chuck Karish
  1484. X    #
  1485. X
  1486. if [ $# -ne 1 ]
  1487. then
  1488. X    echo "Usage: makedist tar_file_name"
  1489. X    exit 1
  1490. fi
  1491. X
  1492. tar cvf $1 *.c MakeMake* machdep machdepsep hosttype distribute_to makedist \
  1493. X    README
  1494. X
  1495. for direct in *lib include utilities machines Tests
  1496. do
  1497. X    tar rvf $1 \
  1498. X        ` find $direct -type f -print | \
  1499. X        egrep -v "(\\.a\$|\\.o\$|\\.bin|\\.include)" `
  1500. done
  1501. END_OF_FILE
  1502. if test 478 -ne `wc -c <'Vplot_Kernel/filters/makedist'`; then
  1503.     echo shar: \"'Vplot_Kernel/filters/makedist'\" unpacked with wrong size!
  1504. fi
  1505. # end of 'Vplot_Kernel/filters/makedist'
  1506. fi
  1507. if test -f 'Vplot_Kernel/filters/utilities/Makefile' -a "${1}" != "-c" ; then 
  1508.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/utilities/Makefile'\"
  1509. else
  1510. echo shar: Extracting \"'Vplot_Kernel/filters/utilities/Makefile'\" \(287 characters\)
  1511. sed "s/^X//" >'Vplot_Kernel/filters/utilities/Makefile' <<'END_OF_FILE'
  1512. X#
  1513. X#    Device-Independent Subroutines
  1514. X#
  1515. CFILES= clip.c error.c solve.c vptodev.c dupside.c sort.c\
  1516. X    intersect.c fatvec.c dashvec.c vecoutline.c dither.c\
  1517. X    greycorr.c
  1518. X
  1519. utillib.a: $(CFILES)
  1520. X    rm -f *.o
  1521. X    -cc -c $(CFLAGS) $?
  1522. X    ar crv utillib.a *.o
  1523. X    ranlib utillib.a
  1524. X    rm -f *.o
  1525. X
  1526. clean:
  1527. X    rm -f *.o
  1528. END_OF_FILE
  1529. if test 287 -ne `wc -c <'Vplot_Kernel/filters/utilities/Makefile'`; then
  1530.     echo shar: \"'Vplot_Kernel/filters/utilities/Makefile'\" unpacked with wrong size!
  1531. fi
  1532. # end of 'Vplot_Kernel/filters/utilities/Makefile'
  1533. fi
  1534. if test -f 'Vplot_Kernel/lvplot/README' -a "${1}" != "-c" ; then 
  1535.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/README'\"
  1536. else
  1537. echo shar: Extracting \"'Vplot_Kernel/lvplot/README'\" \(568 characters\)
  1538. sed "s/^X//" >'Vplot_Kernel/lvplot/README' <<'END_OF_FILE'
  1539. This directory contains the source for libvplot.
  1540. This is a set of C and FORTRAN bindings for the vplot
  1541. metalanguage.
  1542. X
  1543. The shell script "fixcplot" will convert from older vplotlib names
  1544. to the new, standardized names.
  1545. X
  1546. Hopefully all of these routines should work. It is quite possible
  1547. that some of the lesser-used ones may still harbor bugs.
  1548. The FORTRAN bindings are considerably less tested than the C ones.
  1549. X
  1550. You will need to edit the Makefile to tailor it for your site.
  1551. X
  1552. If you are using 4.3, you will have to #define FOURTHREEBSD when you compile.
  1553. X
  1554. X- Joe Dellinger
  1555. END_OF_FILE
  1556. if test 568 -ne `wc -c <'Vplot_Kernel/lvplot/README'`; then
  1557.     echo shar: \"'Vplot_Kernel/lvplot/README'\" unpacked with wrong size!
  1558. fi
  1559. # end of 'Vplot_Kernel/lvplot/README'
  1560. fi
  1561. if test -f 'Vplot_Kernel/util/Makefile' -a "${1}" != "-c" ; then 
  1562.   echo shar: Will not clobber existing file \"'Vplot_Kernel/util/Makefile'\"
  1563. else
  1564. echo shar: Extracting \"'Vplot_Kernel/util/Makefile'\" \(409 characters\)
  1565. sed "s/^X//" >'Vplot_Kernel/util/Makefile' <<'END_OF_FILE'
  1566. LOCLIB= ../filters/loclib/loclib.a
  1567. GROUP= graphics
  1568. B= /usr/local/
  1569. CFLAGS= -I../filters/include
  1570. X
  1571. all: plas pldb
  1572. X
  1573. install: all
  1574. X    install -m 555 -g $(GROUP) plas $Bplas
  1575. X    install -m 555 -g $(GROUP) pldb $Bpldb
  1576. X
  1577. plas.o:    plas.c
  1578. X    cc $(CFLAGS) -c -O plas.c
  1579. X
  1580. plas:    plas.o 
  1581. X    cc plas.o  -O $(LOCLIB) -lm -o plas
  1582. X
  1583. pldb.o:    pldb.c
  1584. X    cc $(CFLAGS) -c -O pldb.c
  1585. X
  1586. pldb: pldb.o
  1587. X    cc pldb.o -O $(LOCLIB) -lm -o pldb
  1588. X
  1589. clean:
  1590. X    rm *.o
  1591. END_OF_FILE
  1592. if test 409 -ne `wc -c <'Vplot_Kernel/util/Makefile'`; then
  1593.     echo shar: \"'Vplot_Kernel/util/Makefile'\" unpacked with wrong size!
  1594. fi
  1595. # end of 'Vplot_Kernel/util/Makefile'
  1596. fi
  1597. if test -f 'Vplot_Kernel/util/tube.example' -a "${1}" != "-c" ; then 
  1598.   echo shar: Will not clobber existing file \"'Vplot_Kernel/util/tube.example'\"
  1599. else
  1600. echo shar: Extracting \"'Vplot_Kernel/util/tube.example'\" \(564 characters\)
  1601. sed "s/^X//" >'Vplot_Kernel/util/tube.example' <<'END_OF_FILE'
  1602. X#!/bin/csh -f
  1603. X#
  1604. X# Keywords: graphics vplot tty
  1605. X#
  1606. X# Here is an example of a shell which will pick the appropriate
  1607. X# pen filter for the user's terminal, so he doesn't have to remember.
  1608. X#
  1609. X    if($TERM =~ gigi*) then
  1610. X    gigipen $* 
  1611. X    else if($TERM =~ envision220*) then
  1612. X    envipen $* 
  1613. X    else if($TERM =~ envision*) then
  1614. X    envipen wstype=envi215 $* 
  1615. X    else if($TERM =~ tek4105*) then
  1616. X    ctekpen $*
  1617. X    else if($TERM =~ grif* || $TERM == vt100 || $TERM == tek4014) then
  1618. X    tekpen $*
  1619. X    else if($TERM =~ D2) then
  1620. X    rpen $*
  1621. X    else
  1622. X    echo "tube: No Graphics available on that device\!\!"
  1623. X    endif
  1624. END_OF_FILE
  1625. echo shar: 1 control character may be missing from \"'Vplot_Kernel/util/tube.example'\"
  1626. if test 564 -ne `wc -c <'Vplot_Kernel/util/tube.example'`; then
  1627.     echo shar: \"'Vplot_Kernel/util/tube.example'\" unpacked with wrong size!
  1628. fi
  1629. chmod +x 'Vplot_Kernel/util/tube.example'
  1630. # end of 'Vplot_Kernel/util/tube.example'
  1631. fi
  1632. echo shar: End of archive 21 \(of 24\).
  1633. cp /dev/null ark21isdone
  1634. MISSING=""
  1635. for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 ; do
  1636.     if test ! -f ark${I}isdone ; then
  1637.     MISSING="${MISSING} ${I}"
  1638.     fi
  1639. done
  1640. if test "${MISSING}" = "" ; then
  1641.     echo You have unpacked all 24 archives.
  1642.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  1643. else
  1644.     echo You still need to unpack the following archives:
  1645.     echo "        " ${MISSING}
  1646. fi
  1647. ##  End of shell archive.
  1648. exit 0
  1649.