Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
TOONS
#1
I don't remember where I got this original program, but, it is amazing, in that just 9 lines produce such a complex result!

If this program was previously posted here, my apologies. Not knowing this, I venture to post it, as I think it is very good!

Aspect ratio was too high, so, I added my own aspect ratio multiplier, ar, to get closer to a true circle

The program consists of simply drawing a line and a point, over and over again. To watch this, just unremark the 'SLEEP that I've added, between lines 7 and 8, and press the Space bar to see the performance, one drawn line and point at a time.

When running the program with the 'SLEEP remarked out, you will see the wreath turn counterclockwise for about 6 seconds, then clockwise for another 6 seconds, then counterclockwise for a long time... All with the repetitious drawing of a line and a point! It is a really amazing result!

Code:
ar = 1.33
1 SCREEN 13
2 FOR x = 0 TO ATN(1) * 8 STEP ATN(1) / 2
3   c = (c + 1) MOD 16
4   a = a - ATN(1) / 90
5  LINE (160 + ar*COS(a - x) * 70, 100 + SIN(a - x) * 70)-(160 + ar*COS(ATN(1) * 2 + x) * 70, 100 + SIN(ATN(1) * 2 + x) * 70), c MOD 8
6  LINE (160 + ar*COS(a - x) * 50, 100 + SIN(a - x) * 50)-(160 + ar*COS(ATN(1) * 2 + x) * 50, 100 + SIN(ATN(1) * 2 + x) * 50), a MOD 8
7   PSET (COS(RND * ATN(1) * 8) * (RND * 30 + 70) + 160, SIN(RND * ATN(1) * 8) * (RND * 30 + 70) + 100), RND * 255
'SLEEP
8 NEXT x
9 GOTO 2
Ralph, using QuickBASIC 4.5 and Windows XP Home Edition and Service Pack 2, with HP LaserJet 4L printer.
Reply


Messages In This Thread
TOONS - by Ralph - 12-23-2006, 07:10 AM
TOONS - by anarky - 12-23-2006, 10:10 PM
TOONS - by zoasterboy - 12-24-2006, 08:45 AM
TOONS - by Ralph - 12-24-2006, 09:19 AM
TOONS - by zoasterboy - 12-24-2006, 09:20 AM
TOONS - by Ralph - 12-24-2006, 09:33 AM
TOONS - by zoasterboy - 12-24-2006, 09:58 AM
TOONS - by spaz_man2 - 12-24-2006, 10:43 AM
TOONS - by Anonymous - 12-24-2006, 01:51 PM
TOONS - by Ralph - 12-24-2006, 09:35 PM
TOONS - by Ralph - 12-25-2006, 12:40 AM
TOONS - by spaz_man2 - 12-25-2006, 12:42 AM
TOONS - by Ralph - 12-25-2006, 01:22 AM
TOONS - by anarky - 12-25-2006, 06:12 AM
TOONS - by Anonymous - 12-25-2006, 04:07 PM
TOONS - by Ralph - 12-26-2006, 12:53 AM
TOONS - by Antoni Gual - 12-31-2006, 10:55 PM
TOONS - by zoasterboy - 01-01-2007, 07:51 AM
TOONS - by Antoni Gual - 01-01-2007, 07:17 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)