home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / Samples / C-ASM_VI.ARJ / PROGC.ZIP / PROGC089.C < prev    next >
Text File  |  1988-04-10  |  1KB  |  30 lines

  1.  
  2. /************************************************************************/
  3. /* A set of concentric circles and four sets of symmetric arcs          */
  4. /************************************************************************/
  5.  
  6. arc_demo()
  7.         {
  8.         #define WHITE   15
  9.         int     r;
  10.         cls();
  11.         for (r = 100; r > 70; r -= 5)           /* Draw 6 circles       */
  12.                 arc(320,100,320+r,100,0,360,WHITE);
  13.         for (r = 70; r > 0; r -= 5)             /* Loop over size       */
  14.                 {                               /* Draw next four arcs  */
  15.                 arc(320,100,320+r,100, 22, 66,WHITE);
  16.                 arc(320,100,320+r,100,112,156,WHITE);
  17.                 arc(320,100,320+r,100,202,246,WHITE);
  18.                 arc(320,100,320+r,100,292,336,WHITE);
  19.                 }
  20.         }
  21.  
  22. arc(xc,yc,xp,yp,a0,a1,color)
  23. int     xc,yc;                  /* Center of the arc                    */
  24. int     xp,yp;                  /* Any point on full circle             */
  25. int     a0,a1;                  /* Starting and ending angle in degrees */
  26. int     color;                  /* Color of the arc                     */
  27.         {
  28.         brute_arc(xc,yc,xp,yp,a0,a1,color);
  29.         }
  30.