home *** CD-ROM | disk | FTP | other *** search
/ Global Amiga Experience / globalamigaexperience.iso / compressed / graphic / imagefx20demo.lha / Rexx.lha / Rexx / Stars.ifx < prev   
Text File  |  1993-03-20  |  560b  |  38 lines

  1. /*
  2.  * $VER: Stars 1.00.00 (24.9.92)
  3.  *
  4.  * Arexx program for the ImageFX image processing system.
  5.  * Written by Thomas Krehbiel
  6.  *
  7.  * Draws a lot of random stars into the current buffer.
  8.  *
  9.  */
  10.  
  11. OPTIONS RESULTS
  12.  
  13. GetMain ; IF result = "" THEN EXIT ; PARSE VAR result name width height depth .
  14.  
  15. SaveUndo ; Undo Off ; Redraw Off
  16.  
  17. BeginBar 'Stars' 1000
  18.  
  19. DO i = 1 TO 1000
  20.  
  21.    Bar i
  22.    LockGui
  23.    x = randu() * width
  24.    y = randu() * height
  25.    g = random(64,255)
  26.    SetPalette '-1' g g g
  27.    Point x y
  28.    UnlockGui
  29.  
  30.    END
  31.  
  32. EndBar
  33.  
  34. Undo On ; Redraw On ; Redraw
  35.  
  36. EXIT
  37.  
  38.