home *** CD-ROM | disk | FTP | other *** search
/ gondwana.ecr.mu.oz.au/pub/ / Graphics.tar / Graphics / voglw.zip / points.c < prev    next >
C/C++ Source or Header  |  1997-02-13  |  1KB  |  116 lines

  1. #include "vogl.h"
  2.  
  3. /*
  4.  * pnt
  5.  *
  6.  * plot a point in x, y, z.
  7.  * This is just the old VOGLE routine point.
  8.  *
  9.  */
  10. void
  11. pnt(x, y, z)
  12.     float     x, y, z;
  13. {
  14.  
  15.     if(!vdevice.initialised)
  16.         verror("pnt: vogl not initialised");
  17.  
  18.     move(x, y, z);  
  19.     draw(x, y, z);    
  20. }
  21.  
  22.  
  23. /*
  24.  * pnts
  25.  *
  26.  * plot a point (short integer version)
  27.  *
  28.  */
  29. void
  30. pnts(x, y, z)
  31.     Scoord    x, y;
  32. {
  33.     pnt((Coord)x, (Coord)y, (Coord)z);
  34. }
  35.  
  36. /*
  37.  * pnti
  38.  *
  39.  * plot a point (short integer version)
  40.  *
  41.  */
  42. void
  43. pnti(x, y, z)
  44.     Icoord    x, y, z;
  45. {
  46.     pnt((Coord)x, (Coord)y, (Coord)z);
  47. }
  48.  
  49. /*
  50.  * pnt2
  51.  *
  52.  * plot a point in x, y.
  53.  *
  54.  */
  55. void
  56. pnt2(x, y)
  57.     Coord    x, y;
  58. {
  59.     move(x, y, 0.0);
  60.     draw(x, y, 0.0);
  61. }
  62.  
  63. /*
  64.  * pnt2s in x, y
  65.  *
  66.  * plot a point (short integer version)
  67.  *
  68.  */
  69. void
  70. pnt2s(x, y)
  71.     Scoord    x, y;
  72. {
  73.     pnt2((Coord)x, (Coord)y);
  74. }
  75.  
  76. /*
  77.  * pnt2i in x, y
  78.  *
  79.  * plot a point (short integer version)
  80.  *
  81.  */
  82. void
  83. pnt2i(x, y)
  84.     Icoord    x, y;
  85. {
  86.     pnt2((Coord)x, (Coord)y);
  87. }
  88.  
  89. /*
  90.  * bgnpoint
  91.  *
  92.  *     Flags that all v*() routine points will be building up a point list.
  93.  */
  94. void
  95. bgnpoint()
  96. {
  97.     if (vdevice.bgnmode != NONE)
  98.         verror("vogl: bgnpoint mode already belongs to some other bgn routine");
  99.  
  100.     vdevice.bgnmode = VPNT;
  101.     vdevice.save = 0;
  102. }
  103.  
  104. /*
  105.  * endpoint
  106.  *
  107.  *     Flags that all v*() routine points will be simply setting the 
  108.  *     current position.
  109.  */
  110. void
  111. endpoint()
  112. {
  113.     vdevice.bgnmode = NONE;
  114.     vdevice.save = 0;
  115. }
  116.