home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume14 / vplot / part05 < prev    next >
Encoding:
Internet Message Format  |  1988-03-28  |  60.7 KB

  1. Subject:  v14i010:  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 10
  8. Archive-name: vplot/part05
  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 5 (of 24)."
  17. # Wrapped by rsalz@fig.bbn.com on Fri Mar 25 11:46:43 1988
  18. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  19. if test -f 'Envision_device/envilib/enviopen.c' -a "${1}" != "-c" ; then 
  20.   echo shar: Will not clobber existing file \"'Envision_device/envilib/enviopen.c'\"
  21. else
  22. echo shar: Extracting \"'Envision_device/envilib/enviopen.c'\" \(1277 characters\)
  23. sed "s/^X//" >'Envision_device/envilib/enviopen.c' <<'END_OF_FILE'
  24. X/*
  25. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  26. X * University. Official permission to use this software is included in
  27. X * the documentation. It authorizes you to use this file for any
  28. X * non-commercial purpose, provided that this copyright notice is not
  29. X * removed and that any modifications made to this file are commented
  30. X * and dated in the style of my example below.
  31. X */
  32. X
  33. X/*
  34. X *
  35. X *  source file:   ./filters/envilib/enviopen.c
  36. X *
  37. X * Joe Dellinger (SEP), June 11 1987
  38. X *    Inserted this sample edit history entry.
  39. X *    Please log any further modifications made to this file:
  40. X */
  41. X
  42. X#include <stdio.h>
  43. X#include "../include/enum.h"
  44. X#include "../include/extern.h"
  45. X
  46. X
  47. extern int      want_bell;
  48. extern char     wstype[];
  49. extern int      vecarea ();
  50. int             version;
  51. X
  52. enviopen ()
  53. X{
  54. char            bell[10];
  55. X
  56. X    version = 220;
  57. X
  58. X/*
  59. X * physical device size that can be different on different models
  60. X */
  61. X    dev_ymax = 479;
  62. X
  63. X/*
  64. X * device capabilities
  65. X */
  66. X    need_end_erase = NO;
  67. X    buffer_output = YES;
  68. X    smart_clip = NO;
  69. X
  70. X    if (!strcmp (wstype, "envi215"))
  71. X    {
  72. X    version = 215;
  73. X    dev_ymax = 407;
  74. X    dev.area = vecarea;    /* 215's can't fill properly */
  75. X    }
  76. X    getpar ("bell", "s", bell);
  77. X    if (bell[0] == 'n')
  78. X    want_bell = 0;
  79. X    endpause = YES;
  80. X}
  81. END_OF_FILE
  82. if test 1277 -ne `wc -c <'Envision_device/envilib/enviopen.c'`; then
  83.     echo shar: \"'Envision_device/envilib/enviopen.c'\" unpacked with wrong size!
  84. fi
  85. # end of 'Envision_device/envilib/enviopen.c'
  86. fi
  87. if test -f 'Imagen_device/imaglib/imagattr.c' -a "${1}" != "-c" ; then 
  88.   echo shar: Will not clobber existing file \"'Imagen_device/imaglib/imagattr.c'\"
  89. else
  90. echo shar: Extracting \"'Imagen_device/imaglib/imagattr.c'\" \(1210 characters\)
  91. sed "s/^X//" >'Imagen_device/imaglib/imagattr.c' <<'END_OF_FILE'
  92. X/*
  93. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  94. X * University. Official permission to use this software is included in
  95. X * the documentation. It authorizes you to use this file for any
  96. X * non-commercial purpose, provided that this copyright notice is not
  97. X * removed and that any modifications made to this file are commented
  98. X * and dated in the style of my example below.
  99. X */
  100. X
  101. X/*
  102. X *
  103. X *  source file:   ./filters/imaglib/imagattr.c
  104. X *
  105. X * Joe Dellinger (SEP), June 11 1987
  106. X *    Inserted this sample edit history entry.
  107. X *    Please log any further modifications made to this file:
  108. X */
  109. X
  110. X#include <stdio.h>
  111. X#include "../include/attrcom.h"
  112. X#include "../include/params.h"
  113. X#include "imagen.h"
  114. X
  115. int             imag_curcolor = BLACK;
  116. X
  117. imagattributes (command, value, v1, v2, v3)
  118. X    register int    command, value;
  119. X    int             v1, v2, v3;
  120. X{
  121. int             new_imag_curcolor;
  122. X
  123. X    switch (command)
  124. X    {
  125. X    case SET_COLOR:
  126. X    if (value > 0)
  127. X        new_imag_curcolor = BLACK;
  128. X    else
  129. X        new_imag_curcolor = WHITE;
  130. X
  131. X    if (new_imag_curcolor != imag_curcolor)
  132. X    {
  133. X        endpath (DRAW_PATH, imag_curcolor);
  134. X        imag_curcolor = new_imag_curcolor;
  135. X    }
  136. X    break;
  137. X    default:
  138. X    break;
  139. X    }
  140. X
  141. X    return 0;
  142. X}
  143. END_OF_FILE
  144. if test 1210 -ne `wc -c <'Imagen_device/imaglib/imagattr.c'`; then
  145.     echo shar: \"'Imagen_device/imaglib/imagattr.c'\" unpacked with wrong size!
  146. fi
  147. # end of 'Imagen_device/imaglib/imagattr.c'
  148. fi
  149. if test -f 'RasterTek_device/rteklib/rtekarea.c' -a "${1}" != "-c" ; then 
  150.   echo shar: Will not clobber existing file \"'RasterTek_device/rteklib/rtekarea.c'\"
  151. else
  152. echo shar: Extracting \"'RasterTek_device/rteklib/rtekarea.c'\" \(1141 characters\)
  153. sed "s/^X//" >'RasterTek_device/rteklib/rtekarea.c' <<'END_OF_FILE'
  154. X/*
  155. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  156. X * University. Official permission to use this software is included in
  157. X * the documentation. It authorizes you to use this file for any
  158. X * non-commercial purpose, provided that this copyright notice is not
  159. X * removed and that any modifications made to this file are commented
  160. X * and dated in the style of my example below.
  161. X */
  162. X
  163. X/*
  164. X *
  165. X *  source file:   ./filters/rteklib/rtekarea.c
  166. X *
  167. X * Joe Dellinger (SEP), June 11 1987
  168. X *    Inserted this sample edit history entry.
  169. X *    Please log any further modifications made to this file:
  170. X */
  171. X
  172. X/* not used because POLYGON command defective */
  173. X#include "rtekpen.h"
  174. X#include "../include/vertex.h"
  175. X
  176. rtekarea (npts, head)
  177. X    int             npts;
  178. X    struct vertex  *head;
  179. X{
  180. int             i, x, y;
  181. X
  182. X    x = head->x;
  183. X    y = head->y;
  184. X/*
  185. X    rtekplot (x,y,0);
  186. X*/
  187. X    CHKLEN (8 + npts << 2);    /* cmdlen = 8+npts*4 */
  188. X    byte (PRMFIL);
  189. X    byte (1);
  190. X    byte (POLYGN);
  191. X    byte (1);
  192. X    word (npts);
  193. X    for (i = 0; i < npts; i++)
  194. X    {
  195. X    word (head->x - x);
  196. X    word (head->y - y);
  197. X    head = head->next;
  198. X    }
  199. X    byte (PRMFIL);
  200. X    byte (0);
  201. X}
  202. END_OF_FILE
  203. if test 1141 -ne `wc -c <'RasterTek_device/rteklib/rtekarea.c'`; then
  204.     echo shar: \"'RasterTek_device/rteklib/rtekarea.c'\" unpacked with wrong size!
  205. fi
  206. # end of 'RasterTek_device/rteklib/rtekarea.c'
  207. fi
  208. if test -f 'RasterTek_device/rteklib/rtekattr.c' -a "${1}" != "-c" ; then 
  209.   echo shar: Will not clobber existing file \"'RasterTek_device/rteklib/rtekattr.c'\"
  210. else
  211. echo shar: Extracting \"'RasterTek_device/rteklib/rtekattr.c'\" \(1165 characters\)
  212. sed "s/^X//" >'RasterTek_device/rteklib/rtekattr.c' <<'END_OF_FILE'
  213. X/*
  214. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  215. X * University. Official permission to use this software is included in
  216. X * the documentation. It authorizes you to use this file for any
  217. X * non-commercial purpose, provided that this copyright notice is not
  218. X * removed and that any modifications made to this file are commented
  219. X * and dated in the style of my example below.
  220. X */
  221. X
  222. X/*
  223. X *
  224. X *  source file:   ./filters/rteklib/rtekattr.c
  225. X *
  226. X * Joe Dellinger (SEP), June 11 1987
  227. X *    Inserted this sample edit history entry.
  228. X *    Please log any further modifications made to this file:
  229. X */
  230. X
  231. X#include "rtekpen.h"
  232. X#include "../include/attrcom.h"
  233. X
  234. int             color = 7;
  235. X
  236. rtekattributes (command, v, v1, v2, v3)
  237. X    int             command, v, v1, v2, v3;
  238. X{
  239. X    switch (command)
  240. X    {
  241. X    case SET_COLOR:        /* cmdlen = 2 */
  242. X    CHKLEN (2);
  243. X    color = v;
  244. X    byte (VAL8);
  245. X    byte (v);
  246. X    break;
  247. X    case SET_COLOR_TABLE:    /* cmdlen = 5 */
  248. X    CHKLEN (5);
  249. X    byte (LUT8);
  250. X    byte (v);
  251. X    byte (v1);
  252. X    byte (v2);
  253. X    byte (v3);
  254. X    break;
  255. X    case SET_WINDOW:        /* cmdlen = 9 */
  256. X    CHKLEN (9);
  257. X    byte (WINDOW);
  258. X    word (v);
  259. X    word (v1);
  260. X    word (v2);
  261. X    word (v3);
  262. X    break;
  263. X    }
  264. X
  265. X    return 0;
  266. X}
  267. END_OF_FILE
  268. if test 1165 -ne `wc -c <'RasterTek_device/rteklib/rtekattr.c'`; then
  269.     echo shar: \"'RasterTek_device/rteklib/rtekattr.c'\" unpacked with wrong size!
  270. fi
  271. # end of 'RasterTek_device/rteklib/rtekattr.c'
  272. fi
  273. if test -f 'Regis_device/gigilib/gigigetpoint.c' -a "${1}" != "-c" ; then 
  274.   echo shar: Will not clobber existing file \"'Regis_device/gigilib/gigigetpoint.c'\"
  275. else
  276. echo shar: Extracting \"'Regis_device/gigilib/gigigetpoint.c'\" \(1212 characters\)
  277. sed "s/^X//" >'Regis_device/gigilib/gigigetpoint.c' <<'END_OF_FILE'
  278. X/*
  279. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  280. X * University. Official permission to use this software is included in
  281. X * the documentation. It authorizes you to use this file for any
  282. X * non-commercial purpose, provided that this copyright notice is not
  283. X * removed and that any modifications made to this file are commented
  284. X * and dated in the style of my example below.
  285. X */
  286. X
  287. X/*
  288. X *
  289. X *  source file:   ./filters/gigilib/gigigetpoint.c
  290. X *
  291. X * Joe Dellinger (SEP), June 11 1987
  292. X *    Inserted this sample edit history entry.
  293. X *    Please log any further modifications made to this file:
  294. X */
  295. X
  296. X#include <stdio.h>
  297. X
  298. extern FILE    *pltout;
  299. X
  300. extern int      dev_xmax, dev_ymax, dev_xmin, dev_ymin;
  301. extern int      lost;    /* used by genvector */
  302. X
  303. gigigetpoint (termout, x, y)
  304. X    FILE           *termout;
  305. X    int            *x, *y;
  306. X{
  307. int             itemp;
  308. char            temp[10];
  309. X
  310. X    fflush (pltout);
  311. X    fprintf (pltout, "r(p(i))");
  312. X    fflush (pltout);
  313. X    fscanf (termout, "%[^0123456789]%d,%d]%*c", temp, y, x);
  314. X
  315. X/* Undo the GIGI's perverse coordinate system */
  316. X    *x = *x / 2;
  317. X    *y = *y / 2;
  318. X
  319. X    itemp = *y;
  320. X    *y = dev_ymin + dev_ymax - *x;
  321. X    *x = itemp;
  322. X    lost = 1;
  323. X    return (0);
  324. X}
  325. END_OF_FILE
  326. if test 1212 -ne `wc -c <'Regis_device/gigilib/gigigetpoint.c'`; then
  327.     echo shar: \"'Regis_device/gigilib/gigigetpoint.c'\" unpacked with wrong size!
  328. fi
  329. # end of 'Regis_device/gigilib/gigigetpoint.c'
  330. fi
  331. if test -f 'Regis_device/gigilib/gigipoly.c' -a "${1}" != "-c" ; then 
  332.   echo shar: Will not clobber existing file \"'Regis_device/gigilib/gigipoly.c'\"
  333. else
  334. echo shar: Extracting \"'Regis_device/gigilib/gigipoly.c'\" \(1254 characters\)
  335. sed "s/^X//" >'Regis_device/gigilib/gigipoly.c' <<'END_OF_FILE'
  336. X/*
  337. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  338. X * University. Official permission to use this software is included in
  339. X * the documentation. It authorizes you to use this file for any
  340. X * non-commercial purpose, provided that this copyright notice is not
  341. X * removed and that any modifications made to this file are commented
  342. X * and dated in the style of my example below.
  343. X */
  344. X
  345. X/*
  346. X *
  347. X *  source file:   ./filters/gigilib/gigipoly.c
  348. X *
  349. X * Joe Dellinger (SEP), June 11 1987
  350. X *    Inserted this sample edit history entry.
  351. X *    Please log any further modifications made to this file:
  352. X * Joe Dellinger Feb 16 1988
  353. X *    Fixed bug in call to gigiplot
  354. X */
  355. X
  356. X#include <stdio.h>
  357. X#include "gigi.h"
  358. extern FILE    *pltout;
  359. X
  360. int             in_a_poly = 0;
  361. X
  362. static int      need_set_shade = 0;
  363. X
  364. gigistartpoly (npts)
  365. X    int             npts;
  366. X{
  367. X    lost = 1;
  368. X    need_set_shade = 1;
  369. X    in_a_poly = 1;
  370. X    if (lastop != 'P')
  371. X    fprintf (pltout, "P");
  372. X}
  373. X
  374. gigimidpoly (x, y)
  375. X    int             x, y;
  376. X{
  377. X    gigiplot (x, y, 0);
  378. X    if (need_set_shade == 1)
  379. X    {
  380. X    need_set_shade = 0;
  381. X    fprintf (pltout, "V@W(W(S1))");
  382. X    lastop = 'V';
  383. X    }
  384. X}
  385. X
  386. gigiendpoly (last)
  387. X    int             last;
  388. X{
  389. X    fprintf (pltout, "(W(S0))V@W");
  390. X    lost = 1;
  391. X    in_a_poly = 0;
  392. X}
  393. END_OF_FILE
  394. if test 1254 -ne `wc -c <'Regis_device/gigilib/gigipoly.c'`; then
  395.     echo shar: \"'Regis_device/gigilib/gigipoly.c'\" unpacked with wrong size!
  396. fi
  397. # end of 'Regis_device/gigilib/gigipoly.c'
  398. fi
  399. if test -f 'Tek_device/cteklib/ctekreset.c' -a "${1}" != "-c" ; then 
  400.   echo shar: Will not clobber existing file \"'Tek_device/cteklib/ctekreset.c'\"
  401. else
  402. echo shar: Extracting \"'Tek_device/cteklib/ctekreset.c'\" \(1248 characters\)
  403. sed "s/^X//" >'Tek_device/cteklib/ctekreset.c' <<'END_OF_FILE'
  404. X/*
  405. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  406. X * University. Official permission to use this software is included in
  407. X * the documentation. It authorizes you to use this file for any
  408. X * non-commercial purpose, provided that this copyright notice is not
  409. X * removed and that any modifications made to this file are commented
  410. X * and dated in the style of my example below.
  411. X */
  412. X
  413. X/*
  414. X *
  415. X *  source file:   ./filters/cteklib/ctekreset.c
  416. X *
  417. X * Joe Dellinger (SEP), June 11 1987
  418. X *    Inserted this sample edit history entry.
  419. X *    Please log any further modifications made to this file:
  420. X */
  421. X
  422. X/* 
  423. X * Put the terminal into standard configuration.
  424. X */
  425. X#include <stdio.h>
  426. X#include "../include/attrcom.h"
  427. X#include "../include/params.h"
  428. X#include "ctek.h"
  429. X
  430. extern FILE    *pltout;
  431. extern int      dev_xmax, dev_ymax, dev_xmin, dev_ymin;
  432. X
  433. ctekreset ()
  434. X{
  435. X    /*
  436. X     * Set the graphics window. 
  437. X     */
  438. X    cteksetmode (TEK);
  439. X    fprintf (pltout, "%cRW", ESC);
  440. X    ctekxypack (dev_xmin, dev_ymin);
  441. X    ctekxypack (dev_xmax, dev_ymax);
  442. X
  443. X    /*
  444. X     * Turn off dashed lines. Set color to default color (usually white, but
  445. X     * controlled by color table). 
  446. X     */
  447. X    cteklinestyle (0);
  448. X    ctekattributes (SET_COLOR, DEFAULT_COLOR, 0, 0, 0);
  449. X}
  450. END_OF_FILE
  451. if test 1248 -ne `wc -c <'Tek_device/cteklib/ctekreset.c'`; then
  452.     echo shar: \"'Tek_device/cteklib/ctekreset.c'\" unpacked with wrong size!
  453. fi
  454. # end of 'Tek_device/cteklib/ctekreset.c'
  455. fi
  456. if test -f 'Tek_device/teklib/setmode.c' -a "${1}" != "-c" ; then 
  457.   echo shar: Will not clobber existing file \"'Tek_device/teklib/setmode.c'\"
  458. else
  459. echo shar: Extracting \"'Tek_device/teklib/setmode.c'\" \(1241 characters\)
  460. sed "s/^X//" >'Tek_device/teklib/setmode.c' <<'END_OF_FILE'
  461. X/*
  462. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  463. X * University. Official permission to use this software is included in
  464. X * the documentation. It authorizes you to use this file for any
  465. X * non-commercial purpose, provided that this copyright notice is not
  466. X * removed and that any modifications made to this file are commented
  467. X * and dated in the style of my example below.
  468. X */
  469. X
  470. X/*
  471. X *
  472. X *  source file:   ./filters/teklib/setmode.c
  473. X *
  474. X * Joe Dellinger (SEP), June 11 1987
  475. X *    Inserted this sample edit history entry.
  476. X *    Please log any further modifications made to this file:
  477. X */
  478. X
  479. X/*
  480. X * set and record new Tek mode
  481. X *
  482. X * N.B. we always issue a change to VECTOR when asked since this
  483. X *        is how a move is implemented when we are in VECTOR mode
  484. X *        already
  485. X */
  486. X#include    <stdio.h>
  487. X#include    "tek.h"
  488. extern FILE    *pltout;
  489. X
  490. int             tekmode = ALPHA;
  491. X
  492. setmode (mode)
  493. X    int             mode;
  494. X{
  495. X    switch (mode)
  496. X    {
  497. X    case VECTOR:
  498. X    putc (GS, pltout);
  499. X    tekmode = VECTOR;
  500. X    break;
  501. X    case ALPHA:
  502. X    if (tekmode != ALPHA)
  503. X    {
  504. X        lost = 1;
  505. X        putc (US, pltout);
  506. X        tekmode = ALPHA;
  507. X    }
  508. X    break;
  509. X    case POINT:
  510. X    if (tekmode != POINT)
  511. X    {
  512. X        lost = 1;
  513. X        putc (FS, pltout);
  514. X        tekmode = POINT;
  515. X    }
  516. X    break;
  517. X    }
  518. X}
  519. END_OF_FILE
  520. if test 1241 -ne `wc -c <'Tek_device/teklib/setmode.c'`; then
  521.     echo shar: \"'Tek_device/teklib/setmode.c'\" unpacked with wrong size!
  522. fi
  523. # end of 'Tek_device/teklib/setmode.c'
  524. fi
  525. if test -f 'Virtual_device/raslib/rasattr.c' -a "${1}" != "-c" ; then 
  526.   echo shar: Will not clobber existing file \"'Virtual_device/raslib/rasattr.c'\"
  527. else
  528. echo shar: Extracting \"'Virtual_device/raslib/rasattr.c'\" \(1212 characters\)
  529. sed "s/^X//" >'Virtual_device/raslib/rasattr.c' <<'END_OF_FILE'
  530. X/*
  531. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  532. X * University. Official permission to use this software is included in
  533. X * the documentation. It authorizes you to use this file for any
  534. X * non-commercial purpose, provided that this copyright notice is not
  535. X * removed and that any modifications made to this file are commented
  536. X * and dated in the style of my example below.
  537. X */
  538. X
  539. X/*
  540. X *
  541. X *  source file:   ./filters/raslib/rasattr.c
  542. X *
  543. X * Joe Dellinger (SEP), June 11 1987
  544. X *    Inserted this sample edit history entry.
  545. X *    Please log any further modifications made to this file:
  546. X */
  547. X
  548. X/*
  549. X * control graphics attributes
  550. X */
  551. X#include <stdio.h>
  552. X#include "../include/attrcom.h"
  553. X#include "raspen.h"
  554. extern FILE    *pltout;
  555. extern int      color_mult;
  556. X
  557. int             color_table[NCOLOR][3], rascolor;
  558. X
  559. rasattr (command, value, v1, v2, v3)
  560. X    register int    command, value;
  561. X    int             v1, v2, v3;
  562. X{
  563. X    switch (command)
  564. X    {
  565. X    case SET_COLOR:
  566. X    rascolor = color_mult * value;
  567. X    break;
  568. X    case SET_COLOR_TABLE:
  569. X    color_table[value * color_mult][0] = v1;
  570. X    color_table[value * color_mult][1] = v2;
  571. X    color_table[value * color_mult][2] = v3;
  572. X    break;
  573. X    default:
  574. X    break;
  575. X    }
  576. X
  577. X    return 0;
  578. X}
  579. END_OF_FILE
  580. if test 1212 -ne `wc -c <'Virtual_device/raslib/rasattr.c'`; then
  581.     echo shar: \"'Virtual_device/raslib/rasattr.c'\" unpacked with wrong size!
  582. fi
  583. # end of 'Virtual_device/raslib/rasattr.c'
  584. fi
  585. if test -f 'Virtual_device/raslib/rasdoc.h' -a "${1}" != "-c" ; then 
  586.   echo shar: Will not clobber existing file \"'Virtual_device/raslib/rasdoc.h'\"
  587. else
  588. echo shar: Extracting \"'Virtual_device/raslib/rasdoc.h'\" \(1267 characters\)
  589. sed "s/^X//" >'Virtual_device/raslib/rasdoc.h' <<'END_OF_FILE'
  590. char *documentation[] = {
  591. X" ",
  592. X"NAME",
  593. X#ifdef SEP
  594. X"    Raspen - SEPlib vplot filter for Movie files",
  595. X#else
  596. X"    raspen - vplot filter for Movie files (SEPlib version is preferred!)",
  597. X#endif
  598. X" ",
  599. X"SYNOPSIS",
  600. X#ifdef SEP
  601. X"    Raspen [options] in=vplot-inputfile OR headerfile on standard in",
  602. X#else 
  603. X"    raspen [options] [inputfiles]",
  604. X#endif
  605. X" ",
  606. X"This program creates Movie files for such things as plate tectonic movies,",
  607. X"or any movies based on any Vplot graphics.",
  608. X"This program supports EVERYTHING in Vplot to the FULL extent!",
  609. X"",
  610. X"OPTIONS",
  611. X"n1=1024 n2=768 aspect=1.",
  612. X"n1 and n2 control the size of the created output raster file, with one",
  613. X"page for each frame in the input file.",
  614. X"colormult scales vplot color numbers to raster byte values. The default is",
  615. X"2, but for plate tectonic movies 1 might be more appropriate.",
  616. X"colfile=colfile gives name of color table file for color=T option of movie.",
  617. X"If or=y then colors are OR'd as they are drawn. IE, color 3 and color 6 will",
  618. X"create color 7 where they overwrite. colormult should be a power of 2",
  619. X"in order for this option to work. (note 1 is a power of 2)",
  620. X"",
  621. X#include "../include/gendoc.h"
  622. X" ",
  623. X"SEE ALSO",
  624. X"    man pen"
  625. X};
  626. int    doclength = { sizeof documentation/sizeof documentation[0] };
  627. END_OF_FILE
  628. if test 1267 -ne `wc -c <'Virtual_device/raslib/rasdoc.h'`; then
  629.     echo shar: \"'Virtual_device/raslib/rasdoc.h'\" unpacked with wrong size!
  630. fi
  631. # end of 'Virtual_device/raslib/rasdoc.h'
  632. fi
  633. if test -f 'Virtual_device/raslib/rasreset.c' -a "${1}" != "-c" ; then 
  634.   echo shar: Will not clobber existing file \"'Virtual_device/raslib/rasreset.c'\"
  635. else
  636. echo shar: Extracting \"'Virtual_device/raslib/rasreset.c'\" \(1241 characters\)
  637. sed "s/^X//" >'Virtual_device/raslib/rasreset.c' <<'END_OF_FILE'
  638. X/*
  639. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  640. X * University. Official permission to use this software is included in
  641. X * the documentation. It authorizes you to use this file for any
  642. X * non-commercial purpose, provided that this copyright notice is not
  643. X * removed and that any modifications made to this file are commented
  644. X * and dated in the style of my example below.
  645. X */
  646. X
  647. X/*
  648. X *
  649. X *  source file:   ./filters/raslib/rasreset.c
  650. X *
  651. X * Joe Dellinger (SEP), June 11 1987
  652. X *    Inserted this sample edit history entry.
  653. X *    Please log any further modifications made to this file:
  654. X */
  655. X
  656. X#include "raspen.h"
  657. X#include "../include/params.h"
  658. extern int      color_table[NCOLOR][3], rascolor;
  659. extern int      color_mult;
  660. X
  661. rasreset ()
  662. X{
  663. int             value;
  664. X    zap ();
  665. X    for (value = 0; value < NCOLOR; value++)
  666. X    {
  667. X    color_table[value][0] = -1;
  668. X    }
  669. X    for (value = 0; value < 8; value++)
  670. X    {
  671. X    color_table[value * color_mult][0] = MAX_GUN * ((value & 2) / 2);
  672. X    color_table[value * color_mult][1] = MAX_GUN * ((value & 4) / 4);
  673. X    color_table[value * color_mult][2] = MAX_GUN * ((value & 1) / 1);
  674. X    }
  675. X}
  676. X
  677. X/*
  678. X * Zero image
  679. X */
  680. zap ()
  681. X{
  682. char           *p;
  683. X    for (p = image; p < &image[dev_xmax * dev_ymax]; p++)
  684. X    *p = 0;
  685. X}
  686. END_OF_FILE
  687. if test 1241 -ne `wc -c <'Virtual_device/raslib/rasreset.c'`; then
  688.     echo shar: \"'Virtual_device/raslib/rasreset.c'\" unpacked with wrong size!
  689. fi
  690. # end of 'Virtual_device/raslib/rasreset.c'
  691. fi
  692. if test -f 'Virtual_device/vplib/vplogvector.c' -a "${1}" != "-c" ; then 
  693.   echo shar: Will not clobber existing file \"'Virtual_device/vplib/vplogvector.c'\"
  694. else
  695. echo shar: Extracting \"'Virtual_device/vplib/vplogvector.c'\" \(1137 characters\)
  696. sed "s/^X//" >'Virtual_device/vplib/vplogvector.c' <<'END_OF_FILE'
  697. X/*
  698. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  699. X * University. Official permission to use this software is included in
  700. X * the documentation. It authorizes you to use this file for any
  701. X * non-commercial purpose, provided that this copyright notice is not
  702. X * removed and that any modifications made to this file are commented
  703. X * and dated in the style of my example below.
  704. X */
  705. X
  706. X/*
  707. X *
  708. X *  source file:   ./filters/vplib/vplogvector.c
  709. X *
  710. X * Joe Dellinger (SEP), Jan 10 1988
  711. X *    Inserted this sample edit history entry.
  712. X *    Please log any further modifications made to this file:
  713. X */
  714. X
  715. X#include <stdio.h>
  716. X#include "vp.h"
  717. X
  718. extern int      vpxmax, vpxmin, vpymax, vpymin;
  719. X
  720. vplogvector (x1, y1, x2, y2, nfat, vpdashon)
  721. X    int             x1, y1, x2, y2;
  722. X    int             nfat, vpdashon;
  723. X{
  724. X    if (clip (&x1, &y1, &x2, &y2))
  725. X    return;
  726. X
  727. X    if (x1 > vpxmax)
  728. X    vpxmax = x1;
  729. X    if (x1 < vpxmin)
  730. X    vpxmin = x1;
  731. X
  732. X    if (y1 > vpymax)
  733. X    vpymax = y1;
  734. X    if (y1 < vpymin)
  735. X    vpymin = y1;
  736. X
  737. X    if (x2 > vpxmax)
  738. X    vpxmax = x2;
  739. X    if (x2 < vpxmin)
  740. X    vpxmin = x2;
  741. X
  742. X    if (y2 > vpymax)
  743. X    vpymax = y2;
  744. X    if (y2 < vpymin)
  745. X    vpymin = y2;
  746. X}
  747. END_OF_FILE
  748. if test 1137 -ne `wc -c <'Virtual_device/vplib/vplogvector.c'`; then
  749.     echo shar: \"'Virtual_device/vplib/vplogvector.c'\" unpacked with wrong size!
  750. fi
  751. # end of 'Virtual_device/vplib/vplogvector.c'
  752. fi
  753. if test -f 'Virtual_device/vplib/vpmarker.c' -a "${1}" != "-c" ; then 
  754.   echo shar: Will not clobber existing file \"'Virtual_device/vplib/vpmarker.c'\"
  755. else
  756. echo shar: Extracting \"'Virtual_device/vplib/vpmarker.c'\" \(1312 characters\)
  757. sed "s/^X//" >'Virtual_device/vplib/vpmarker.c' <<'END_OF_FILE'
  758. X/*
  759. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  760. X * University. Official permission to use this software is included in
  761. X * the documentation. It authorizes you to use this file for any
  762. X * non-commercial purpose, provided that this copyright notice is not
  763. X * removed and that any modifications made to this file are commented
  764. X * and dated in the style of my example below.
  765. X */
  766. X
  767. X/*
  768. X *
  769. X *  source file:   ./filters/vplib/vpmarker.c
  770. X *
  771. X * Joe Dellinger (SEP), Dec 19 1987
  772. X *    Inserted this sample edit history entry.
  773. X *    Please log any further modifications made to this file:
  774. X */
  775. X
  776. X#include <stdio.h>
  777. X#include <vplot.h>
  778. X#include "../include/round.h"
  779. X#include "../include/enum.h"
  780. X#include "vp.h"
  781. X
  782. vpmarker (npts, type, size, pvec)
  783. X    int             npts, type, size;
  784. X    int            *pvec;
  785. X{
  786. float          *xp;
  787. float          *yp;
  788. int             ii;
  789. X
  790. X    vpsetflag = NO;
  791. X    lost = YES;
  792. X
  793. X    xp = (float *) malloc ((unsigned) (npts * sizeof (float)));
  794. X    yp = (float *) malloc ((unsigned) (npts * sizeof (float)));
  795. X
  796. X    for (ii = 0; ii < npts; ii++)
  797. X    {
  798. X    xp[ii] = (float) pvec[2 * ii] / RPERIN;
  799. X    yp[ii] = (float) pvec[2 * ii + 1] / RPERIN;
  800. X    }
  801. X
  802. X    size = ROUND (size * TXPERIN / RPERIN);
  803. X
  804. X    vp_pmark (npts, type, size, xp, yp);
  805. X
  806. X    free ((char *) xp);
  807. X    free ((char *) yp);
  808. X
  809. X}
  810. END_OF_FILE
  811. if test 1312 -ne `wc -c <'Virtual_device/vplib/vpmarker.c'`; then
  812.     echo shar: \"'Virtual_device/vplib/vpmarker.c'\" unpacked with wrong size!
  813. fi
  814. # end of 'Virtual_device/vplib/vpmarker.c'
  815. fi
  816. if test -f 'Virtual_device/vplib/vpmessage.c' -a "${1}" != "-c" ; then 
  817.   echo shar: Will not clobber existing file \"'Virtual_device/vplib/vpmessage.c'\"
  818. else
  819. echo shar: Extracting \"'Virtual_device/vplib/vpmessage.c'\" \(1281 characters\)
  820. sed "s/^X//" >'Virtual_device/vplib/vpmessage.c' <<'END_OF_FILE'
  821. X/*
  822. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  823. X * University. Official permission to use this software is included in
  824. X * the documentation. It authorizes you to use this file for any
  825. X * non-commercial purpose, provided that this copyright notice is not
  826. X * removed and that any modifications made to this file are commented
  827. X * and dated in the style of my example below.
  828. X */
  829. X
  830. X/*
  831. X *
  832. X *  source file:   ./filters/vplib/vpmessage.c
  833. X *
  834. X * Joe Dellinger (SEP), Dec 19 1987
  835. X *    Inserted this sample edit history entry.
  836. X *    Please log any further modifications made to this file:
  837. X */
  838. X
  839. X#include <stdio.h>
  840. X#include "../include/enum.h"
  841. X#include "../include/mesgcom.h"
  842. X#include "vp.h"
  843. X
  844. static int      saveit;
  845. static char     savestring[80 * 24];
  846. X
  847. vpmessage (command, string)
  848. X    int             command;
  849. X    char            string[];
  850. X{
  851. X    switch (command)
  852. X    {
  853. X    case MESG_READY:
  854. X    saveit = NO;
  855. X    break;
  856. X    case MESG_MESSAGE:
  857. X    saveit = YES;
  858. X    strcpy (savestring, "");
  859. X    break;
  860. X    case MESG_DONE:
  861. X    if (saveit && !vpdumb)
  862. X    {
  863. X        vp_message (savestring);
  864. X    }
  865. X    break;
  866. X    case MESG_TEXT:
  867. X
  868. X    if (saveit)
  869. X    {
  870. X        if (strcmp (string, CRLF) != 0)
  871. X        (void) strcat (savestring, string);
  872. X    }
  873. X    else
  874. X    {
  875. X        fprintf (stderr, "%s", string);
  876. X    }
  877. X
  878. X    break;
  879. X    default:
  880. X    break;
  881. X    }
  882. X}
  883. END_OF_FILE
  884. if test 1281 -ne `wc -c <'Virtual_device/vplib/vpmessage.c'`; then
  885.     echo shar: \"'Virtual_device/vplib/vpmessage.c'\" unpacked with wrong size!
  886. fi
  887. # end of 'Virtual_device/vplib/vpmessage.c'
  888. fi
  889. if test -f 'Virtual_device/vplib/vpraster.c' -a "${1}" != "-c" ; then 
  890.   echo shar: Will not clobber existing file \"'Virtual_device/vplib/vpraster.c'\"
  891. else
  892. echo shar: Extracting \"'Virtual_device/vplib/vpraster.c'\" \(1189 characters\)
  893. sed "s/^X//" >'Virtual_device/vplib/vpraster.c' <<'END_OF_FILE'
  894. X/*
  895. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  896. X * University. Official permission to use this software is included in
  897. X * the documentation. It authorizes you to use this file for any
  898. X * non-commercial purpose, provided that this copyright notice is not
  899. X * removed and that any modifications made to this file are commented
  900. X * and dated in the style of my example below.
  901. X */
  902. X
  903. X/*
  904. X * 
  905. X *  source file:   ./filters/vplib/vpraster.c
  906. X *
  907. X * Joe Dellinger (SEP), Dec 19 1987
  908. X *    Inserted this sample edit history entry.
  909. X *    Please log any further modifications made to this file:
  910. X */
  911. X
  912. X#include <stdio.h>
  913. X#include <vplot.h>
  914. X#include "../include/enum.h"
  915. X#include "vp.h"
  916. X
  917. vpraster (xpix, ypix, xmin, ymin, xmax, ymax, raster_block, orient, dither_it)
  918. X    int             xpix, ypix, xmin, ymin, xmax, ymax, orient, dither_it;
  919. X    unsigned char  *raster_block;
  920. X{
  921. float           temp1, temp2;
  922. X
  923. X    vpsetflag = NO;
  924. X    lost = YES;
  925. X
  926. X    temp1 = (float) xmax / RPERIN;
  927. X    temp2 = (float) ymax / RPERIN;
  928. X
  929. X    vp_raster (raster_block, vpblast, (vpbit > 0), vpbit, xpix, ypix,
  930. X           (float) xmin / RPERIN, (float) ymin / RPERIN,
  931. X           0., &temp1, &temp2,
  932. X           orient, NO);
  933. X}
  934. END_OF_FILE
  935. if test 1189 -ne `wc -c <'Virtual_device/vplib/vpraster.c'`; then
  936.     echo shar: \"'Virtual_device/vplib/vpraster.c'\" unpacked with wrong size!
  937. fi
  938. # end of 'Virtual_device/vplib/vpraster.c'
  939. fi
  940. if test -f 'Vplot_Kernel/Documentation/known_bugs' -a "${1}" != "-c" ; then 
  941.   echo shar: Will not clobber existing file \"'Vplot_Kernel/Documentation/known_bugs'\"
  942. else
  943. echo shar: Extracting \"'Vplot_Kernel/Documentation/known_bugs'\" \(1190 characters\)
  944. sed "s/^X//" >'Vplot_Kernel/Documentation/known_bugs' <<'END_OF_FILE'
  945. Each directory should contain a "known_bugs" file.
  946. If anyone wants to fix any of them for me, be my guest. If you fix
  947. any bugs or add any useful enhancements to the original distribution,
  948. please let me know. Well-debugged device drivers for new devices should
  949. be posted, but make sure that it passes "All_tests" first.
  950. X
  951. X    - Joe Dellinger
  952. X      Dept of Geophysics
  953. X      Stanford University
  954. X      Stanford CA 94305
  955. X
  956. Comments about bugs in documentation:
  957. X
  958. X    I don't KNOW of any, but I expect they're there. Of course,
  959. X    since nobody reads the documentation anyway, it doesn't matter.
  960. X    I really despise troff and so didn't use it to make vplothacker.doc
  961. X    on purpose.
  962. X
  963. General comments about bugs in device drivers:
  964. X
  965. X    Different devices were supported by different people. Many people
  966. X    are content to write code that "mostly" works, and can NOT be coerced
  967. X    into finishing the job. I am distributing such code as well, even
  968. X    though it isn't perfect. I have tried to mention all such problems
  969. X    that I know of in the corresponding "known_bugs" files.
  970. X    There are probably also some things "hard_wired" into some of the
  971. X    device-dependent makefiles that shouldn't be.
  972. X
  973. X*Sigh*
  974. X
  975. X>> So what do you want for free?! <<
  976. END_OF_FILE
  977. if test 1190 -ne `wc -c <'Vplot_Kernel/Documentation/known_bugs'`; then
  978.     echo shar: \"'Vplot_Kernel/Documentation/known_bugs'\" unpacked with wrong size!
  979. fi
  980. # end of 'Vplot_Kernel/Documentation/known_bugs'
  981. fi
  982. if test -f 'Vplot_Kernel/filters/Tests/TEST_limit' -a "${1}" != "-c" ; then 
  983.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/Tests/TEST_limit'\"
  984. else
  985. echo shar: Extracting \"'Vplot_Kernel/filters/Tests/TEST_limit'\" \(1196 characters\)
  986. sed "s/^X//" >'Vplot_Kernel/filters/Tests/TEST_limit' <<'END_OF_FILE'
  987. X#plas: Inches used in this file
  988. e
  989. S s
  990. z
  991. Test of fitting Vplot's window to the screen
  992. z
  993. X
  994. c 1
  995. f 1.
  996. m 0 0
  997. d 0 10.24
  998. d 13.653333 10.24
  999. d 13.653333 0
  1000. d 0 0
  1001. c 4
  1002. f .5
  1003. m 0 0
  1004. d 0 10.24
  1005. d 13.653333 10.24
  1006. d 13.653333 0
  1007. d 0 0
  1008. c 2
  1009. f .25
  1010. m 0 0
  1011. d 0 10.24
  1012. d 13.653333 10.24
  1013. d 13.653333 0
  1014. d 0 0
  1015. c 0
  1016. f .05
  1017. m 0 0
  1018. d 0 10.24
  1019. d 13.653333 10.24
  1020. d 13.653333 0
  1021. d 0 0
  1022. s 1
  1023. X.5  .5
  1024. c 7
  1025. f 0
  1026. m 0 0
  1027. d 0 10.24
  1028. d 13.653333 10.24
  1029. d 13.653333 0
  1030. d 0 0
  1031. s 2
  1032. X0. .5
  1033. X0. .5
  1034. c 7
  1035. f .05
  1036. m 0 0
  1037. d 0 10.24
  1038. d 13.653333 10.24
  1039. d 13.653333 0
  1040. d 0 0
  1041. s 0
  1042. c 7
  1043. m 6.826 7.12
  1044. J 2 0
  1045. f .02
  1046. T .3 0
  1047. Center of multi-colored border\n\
  1048. shows edges of standard vplot\n\
  1049. window. Center of dotted stripe\n\
  1050. should show AT the screen's\n\
  1051. edge on 3 sides.
  1052. m 1.5 5.12
  1053. J 2 3
  1054. f .02
  1055. T .3 90
  1056. X\F15 \v146 \F-1 10.24 Inches This Way \F15 \v144 \F-1 
  1057. m 6.8266666 1.5
  1058. J 2 3
  1059. f .02
  1060. T .3 0
  1061. X\F15 \v146 \F-1 13.65 Inches This Way \F15 \v144 \F-1 
  1062. z
  1063. This will draw a "picture frame" around the edge of Vplot's standard
  1064. z
  1065. X3 by 4 window. The central dotted line shows the exact edge of the
  1066. z
  1067. window. This should show just on the edge of your screen on 3 sides.
  1068. z
  1069. The sizes given will only be true scale if size=absolute,
  1070. z
  1071. but then the plot is not constrained to fit to the screen.
  1072. z
  1073. X
  1074. END_OF_FILE
  1075. if test 1196 -ne `wc -c <'Vplot_Kernel/filters/Tests/TEST_limit'`; then
  1076.     echo shar: \"'Vplot_Kernel/filters/Tests/TEST_limit'\" unpacked with wrong size!
  1077. fi
  1078. # end of 'Vplot_Kernel/filters/Tests/TEST_limit'
  1079. fi
  1080. if test -f 'Vplot_Kernel/filters/Tests/markertest.f' -a "${1}" != "-c" ; then 
  1081.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/Tests/markertest.f'\"
  1082. else
  1083. echo shar: Extracting \"'Vplot_Kernel/filters/Tests/markertest.f'\" \(1145 characters\)
  1084. sed "s/^X//" >'Vplot_Kernel/filters/Tests/markertest.f' <<'END_OF_FILE'
  1085. c==============================================================
  1086. c    FORTRAN routine displaying polymarkers
  1087. c==============================================================
  1088. c
  1089. X    dimension xpoly(20),ypoly(20)
  1090. X    integer marktype(8),color(8)
  1091. X    integer   out
  1092. X    data marktype /2, 3, 4, 5, 20, 21, 22, 23/
  1093. X    data color /0, 1, 2, 3, 4, 5, 6, 7/
  1094. c
  1095. c  set vplot output file
  1096. c
  1097. X    call vpfile('out.vp')
  1098. c
  1099. c  choose standard style for vplot
  1100. c
  1101. X    call vpstyle(STANDARD)
  1102. c
  1103. c  set user window
  1104. c
  1105. X    xmin = 0.
  1106. X    ymin = 0.
  1107. X    xmax = 100.
  1108. X    ymax = 100.
  1109. X    call vpstretch(xmin,ymin,xmax,ymax)
  1110. X
  1111. X
  1112. X    ncol       = 4
  1113. X    nrow    = 8
  1114. X    dcol    = (xmax-xmin)/(ncol+1)
  1115. X    drow    = (ymax-ymin)/(nrow+1)
  1116. X    isiz    = 2
  1117. X    icolor  = 0
  1118. c
  1119. c  compute positions of markers
  1120. c
  1121. X    do irow = 1,nrow
  1122. X       ix = 0
  1123. X       iy = 0
  1124. X       ypos = ymin + drow*irow
  1125. c
  1126. c  set marker type,color and size
  1127. c
  1128. X       ityp = ityp+1
  1129. X       mtype= marktype(ityp)
  1130. X       icolor = icolor+1
  1131. X       isiz = isiz+2
  1132. X       do icol =1,ncol
  1133. X        ix = ix+1
  1134. X        iy = iy+1
  1135. X        xpoly(ix) = xmin + dcol*icol
  1136. X        ypoly(iy) = ypos
  1137. X       end do
  1138. c
  1139. c  display markers
  1140. c
  1141. X       call vpcolor(color(icolor))
  1142. X       call vpupmark(ncol,mtype,isiz,xpoly,ypoly)
  1143. X    end do
  1144. c
  1145. c  end of session
  1146. c
  1147. X    call vpendplot()
  1148. X    end
  1149. X
  1150. X
  1151. END_OF_FILE
  1152. if test 1145 -ne `wc -c <'Vplot_Kernel/filters/Tests/markertest.f'`; then
  1153.     echo shar: \"'Vplot_Kernel/filters/Tests/markertest.f'\" unpacked with wrong size!
  1154. fi
  1155. # end of 'Vplot_Kernel/filters/Tests/markertest.f'
  1156. fi
  1157. if test -f 'Vplot_Kernel/filters/Tests/texttest.c' -a "${1}" != "-c" ; then 
  1158.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/Tests/texttest.c'\"
  1159. else
  1160. echo shar: Extracting \"'Vplot_Kernel/filters/Tests/texttest.c'\" \(1170 characters\)
  1161. sed "s/^X//" >'Vplot_Kernel/filters/Tests/texttest.c' <<'END_OF_FILE'
  1162. X/*
  1163. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1164. X * University. Official permission to use this software is included in
  1165. X * the documentation. It authorizes you to use this file for any
  1166. X * non-commercial purpose, provided that this copyright notice is not
  1167. X * removed and that any modifications made to this file are commented
  1168. X * and dated in the style of my example below.
  1169. X */
  1170. X
  1171. X/*
  1172. X *
  1173. X *  source file:   ./filters/Tests/texttest.c
  1174. X *
  1175. X * Joe Dellinger (SEP), June 11 1987
  1176. X *    Inserted this sample edit history entry.
  1177. X *    Please log any further modifications made to this file:
  1178. X */
  1179. X
  1180. X#include <stdio.h>
  1181. X#include <vplot.h>
  1182. X#include <math.h>
  1183. X
  1184. X#define NP 7
  1185. X
  1186. main ()
  1187. X{
  1188. float           xp, yp;
  1189. int             i;
  1190. X
  1191. X/*
  1192. X * Set up where you want the vplot output to go.
  1193. X */
  1194. X    vp_filep (stdout);
  1195. X
  1196. X/*
  1197. X * Decide what "style" plot this is to be.
  1198. X */
  1199. X    vp_style (STANDARD);
  1200. X
  1201. X/*
  1202. X * text
  1203. X */
  1204. X    for (i = 0; i < NP; i++)
  1205. X    {
  1206. X    xp = 1. + (7. / NP) * i;
  1207. X    yp = xp;
  1208. X    vp_color (i + 1);
  1209. X    vp_tfont (i * 2, STRING, OVLY_NORMAL);
  1210. X    vp_text (xp, yp, 15, 0, "This is a test...");
  1211. X/*    vp_utext(xp,yp,15,0,"This is a test..."); */
  1212. X    }
  1213. X
  1214. X/*
  1215. X * Finish up
  1216. X */
  1217. X    vp_endplot ();
  1218. X}
  1219. END_OF_FILE
  1220. if test 1170 -ne `wc -c <'Vplot_Kernel/filters/Tests/texttest.c'`; then
  1221.     echo shar: \"'Vplot_Kernel/filters/Tests/texttest.c'\" unpacked with wrong size!
  1222. fi
  1223. # end of 'Vplot_Kernel/filters/Tests/texttest.c'
  1224. fi
  1225. if test -f 'Vplot_Kernel/filters/genlib/gen_do_dovplot.c' -a "${1}" != "-c" ; then 
  1226.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/genlib/gen_do_dovplot.c'\"
  1227. else
  1228. echo shar: Extracting \"'Vplot_Kernel/filters/genlib/gen_do_dovplot.c'\" \(1209 characters\)
  1229. sed "s/^X//" >'Vplot_Kernel/filters/genlib/gen_do_dovplot.c' <<'END_OF_FILE'
  1230. X/*
  1231. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1232. X * University. Official permission to use this software is included in
  1233. X * the documentation. It authorizes you to use this file for any
  1234. X * non-commercial purpose, provided that this copyright notice is not
  1235. X * removed and that any modifications made to this file are commented
  1236. X * and dated in the style of my example below.
  1237. X */
  1238. X
  1239. X/*
  1240. X *
  1241. X *  source file:   ./filters/genlib/gen_do_dovplot.c
  1242. X *
  1243. X * Joe Dellinger (SEP), Feb 24 1988
  1244. X *    Inserted this sample edit history entry.
  1245. X *    Please log any further modifications made to this file:
  1246. X */
  1247. X
  1248. X#include <stdio.h>
  1249. X#include <strings.h>
  1250. X#include "../include/params.h"
  1251. X#include "../include/extern.h"
  1252. X
  1253. X/*
  1254. X * Call dovplot, cycling through the input plot files.
  1255. X */
  1256. X
  1257. gen_do_dovplot (nn, inpltin, innames)
  1258. X    int             nn;
  1259. X    FILE          **inpltin;
  1260. X    char            innames[][MAXFLEN + 1];
  1261. X{
  1262. int             ii;
  1263. X
  1264. X    for (ii = 0; ii < nn; ii++)
  1265. X    {
  1266. X/*
  1267. X * Set things up for dovplot.
  1268. X * The "-5" is to leave room for dovplot to add a little onto the
  1269. X * end of pltname if it wants.
  1270. X */
  1271. X    pltin = inpltin[ii];
  1272. X    strncpy (pltname, innames[ii], MAXFLEN - 5);
  1273. X    dovplot ();
  1274. X    fclose (pltin);
  1275. X    }
  1276. X}
  1277. END_OF_FILE
  1278. if test 1209 -ne `wc -c <'Vplot_Kernel/filters/genlib/gen_do_dovplot.c'`; then
  1279.     echo shar: \"'Vplot_Kernel/filters/genlib/gen_do_dovplot.c'\" unpacked with wrong size!
  1280. fi
  1281. # end of 'Vplot_Kernel/filters/genlib/gen_do_dovplot.c'
  1282. fi
  1283. if test -f 'Vplot_Kernel/filters/genlib/geninteract.c' -a "${1}" != "-c" ; then 
  1284.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/genlib/geninteract.c'\"
  1285. else
  1286. echo shar: Extracting \"'Vplot_Kernel/filters/genlib/geninteract.c'\" \(1203 characters\)
  1287. sed "s/^X//" >'Vplot_Kernel/filters/genlib/geninteract.c' <<'END_OF_FILE'
  1288. X/*
  1289. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1290. X * University. Official permission to use this software is included in
  1291. X * the documentation. It authorizes you to use this file for any
  1292. X * non-commercial purpose, provided that this copyright notice is not
  1293. X * removed and that any modifications made to this file are commented
  1294. X * and dated in the style of my example below.
  1295. X */
  1296. X
  1297. X/*
  1298. X *
  1299. X *  source file:   ./filters/genlib/geninteract.c
  1300. X *
  1301. X * Joe Dellinger (SEP), June 11 1987
  1302. X *    Inserted this sample edit history entry.
  1303. X *    Please log any further modifications made to this file:
  1304. X * Joe Dellinger Feb 22 1988
  1305. X *    Created INT_PAUSE.
  1306. X */
  1307. X
  1308. X/*
  1309. X * For most devices, this can be the interact routine.
  1310. X * This routine will work if the terminal control during plotting
  1311. X * is the same place as standard input.
  1312. X */
  1313. X
  1314. X/*
  1315. X * Get a string from the user.
  1316. X */
  1317. X
  1318. X#include <stdio.h>
  1319. X#include "../include/intcom.h"
  1320. X
  1321. geninteract (what, controltty, string)
  1322. X    int             what;
  1323. X    FILE           *controltty;
  1324. X    char           *string;
  1325. X{
  1326. X    switch (what)
  1327. X    {
  1328. X    case INT_PAUSE:
  1329. X    case INT_F_PAUSE:
  1330. X    case INT_GET_STRING:
  1331. X    fgets (string, 79, controltty);
  1332. X    break;
  1333. X    default:
  1334. X    break;
  1335. X    }
  1336. X}
  1337. END_OF_FILE
  1338. if test 1203 -ne `wc -c <'Vplot_Kernel/filters/genlib/geninteract.c'`; then
  1339.     echo shar: \"'Vplot_Kernel/filters/genlib/geninteract.c'\" unpacked with wrong size!
  1340. fi
  1341. # end of 'Vplot_Kernel/filters/genlib/geninteract.c'
  1342. fi
  1343. if test -f 'Vplot_Kernel/filters/genlib/genmessage.c' -a "${1}" != "-c" ; then 
  1344.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/genlib/genmessage.c'\"
  1345. else
  1346. echo shar: Extracting \"'Vplot_Kernel/filters/genlib/genmessage.c'\" \(1262 characters\)
  1347. sed "s/^X//" >'Vplot_Kernel/filters/genlib/genmessage.c' <<'END_OF_FILE'
  1348. X/*
  1349. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1350. X * University. Official permission to use this software is included in
  1351. X * the documentation. It authorizes you to use this file for any
  1352. X * non-commercial purpose, provided that this copyright notice is not
  1353. X * removed and that any modifications made to this file are commented
  1354. X * and dated in the style of my example below.
  1355. X */
  1356. X
  1357. X/*
  1358. X *
  1359. X *  source file:   ./filters/genlib/genmessage.c
  1360. X *
  1361. X * Joe Dellinger (SEP), June 11 1987
  1362. X *    Inserted this sample edit history entry.
  1363. X *    Please log any further modifications made to this file:
  1364. X */
  1365. X
  1366. X/*
  1367. X * Device independent subroutine to handle message operations
  1368. X */
  1369. X#include    <stdio.h>
  1370. X#include    "../include/mesgcom.h"
  1371. X#include    "../include/enum.h"
  1372. X
  1373. genmessage (command, string)
  1374. X    int             command;
  1375. X    char            string[];
  1376. X{
  1377. X
  1378. X    switch (command)
  1379. X    {
  1380. X    case MESG_HOME:
  1381. X    case MESG_READY:
  1382. X    fflush (stderr);
  1383. X    break;
  1384. X    case MESG_TEXT:
  1385. X    fprintf (stderr, "%s", string);
  1386. X    break;
  1387. X    case MESG_HIGHLIGHT_ON:
  1388. X    /* Beep at them to get their attention */
  1389. X    fprintf (stderr, "\07\07");
  1390. X    break;
  1391. X    case MESG_ON:
  1392. X    case MESG_OFF:
  1393. X    case MESG_ERASE:
  1394. X    case MESG_HIGHLIGHT_OFF:
  1395. X    case MESG_DONE:
  1396. X    default:
  1397. X    fflush (stderr);
  1398. X    break;
  1399. X    }
  1400. X}
  1401. END_OF_FILE
  1402. if test 1262 -ne `wc -c <'Vplot_Kernel/filters/genlib/genmessage.c'`; then
  1403.     echo shar: \"'Vplot_Kernel/filters/genlib/genmessage.c'\" unpacked with wrong size!
  1404. fi
  1405. # end of 'Vplot_Kernel/filters/genlib/genmessage.c'
  1406. fi
  1407. if test -f 'Vplot_Kernel/filters/include/erasecom.h' -a "${1}" != "-c" ; then 
  1408.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/include/erasecom.h'\"
  1409. else
  1410. echo shar: Extracting \"'Vplot_Kernel/filters/include/erasecom.h'\" \(1157 characters\)
  1411. sed "s/^X//" >'Vplot_Kernel/filters/include/erasecom.h' <<'END_OF_FILE'
  1412. X/*
  1413. X * command passed to dev.erase()
  1414. X */
  1415. X#define ERASE_START        0
  1416. X#define ERASE_MIDDLE        1
  1417. X#define ERASE_END        2
  1418. X#define ERASE_BREAK        3
  1419. X
  1420. X/*
  1421. X * Types of erases: (Who would believe that there are 4 kinds?)
  1422. X *
  1423. X * An erase really has two parts; you END one frame of a plot and BEGIN
  1424. X * another. For some devices you have to be careful to separate these
  1425. X * two different parts.
  1426. X *
  1427. X * ERASE_START is an erase which occurs before anything has been drawn.
  1428. X *
  1429. X * ERASE_MIDDLE is the typical case. You are both erasing something
  1430. X *     that is already there, and also preparing for another plot that
  1431. X *    is coming.
  1432. X *
  1433. X * ERASE_END is a terminal erase, with nothing more to be drawn afterwards.
  1434. X *
  1435. X * ERASE_BREAK is like ERASE_MIDDLE, except that the picture shouldn't
  1436. X *    actually be cleared. The purpose of the Break command in Vplot
  1437. X *    is to allow saving of snapshots of a plot in progress. (An example
  1438. X *    of the proper use of ERASE_BREAK is in the filter Raspen.)
  1439. X *
  1440. X * For most screen devices, ERASE_START and ERASE_MIDDLE will just be regular
  1441. X * erases, and ERASE_END and ERASE_BREAK will be ignored.
  1442. X *
  1443. X * Hardcopy devices may use ERASE_MIDDLE and ERASE_END instead.
  1444. X */
  1445. END_OF_FILE
  1446. if test 1157 -ne `wc -c <'Vplot_Kernel/filters/include/erasecom.h'`; then
  1447.     echo shar: \"'Vplot_Kernel/filters/include/erasecom.h'\" unpacked with wrong size!
  1448. fi
  1449. # end of 'Vplot_Kernel/filters/include/erasecom.h'
  1450. fi
  1451. if test -f 'Vplot_Kernel/filters/include/vplotfonts/Makefile' -a "${1}" != "-c" ; then 
  1452.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/include/vplotfonts/Makefile'\"
  1453. else
  1454. echo shar: Extracting \"'Vplot_Kernel/filters/include/vplotfonts/Makefile'\" \(1089 characters\)
  1455. sed "s/^X//" >'Vplot_Kernel/filters/include/vplotfonts/Makefile' <<'END_OF_FILE'
  1456. X# This makefile makes all the packed format fonts used by gentext
  1457. X# from the editable form produced by hertovplot.
  1458. X#
  1459. X# This makefile is NOT run by the makefile in .../vplot/filters.
  1460. X# You'll need to run this one yourself first.
  1461. X#
  1462. X# Makefont won't compile on Suns using software floating point
  1463. X# code.  CFLAGS must select the appropriate floating-point chip
  1464. X# specification:
  1465. X
  1466. X#CFLAGS = -O -f68881
  1467. CFLAGS = -O
  1468. ALL = pen.bin romanc.bin romans.bin cyrilc.bin gothgbt.bin gothgrt.bin gothitt.bin greekc.bin greeks.bin italicc.bin italict.bin math.bin misc.bin romand.bin romant.bin scriptc.bin scripts.bin
  1469. X
  1470. all: makefont $(ALL)
  1471. X
  1472. X.SUFFIXES: .vplot_font .bin .include
  1473. X
  1474. makefont: makefont.c
  1475. X    cc $(CFLAGS) -o makefont makefont.c
  1476. X
  1477. clean:
  1478. X    rm -f makefont *.o *_check *_dim *_addr *_widthl *_widthr *_symbol \
  1479. X        *_svec *_lig *.bin *.include
  1480. X
  1481. X.vplot_font.bin:    makefont
  1482. X    makefont $* < $*.vplot_font > $*.include
  1483. X    cat $*_check $*_header $*_dim $*_addr $*_widthl \
  1484. X        $*_widthr $*_symbol $*_svec $*_lig > \
  1485. X        $*.bin
  1486. X    rm -f $*_check $*_header $*_dim $*_addr $*_widthl \
  1487. X        $*_widthr $*_symbol $*_svec $*_lig
  1488. END_OF_FILE
  1489. if test 1089 -ne `wc -c <'Vplot_Kernel/filters/include/vplotfonts/Makefile'`; then
  1490.     echo shar: \"'Vplot_Kernel/filters/include/vplotfonts/Makefile'\" unpacked with wrong size!
  1491. fi
  1492. # end of 'Vplot_Kernel/filters/include/vplotfonts/Makefile'
  1493. fi
  1494. if test -f 'Vplot_Kernel/filters/utilities/dupside.c' -a "${1}" != "-c" ; then 
  1495.   echo shar: Will not clobber existing file \"'Vplot_Kernel/filters/utilities/dupside.c'\"
  1496. else
  1497. echo shar: Extracting \"'Vplot_Kernel/filters/utilities/dupside.c'\" \(1253 characters\)
  1498. sed "s/^X//" >'Vplot_Kernel/filters/utilities/dupside.c' <<'END_OF_FILE'
  1499. X/*
  1500. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1501. X * University. Official permission to use this software is included in
  1502. X * the documentation. It authorizes you to use this file for any
  1503. X * non-commercial purpose, provided that this copyright notice is not
  1504. X * removed and that any modifications made to this file are commented
  1505. X * and dated in the style of my example below.
  1506. X */
  1507. X
  1508. X/*
  1509. X *
  1510. X *  source file:   ./filters/utilities/dupside.c
  1511. X *
  1512. X * Joe Dellinger (SEP), June 11 1987
  1513. X *    Inserted this sample edit history entry.
  1514. X *    Please log any further modifications made to this file:
  1515. X */
  1516. X
  1517. X/*
  1518. X * VPLOT filter utility routine
  1519. X * Determine if other sides in the polygon are
  1520. X * identical to the side specified by the
  1521. X * vertices v and v->b.
  1522. X */
  1523. X#include "../include/vertex.h"
  1524. X
  1525. dupside (base)
  1526. X    register struct vertex *base;
  1527. X{
  1528. register struct vertex *v;
  1529. register int    x1, x2, y1, y2;
  1530. X
  1531. X    x1 = base->x;
  1532. X    x2 = base->last->x;
  1533. X    y1 = base->y;
  1534. X    y2 = base->last->y;
  1535. X    v = base->next;
  1536. X    do
  1537. X    {
  1538. X    if (x1 == v->x && y1 == v->y && x2 == v->last->x && y2 == v->last->y)
  1539. X        return (1);
  1540. X    if (x2 == v->x && y2 == v->y && x1 == v->last->x && y1 == v->last->y)
  1541. X        return (1);
  1542. X    v = v->next;
  1543. X    }
  1544. X    while (v != base);
  1545. X    return (0);
  1546. X}
  1547. END_OF_FILE
  1548. if test 1253 -ne `wc -c <'Vplot_Kernel/filters/utilities/dupside.c'`; then
  1549.     echo shar: \"'Vplot_Kernel/filters/utilities/dupside.c'\" unpacked with wrong size!
  1550. fi
  1551. # end of 'Vplot_Kernel/filters/utilities/dupside.c'
  1552. fi
  1553. if test -f 'Vplot_Kernel/lvplot/Makefile' -a "${1}" != "-c" ; then 
  1554.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/Makefile'\"
  1555. else
  1556. echo shar: Extracting \"'Vplot_Kernel/lvplot/Makefile'\" \(1316 characters\)
  1557. sed "s/^X//" >'Vplot_Kernel/lvplot/Makefile' <<'END_OF_FILE'
  1558. L = /usr/lib/libvplot.a
  1559. CFLAGS = -I../filters/include -g
  1560. FFLAGS = -g
  1561. X
  1562. X# Beware when editing files with user-unit equivalents! You should touch
  1563. X# the user-unit version as well if it includes the file you edited!
  1564. X
  1565. OFILES = vp_area.o vp_break.o vp_clip.o vp_color.o vp_dash.o vp_draw.o\
  1566. X        vp_endplt.o vp_erase.o vp_fat.o vp_message.o vp_move.o\
  1567. X        vp_orig.o vp_plot.o vp_pmark.o vp_scale.o vp_style.o\
  1568. X        vp_text.o vp_gtext.o vp_uarea.o vp_uclip.o vp_udraw.o\
  1569. X        vp_umove.o vp_uorig.o vp_uplot.o vp_upmark.o vp_utext.o\
  1570. X        vp_ugtext.o vp_file.o\
  1571. X        vp_filep.o vp_unit.o vp_where.o\
  1572. X        vp_tjust.o vp_tfont.o vp_purge.o vp_penup.o\
  1573. X        vp_upendn.o vp_pendn.o geth.o puth.o\
  1574. X        vp_uarrow.o vp_arrow.o vp_raster.o vp_uraster.o\
  1575. X        vp_coltab.o vp_pline.o vp_upline.o vp_fill.o vp_ufill.o\
  1576. X        vp_patload.o vp_hatchload.o vp_stretch.o vp_setdash.o\
  1577. X        vp_bgroup.o vp_egroup.o\
  1578. X        vptext.o vpgtext.o vputext.o vpugtext.o vpfile.o vpmessage.o\
  1579. X        vpbgroup.o
  1580. X
  1581. libvplot.a: $(OFILES)
  1582. X    rm -f *_.o
  1583. X    ranlib libvplot.a
  1584. X
  1585. install: libvplot.a
  1586. X    -mv -f $(L) $(L).old
  1587. X    install -c libvplot.a $(L)
  1588. X    ranlib $(L)
  1589. X
  1590. X.SUFFIXES:
  1591. X.SUFFIXES: .o .c .f
  1592. X.c.o:
  1593. X    cc -c ${CFLAGS} $*.c
  1594. X    cp $*.c $*_.c
  1595. X    cc -c ${CFLAGS} -DFORTRAN $*_.c
  1596. X    rm -f $*_.c
  1597. X    ar crv libvplot.a $*.o $*_.o
  1598. X.f.o:
  1599. X    f77 -c ${FFLAGS} $*.f
  1600. X    ar crv libvplot.a $*.o
  1601. END_OF_FILE
  1602. if test 1316 -ne `wc -c <'Vplot_Kernel/lvplot/Makefile'`; then
  1603.     echo shar: \"'Vplot_Kernel/lvplot/Makefile'\" unpacked with wrong size!
  1604. fi
  1605. # end of 'Vplot_Kernel/lvplot/Makefile'
  1606. fi
  1607. if test -f 'Vplot_Kernel/lvplot/vp_clip.c' -a "${1}" != "-c" ; then 
  1608.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_clip.c'\"
  1609. else
  1610. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_clip.c'\" \(1326 characters\)
  1611. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_clip.c' <<'END_OF_FILE'
  1612. X/*
  1613. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1614. X * University. Official permission to use this software is included in
  1615. X * the documentation. It authorizes you to use this file for any
  1616. X * non-commercial purpose, provided that this copyright notice is not
  1617. X * removed and that any modifications made to this file are commented
  1618. X * and dated in the style of my example below.
  1619. X */
  1620. X
  1621. X/*
  1622. X *
  1623. X *  source file:   ./lvplot/vp_clip.c
  1624. X *
  1625. X * Joe Dellinger (SEP), June 11 1987
  1626. X *    Inserted this sample edit history entry.
  1627. X *    Please log any further modifications made to this file:
  1628. X * Joe Dellinger Jan 14 1988
  1629. X *    Do rounding.
  1630. X */
  1631. X
  1632. X#include <stdio.h>
  1633. X#include <vplot.h>
  1634. X#include "round.h"
  1635. X#include "vp_pc.h"
  1636. X
  1637. X#ifdef FORTRAN
  1638. X
  1639. X#define CLIP vpclip_
  1640. X#define XMIN *xmin
  1641. X#define YMIN *ymin
  1642. X#define XMAX *xmax
  1643. X#define YMAX *ymax
  1644. X
  1645. X#else
  1646. X
  1647. X#define CLIP vp_clip
  1648. X#define XMIN xmin
  1649. X#define YMIN ymin
  1650. X#define XMAX xmax
  1651. X#define YMAX ymax
  1652. X
  1653. X#endif
  1654. X
  1655. CLIP (xmin, ymin, xmax, ymax)
  1656. X    float           XMIN, YMIN, XMAX, YMAX;
  1657. X{
  1658. int             ix, iy;
  1659. X
  1660. X    putc (VP_WINDOW, vp_pc._pltout);
  1661. X    ix = ROUND (XMIN * RPERIN);
  1662. X    puth (ix, vp_pc._pltout);
  1663. X    iy = ROUND (YMIN * RPERIN);
  1664. X    puth (iy, vp_pc._pltout);
  1665. X    ix = ROUND (XMAX * RPERIN);
  1666. X    puth (ix, vp_pc._pltout);
  1667. X    iy = ROUND (YMAX * RPERIN);
  1668. X    puth (iy, vp_pc._pltout);
  1669. X}
  1670. END_OF_FILE
  1671. if test 1326 -ne `wc -c <'Vplot_Kernel/lvplot/vp_clip.c'`; then
  1672.     echo shar: \"'Vplot_Kernel/lvplot/vp_clip.c'\" unpacked with wrong size!
  1673. fi
  1674. # end of 'Vplot_Kernel/lvplot/vp_clip.c'
  1675. fi
  1676. if test -f 'Vplot_Kernel/lvplot/vp_draw.c' -a "${1}" != "-c" ; then 
  1677.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_draw.c'\"
  1678. else
  1679. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_draw.c'\" \(1241 characters\)
  1680. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_draw.c' <<'END_OF_FILE'
  1681. X/*
  1682. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1683. X * University. Official permission to use this software is included in
  1684. X * the documentation. It authorizes you to use this file for any
  1685. X * non-commercial purpose, provided that this copyright notice is not
  1686. X * removed and that any modifications made to this file are commented
  1687. X * and dated in the style of my example below.
  1688. X */
  1689. X
  1690. X/*
  1691. X *
  1692. X *  source file:   ./lvplot/vp_draw.c
  1693. X *
  1694. X * Joe Dellinger (SEP), June 11 1987
  1695. X *    Inserted this sample edit history entry.
  1696. X *    Please log any further modifications made to this file:
  1697. X */
  1698. X
  1699. X#include <stdio.h>
  1700. X#include <vplot.h>
  1701. X#include "vp_pc.h"
  1702. X
  1703. X#ifdef FORTRAN
  1704. X
  1705. X#ifndef UUU
  1706. X#define DRAW vpdraw_
  1707. X#define X *x
  1708. X#define Y *y
  1709. X#else UUU
  1710. X#define UDRAW    vpudraw_
  1711. X#define X        *x
  1712. X#define Y        *y
  1713. X#endif UUU
  1714. X
  1715. X#else
  1716. X
  1717. X#ifndef UUU
  1718. X#define DRAW vp_draw
  1719. X#define X x
  1720. X#define Y y
  1721. X#else UUU
  1722. X#define UDRAW    vp_udraw
  1723. X#define X        x
  1724. X#define Y        y
  1725. X#endif UUU
  1726. X
  1727. X#endif
  1728. X
  1729. X#ifndef UUU
  1730. DRAW (x, y)
  1731. X#else UUU
  1732. UDRAW (x, y)
  1733. X#endif UUU
  1734. X    float           X, Y;
  1735. X{
  1736. X#ifndef UUU
  1737. X    vp_plot (X, Y, 1);
  1738. X#else UUU
  1739. float           xp, yp;
  1740. X    xp = vp_pc._x0 + (X - vp_pc._xu0) * vp_pc._xscl;
  1741. X    yp = vp_pc._y0 + (Y - vp_pc._yu0) * vp_pc._yscl;
  1742. X    vp_plot (xp, yp, 1);
  1743. X#endif UUU
  1744. X}
  1745. END_OF_FILE
  1746. if test 1241 -ne `wc -c <'Vplot_Kernel/lvplot/vp_draw.c'`; then
  1747.     echo shar: \"'Vplot_Kernel/lvplot/vp_draw.c'\" unpacked with wrong size!
  1748. fi
  1749. # end of 'Vplot_Kernel/lvplot/vp_draw.c'
  1750. fi
  1751. if test -f 'Vplot_Kernel/lvplot/vp_move.c' -a "${1}" != "-c" ; then 
  1752.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_move.c'\"
  1753. else
  1754. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_move.c'\" \(1241 characters\)
  1755. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_move.c' <<'END_OF_FILE'
  1756. X/*
  1757. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1758. X * University. Official permission to use this software is included in
  1759. X * the documentation. It authorizes you to use this file for any
  1760. X * non-commercial purpose, provided that this copyright notice is not
  1761. X * removed and that any modifications made to this file are commented
  1762. X * and dated in the style of my example below.
  1763. X */
  1764. X
  1765. X/*
  1766. X *
  1767. X *  source file:   ./lvplot/vp_move.c
  1768. X *
  1769. X * Joe Dellinger (SEP), June 11 1987
  1770. X *    Inserted this sample edit history entry.
  1771. X *    Please log any further modifications made to this file:
  1772. X */
  1773. X
  1774. X#include <stdio.h>
  1775. X#include <vplot.h>
  1776. X#include "vp_pc.h"
  1777. X
  1778. X#ifdef FORTRAN
  1779. X
  1780. X#ifndef UUU
  1781. X#define MOVE vpmove_
  1782. X#define X *x
  1783. X#define Y *y
  1784. X#else UUU
  1785. X#define UMOVE    vpumove_
  1786. X#define X        *x
  1787. X#define Y        *y
  1788. X#endif UUU
  1789. X
  1790. X#else
  1791. X
  1792. X#ifndef UUU
  1793. X#define MOVE vp_move
  1794. X#define X x
  1795. X#define Y y
  1796. X#else UUU
  1797. X#define UMOVE    vp_umove
  1798. X#define X        x
  1799. X#define Y        y
  1800. X#endif UUU
  1801. X
  1802. X#endif
  1803. X
  1804. X#ifndef UUU
  1805. MOVE (x, y)
  1806. X#else UUU
  1807. UMOVE (x, y)
  1808. X#endif UUU
  1809. X    float           X, Y;
  1810. X{
  1811. X#ifndef UUU
  1812. X    vp_plot (X, Y, 0);
  1813. X#else UUU
  1814. float           xp, yp;
  1815. X    xp = vp_pc._x0 + (X - vp_pc._xu0) * vp_pc._xscl;
  1816. X    yp = vp_pc._y0 + (Y - vp_pc._yu0) * vp_pc._yscl;
  1817. X    vp_plot (xp, yp, 0);
  1818. X#endif UUU
  1819. X}
  1820. END_OF_FILE
  1821. if test 1241 -ne `wc -c <'Vplot_Kernel/lvplot/vp_move.c'`; then
  1822.     echo shar: \"'Vplot_Kernel/lvplot/vp_move.c'\" unpacked with wrong size!
  1823. fi
  1824. # end of 'Vplot_Kernel/lvplot/vp_move.c'
  1825. fi
  1826. if test -f 'Vplot_Kernel/lvplot/vp_orig.c' -a "${1}" != "-c" ; then 
  1827.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_orig.c'\"
  1828. else
  1829. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_orig.c'\" \(1213 characters\)
  1830. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_orig.c' <<'END_OF_FILE'
  1831. X/*
  1832. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1833. X * University. Official permission to use this software is included in
  1834. X * the documentation. It authorizes you to use this file for any
  1835. X * non-commercial purpose, provided that this copyright notice is not
  1836. X * removed and that any modifications made to this file are commented
  1837. X * and dated in the style of my example below.
  1838. X */
  1839. X
  1840. X/*
  1841. X *
  1842. X *  source file:   ./lvplot/vp_orig.c
  1843. X *
  1844. X * Joe Dellinger (SEP), June 11 1987
  1845. X *    Inserted this sample edit history entry.
  1846. X *    Please log any further modifications made to this file:
  1847. X */
  1848. X
  1849. X#include <stdio.h>
  1850. X#include <vplot.h>
  1851. X#include "vp_pc.h"
  1852. X
  1853. X#ifdef FORTRAN
  1854. X
  1855. X#ifndef UUU
  1856. X#define ORIG    vporig_
  1857. X#define X0        *x0
  1858. X#define Y0        *y0
  1859. X#else UUU
  1860. X#define UORIG    vpuorig_
  1861. X#define XU0        *xu0
  1862. X#define YU0        *yu0
  1863. X#endif UUU
  1864. X
  1865. X#else
  1866. X
  1867. X#ifndef UUU
  1868. X#define ORIG    vp_orig
  1869. X#define X0        x0
  1870. X#define Y0        y0
  1871. X#else UUU
  1872. X#define UORIG    vp_uorig
  1873. X#define XU0        xu0
  1874. X#define YU0        yu0
  1875. X#endif UUU
  1876. X
  1877. X#endif
  1878. X
  1879. X#ifndef UUU
  1880. ORIG (x0, y0)
  1881. X    float           X0, Y0;
  1882. X#else UUU
  1883. UORIG (xu0, yu0)
  1884. X    float           XU0, YU0;
  1885. X#endif UUU
  1886. X{
  1887. X#ifndef UUU
  1888. X    vp_pc._x0 = X0;
  1889. X    vp_pc._y0 = Y0;
  1890. X#else UUU
  1891. X    vp_pc._xu0 = XU0;
  1892. X    vp_pc._yu0 = YU0;
  1893. X#endif UUU
  1894. X}
  1895. END_OF_FILE
  1896. if test 1213 -ne `wc -c <'Vplot_Kernel/lvplot/vp_orig.c'`; then
  1897.     echo shar: \"'Vplot_Kernel/lvplot/vp_orig.c'\" unpacked with wrong size!
  1898. fi
  1899. # end of 'Vplot_Kernel/lvplot/vp_orig.c'
  1900. fi
  1901. if test -f 'Vplot_Kernel/lvplot/vp_pendn.c' -a "${1}" != "-c" ; then 
  1902.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_pendn.c'\"
  1903. else
  1904. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_pendn.c'\" \(1151 characters\)
  1905. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_pendn.c' <<'END_OF_FILE'
  1906. X/*
  1907. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1908. X * University. Official permission to use this software is included in
  1909. X * the documentation. It authorizes you to use this file for any
  1910. X * non-commercial purpose, provided that this copyright notice is not
  1911. X * removed and that any modifications made to this file are commented
  1912. X * and dated in the style of my example below.
  1913. X */
  1914. X
  1915. X/*
  1916. X *
  1917. X *  source file:   ./lvplot/vp_pendn.c
  1918. X *
  1919. X * Joe Dellinger (SEP), June 11 1987
  1920. X *    Inserted this sample edit history entry.
  1921. X *    Please log any further modifications made to this file:
  1922. X */
  1923. X
  1924. X#include <vplot.h>
  1925. X#include "vp_pc.h"
  1926. X
  1927. X/* go to location (x,y) and then put the pen down */
  1928. X#ifdef FORTRAN
  1929. X
  1930. X#ifndef UUU
  1931. X#define PENDN vppendn_
  1932. X#else UUU
  1933. X#define UPENDN vpupendn_
  1934. X#endif UUU
  1935. X#define X *x
  1936. X#define Y *y
  1937. X
  1938. X#else
  1939. X
  1940. X#ifndef UUU
  1941. X#define PENDN vp_pendn
  1942. X#else UUU
  1943. X#define UPENDN vp_upendn
  1944. X#endif UUU
  1945. X#define X x
  1946. X#define Y y
  1947. X
  1948. X#endif
  1949. X
  1950. X#ifndef UUU
  1951. PENDN (x, y)
  1952. X#else UUU
  1953. UPENDN (x, y)
  1954. X#endif UUU
  1955. X    float           X, Y;
  1956. X{
  1957. X#ifndef UUU
  1958. X    vp_plot (X, Y, vp_pc._pendown);
  1959. X#else UUU
  1960. X    vp_uplot (X, Y, vp_pc._pendown);
  1961. X#endif UUU
  1962. X    vp_pc._pendown = 1;
  1963. X}
  1964. END_OF_FILE
  1965. if test 1151 -ne `wc -c <'Vplot_Kernel/lvplot/vp_pendn.c'`; then
  1966.     echo shar: \"'Vplot_Kernel/lvplot/vp_pendn.c'\" unpacked with wrong size!
  1967. fi
  1968. # end of 'Vplot_Kernel/lvplot/vp_pendn.c'
  1969. fi
  1970. if test -f 'Vplot_Kernel/lvplot/vp_stretch.c' -a "${1}" != "-c" ; then 
  1971.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_stretch.c'\"
  1972. else
  1973. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_stretch.c'\" \(1300 characters\)
  1974. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_stretch.c' <<'END_OF_FILE'
  1975. X/*
  1976. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  1977. X * University. Official permission to use this software is included in
  1978. X * the documentation. It authorizes you to use this file for any
  1979. X * non-commercial purpose, provided that this copyright notice is not
  1980. X * removed and that any modifications made to this file are commented
  1981. X * and dated in the style of my example below.
  1982. X */
  1983. X
  1984. X/*
  1985. X *
  1986. X *  source file:   ./lvplot/vp_stretch.c
  1987. X *
  1988. X * Joe Dellinger (SEP), June 11 1987
  1989. X *    Inserted this sample edit history entry.
  1990. X *    Please log any further modifications made to this file:
  1991. X */
  1992. X
  1993. X#include <stdio.h>
  1994. X#include <vplot.h>
  1995. X#include "vp_pc.h"
  1996. X
  1997. X#ifdef FORTRAN
  1998. X
  1999. X#define STRETCH    vpstretch_
  2000. X#define XMIN    *xmin
  2001. X#define YMIN    *ymin
  2002. X#define XMAX    *xmax
  2003. X#define YMAX    *ymax
  2004. X
  2005. X#else
  2006. X
  2007. X#define STRETCH    vp_stretch
  2008. X#define XMIN    xmin
  2009. X#define YMIN    ymin
  2010. X#define XMAX    xmax
  2011. X#define YMAX    ymax
  2012. X
  2013. X#endif
  2014. X
  2015. extern int      cur_style;
  2016. X
  2017. STRETCH (xmin, ymin, xmax, ymax)
  2018. X    float           XMIN, YMIN, XMAX, YMAX;
  2019. X{
  2020. X
  2021. X    vp_uorig (XMIN, YMIN);
  2022. X    vp_orig (0., 0.);
  2023. X
  2024. X    if (cur_style == ROTATED)
  2025. X    {
  2026. X    vp_scale (ROTATED_HEIGHT / (XMAX - XMIN), (ROTATED_HEIGHT / SCREEN_RATIO) / (YMAX - YMIN));
  2027. X    }
  2028. X    else
  2029. X    {
  2030. X    vp_scale ((STANDARD_HEIGHT / SCREEN_RATIO) / (XMAX - XMIN), STANDARD_HEIGHT / (YMAX - YMIN));
  2031. X    }
  2032. X}
  2033. END_OF_FILE
  2034. if test 1300 -ne `wc -c <'Vplot_Kernel/lvplot/vp_stretch.c'`; then
  2035.     echo shar: \"'Vplot_Kernel/lvplot/vp_stretch.c'\" unpacked with wrong size!
  2036. fi
  2037. # end of 'Vplot_Kernel/lvplot/vp_stretch.c'
  2038. fi
  2039. if test -f 'Vplot_Kernel/lvplot/vp_style.c' -a "${1}" != "-c" ; then 
  2040.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_style.c'\"
  2041. else
  2042. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_style.c'\" \(1161 characters\)
  2043. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_style.c' <<'END_OF_FILE'
  2044. X/*
  2045. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  2046. X * University. Official permission to use this software is included in
  2047. X * the documentation. It authorizes you to use this file for any
  2048. X * non-commercial purpose, provided that this copyright notice is not
  2049. X * removed and that any modifications made to this file are commented
  2050. X * and dated in the style of my example below.
  2051. X */
  2052. X
  2053. X/*
  2054. X *
  2055. X *  source file:   ./lvplot/vp_style.c
  2056. X *
  2057. X * Joe Dellinger (SEP), June 11 1987
  2058. X *    Inserted this sample edit history entry.
  2059. X *    Please log any further modifications made to this file:
  2060. X */
  2061. X
  2062. X#include <stdio.h>
  2063. X#include <vplot.h>
  2064. X#include "vp_pc.h"
  2065. X#include "params.h"
  2066. X
  2067. X#ifdef FORTRAN
  2068. X
  2069. X#define VPSTYLE    vpstyle_
  2070. X#define ST        *st
  2071. X
  2072. X#else
  2073. X
  2074. X#define VPSTYLE    vp_style
  2075. X#define ST        st
  2076. X
  2077. X#endif
  2078. X
  2079. int             cur_style = STYLE;    /* default; set in "params.h" */
  2080. X
  2081. VPSTYLE (st)
  2082. X    int             ST;
  2083. X{
  2084. X
  2085. X    cur_style = ST;
  2086. X    putc (VP_SETSTYLE, vp_pc._pltout);
  2087. X    switch (ST)
  2088. X    {
  2089. X    case ROTATED:
  2090. X    putc ('r', vp_pc._pltout);
  2091. X    break;
  2092. X    case ABSOLUTE:
  2093. X    putc ('a', vp_pc._pltout);
  2094. X    break;
  2095. X    case STANDARD:
  2096. X    default:
  2097. X    putc ('s', vp_pc._pltout);
  2098. X    break;
  2099. X    }
  2100. X}
  2101. END_OF_FILE
  2102. if test 1161 -ne `wc -c <'Vplot_Kernel/lvplot/vp_style.c'`; then
  2103.     echo shar: \"'Vplot_Kernel/lvplot/vp_style.c'\" unpacked with wrong size!
  2104. fi
  2105. # end of 'Vplot_Kernel/lvplot/vp_style.c'
  2106. fi
  2107. if test -f 'Vplot_Kernel/lvplot/vp_tjust.c' -a "${1}" != "-c" ; then 
  2108.   echo shar: Will not clobber existing file \"'Vplot_Kernel/lvplot/vp_tjust.c'\"
  2109. else
  2110. echo shar: Extracting \"'Vplot_Kernel/lvplot/vp_tjust.c'\" \(1199 characters\)
  2111. sed "s/^X//" >'Vplot_Kernel/lvplot/vp_tjust.c' <<'END_OF_FILE'
  2112. X/*
  2113. X * Copyright 1987 the Board of Trustees of the Leland Stanford Junior
  2114. X * University. Official permission to use this software is included in
  2115. X * the documentation. It authorizes you to use this file for any
  2116. X * non-commercial purpose, provided that this copyright notice is not
  2117. X * removed and that any modifications made to this file are commented
  2118. X * and dated in the style of my example below.
  2119. X */
  2120. X
  2121. X/*
  2122. X *
  2123. X *  source file:   ./lvplot/vp_tjust.c
  2124. X *
  2125. X * Joe Dellinger (SEP), June 11 1987
  2126. X *    Inserted this sample edit history entry.
  2127. X *    Please log any further modifications made to this file:
  2128. X *
  2129. X * Joe Dellinger, Dec 7 1987
  2130. X *    If the person calls vp_tjust, write the command out.
  2131. X *    Don't bother trying to second guess them!!!
  2132. X */
  2133. X
  2134. X#include <stdio.h>
  2135. X#include <vplot.h>
  2136. X#include "vp_pc.h"
  2137. X
  2138. X#ifdef FORTRAN
  2139. X
  2140. X#define XJUST    *xjust
  2141. X#define YJUST   *yjust
  2142. X#define TJUST   vptjust_
  2143. X
  2144. X#else
  2145. X
  2146. X#define XJUST    xjust
  2147. X#define YJUST   yjust
  2148. X#define TJUST   vp_tjust
  2149. X
  2150. X#endif
  2151. X
  2152. TJUST (xjust, yjust)
  2153. X    int             XJUST, YJUST;
  2154. X{
  2155. X    vp_pc._xjust = XJUST;
  2156. X    vp_pc._yjust = YJUST;
  2157. X
  2158. X    putc (VP_TXALIGN, vp_pc._pltout);
  2159. X    puth (vp_pc._xjust, vp_pc._pltout);
  2160. X    puth (vp_pc._yjust, vp_pc._pltout);
  2161. X
  2162. X    return;
  2163. X}
  2164. END_OF_FILE
  2165. if test 1199 -ne `wc -c <'Vplot_Kernel/lvplot/vp_tjust.c'`; then
  2166.     echo shar: \"'Vplot_Kernel/lvplot/vp_tjust.c'\" unpacked with wrong size!
  2167. fi
  2168. # end of 'Vplot_Kernel/lvplot/vp_tjust.c'
  2169. fi
  2170. echo shar: End of archive 5 \(of 24\).
  2171. cp /dev/null ark5isdone
  2172. MISSING=""
  2173. 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
  2174.     if test ! -f ark${I}isdone ; then
  2175.     MISSING="${MISSING} ${I}"
  2176.     fi
  2177. done
  2178. if test "${MISSING}" = "" ; then
  2179.     echo You have unpacked all 24 archives.
  2180.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  2181. else
  2182.     echo You still need to unpack the following archives:
  2183.     echo "        " ${MISSING}
  2184. fi
  2185. ##  End of shell archive.
  2186. exit 0
  2187.