Qbasicnews.com
September 20, 2021, 01:13:31 AM
 Pages: 1 ... 3 4 [5]
 Author Topic: PSET Circle!  (Read 42760 times)
Xerol
Member

Posts: 30

 « Reply #60 on: December 13, 2005, 03:56:32 AM »

I made mine into a function. The actual functional code is only the 3 lines in the loop:

Code:
screen 12

declare sub psetcircle(x, y, r, c)

for r = 1 to 200 step 1
psetcircle 320, 240, r, (r mod 15) + 1
next r

sleep

sub psetcircle(x,y,r,c)
dim o as double
for o = 0 to 360 step 30/r
pset(cos(o*3.141592/180)*r+x, sin(o*3.141592/180)*r+y), c
next o
end sub

(FB)
 Logged

url=http://www.lggaming.com/user/xerol/songs/recycled][size=24]Recycled CompoST[/size][/url] - Best of 2005 Album by Xerol.
googly
New Member

Posts: 3

 « Reply #61 on: December 13, 2005, 10:29:22 AM »

looking at these progs (endless ones all the same) it's like the Bresenham algorithm had never been discovered. Look it up its quick and always using the max screen resolution available.
 Logged

ormal service may never be resumed
axipher
Ancient Guru

Posts: 544

 « Reply #62 on: December 13, 2005, 12:16:00 PM »

I have a copy of the Bresenham algorithm but I can't figure out how to put limits into it, here is the area of the drawing area: (40,2) to (55,17), the circle can range in size from 1 - 24 and color can range from 0 - 255 and having an option to fill or not fill would be nice too.  The circle is base on user input and is drawn relative to the relative position being (x%,y%).
 Logged
Dr_Davenstein
Na_th_an

Posts: 2052

 « Reply #63 on: December 13, 2005, 06:41:48 PM »

Quote from: "googly"
looking at these progs (endless ones all the same) it's like the Bresenham algorithm had never been discovered. Look it up its quick and always using the max screen resolution available.

Way too easy. The point was to make something unique.

btw: Screen resolution has nothing to do with any Bresenham algo, ya know?  :lol:
 Logged
axipher
Ancient Guru

Posts: 544

 « Reply #64 on: December 13, 2005, 11:16:32 PM »

What about my problem... *sniffle* *sniffle*, lol, maybe that's what Z!re meant when he said that I was self-absorbant, but it's not like I am pushing anyone right???
 Logged
Dr_Davenstein
Na_th_an

Posts: 2052

 « Reply #65 on: December 13, 2005, 11:22:44 PM »

Give it a try first, and people will be more enthused about helping you.
 Logged
axipher
Ancient Guru

Posts: 544

 « Reply #66 on: December 13, 2005, 11:40:57 PM »

Here's my try at it:

http://forum.qbasicnews.com/viewtopic.php?p=128335#128335
 Logged
 Pages: 1 ... 3 4 [5]