'=========================================================================== ' Subject: SMOOTH CIRCLE ROUTINE Date: 01-16-97 (12:12) ' Author: Nick Kochakian Code: QB, QBasic, PDS ' Origin: NickK@worldnet.att.net Packet: GRAPHICS.ABC '=========================================================================== 'Fine Circles ' '1997 By: - Nick Kochakian - ' 'Finally! I've done it! 'A program that makes circles that don't have the little gaps in them! ' 'This program enables you to make circles WITHOUT the anoying gaps. 'It produces a crisp, clean circle that looks... Um... Professional! 'It runs very fast! So, don't worry about waiting too long for the circle 'to appear on the screen! :) ' 'You CAN use the CIRFINE routine in your own programs but, PLEASE 'give me credit where it is deserved the most! 'Thanks! ' 'This program can use ANY screen mode. But, it was desgined in SCREEN mode '13. DECLARE SUB CIRFINE (Colors%, Colore%, X%, Y%, SIZ%, THNG%) 'How to CALL CIRFINE: 'CALL CIRFINE (Colors%, Colore%, X%, Y%, SIZ%, THNG%) 'Colors% - is the starting color of the circle 'Colore% - is the ending color 'X% - Is the X location 'Y% - Is the Y location 'SIZ% - Should be the the size of the circle you want 'THNG% - Is how "Fat" for "Fine" you want your circle to be. 1 would be "Fine" 'and 2 or grater would be "Fat". Check out the SUB to see how it works! SCREEN 13 'VGA CM% = 30 CS% = 16 SIZ% = 50 X% = 50 Y% = 50 'The CIRCLE demo SIZZ = 50 COL = 0 LOCATE 1, 1: PRINT "Regular CIRCLE command:" DO CIRCLE (50, 50), SIZZ, COL COL = COL + 1 SIZZ = SIZZ - 1 LOOP UNTIL SIZZ = 1 LOCATE 23, 1: PRINT "Press ANY key" DO LOOP UNTIL INKEY$ <> "" CLS LOCATE 1, 1: PRINT "Circle command with CIRFINE:" CALL CIRFINE(CS%, CM%, X%, Y%, SIZ%, 1) SUB CIRFINE (Colors%, Colore%, X%, Y%, SIZ%, THNG%) C% = Colors% 'Set up the colors DO COL = C% 'Set up the colors CIRCLE (X%, Y%), SIZ%, COL PAINT (X% + SIZ% - 1, Y% + SIZ% / 100), COL C% = C% + 1 IF C% > Colore% THEN C% = Colors% SIZ% = SIZ% - THNG% 'The size control LOOP UNTIL SIZ% <= 1 END SUB