From: Svjatoslav Agejenko Date: Sat, 26 Oct 2024 10:15:43 +0000 (+0300) Subject: Improving comments. X-Git-Url: http://www2.svjatoslav.eu/gitweb/?a=commitdiff_plain;h=7afd16ca809bee6ca4bed17c18cf8a2a84224b2b;p=qbasicapps.git Improving comments. --- diff --git a/Graphics/3D/tank1.bas b/Graphics/3D/tank1.bas index fd019bd..36c1bac 100755 --- a/Graphics/3D/tank1.bas +++ b/Graphics/3D/tank1.bas @@ -183,15 +183,6 @@ DATA 27,28 DATA 28,29 DATA 29,22 -'DATA 14,22 -'DATA 15,23 -'DATA 16,24 -'DATA 17,25 -'DATA 18,26 -'DATA 19,27 -'DATA 20,28 -'DATA 21,29 - DATA 30,31 DATA 31,32 DATA 32,33 @@ -210,15 +201,6 @@ DATA 43,44 DATA 44,45 DATA 45,38 -'DATA 30,38 -'DATA 31,39 -'DATA 32,40 -'DATA 33,41 -'DATA 34,42 -'DATA 35,43 -'DATA 36,44 -'DATA 37,45 - DATA 46,47 DATA 47,48 DATA 48,49 @@ -252,11 +234,8 @@ DATA 61,58 DATA 54,3 DATA 55,7 -'DATA 62,63 - DATA 999, 999 ' BRIDGE - ' right handlebars DATA 100,0,100 DATA 100,50,100 @@ -356,22 +335,22 @@ DATA -600,50,-100 DATA -650,0,-100 DATA -650,50,-100 - ' alumine joon + ' bottom line DATA 100,75,-100 DATA -650,75,-100 DATA 100,75,100 DATA -650,75,100 - ' kallas + ' shore DATA 75,75,-100 DATA 75,75,100 - 'parem + 'right DATA -50,200,-100 DATA -50,200,100 DATA 75,200,-190 DATA 75,200, 190 - 'vasak + 'left DATA -525,200,-100 DATA -525,200, 100 @@ -383,7 +362,7 @@ DATA -600,200, 190 DATA 999,999,999 'right handlebars -'DATA 0,1 + DATA 2,3 DATA 4,5 DATA 6,7 @@ -400,10 +379,9 @@ DATA 22,23 DATA 24,25 DATA 26,27 DATA 28,29 -'DATA 30,31 + 'left handlebars -'DATA 32,33 DATA 34,35 DATA 36,37 DATA 38,39 @@ -420,14 +398,8 @@ DATA 54,55 DATA 56,57 DATA 58,59 DATA 60,61 -'DATA 62,63 - ' sild ise -'DATA 0,30 -'DATA 1,31 -'DATA 32,62 -'DATA 33,63 - -' pikad + +' long features DATA 0,4 DATA 4,8 DATA 8,12 @@ -466,7 +438,7 @@ DATA 61,63 ' -' l�pp +' end DATA 1,33 DATA 31,63 @@ -480,7 +452,7 @@ DATA 0,66 DATA 32,64 DATA 30,67 DATA 62,65 - ' kallas + ' shore DATA 68,69 DATA 70,71 DATA 68,70 @@ -491,7 +463,7 @@ DATA 72,68 DATA 73,71 DATA 73,69 - 'vasak + 'left DATA 74,76 DATA 75,77 DATA 74,75 @@ -502,13 +474,11 @@ DATA 76,65 DATA 75,67 DATA 77,67 -' - DATA 999, 999 DEFINT Z SUB calcsin -REM Calculating SIN and COS data... +' precalculating sine and cosine tables FOR a! = 0 TO 359 / 57.29577951# STEP 1 / 57.29577951# cosine&(a) = INT(.5 + COS(a!) * 1024) @@ -520,7 +490,7 @@ END SUB DEFSNG Z SUB getcor -REM Loading original points and connected points +' Loading original points and connected points FOR a = 0 TO 10000 READ x(a), y(a), cz(a) IF x(a) = 999 THEN x(a) = 0: y(a) = 0: cz(a) = 0: GOTO 1 @@ -561,9 +531,6 @@ getgus1 60, 30, 70, 20 getgus1 70, 20, 70, 0 getgus1 70, 0, 60, -10 getgus1 60, -10, -70, -10 -'LOCATE 1, 1 -'PRINT mitgus -'SLEEP END SUB @@ -727,7 +694,7 @@ LOOP END SUB SUB setgus -REM Updating tank position +' Updating tank position gusxp = gusxp + ssu smes = smes + ssu IF smes > 15 THEN smes = 1 @@ -771,10 +738,6 @@ SCREEN 12 CLS speed = 0 -'deg1 = 270 -'deg2 = 0 -'deg3 = 90 - deg1 = 210 deg2 = 20 deg3 = 90 diff --git a/Graphics/4D engine/qeng.bas b/Graphics/4D engine/qeng.bas index a3eb20b..aea1069 100755 --- a/Graphics/4D engine/qeng.bas +++ b/Graphics/4D engine/qeng.bas @@ -1,9 +1,19 @@ -' 4D engine +' 4D engine. It renders 5-cell (aka. pentachoron) as a series of 3D tetrahedrons with varying brightness. +' Brightness is used to represent shift in fourth dimension. +' +' In essence you can look at 3D object as a series of 2D crossections along third dimension. +' Here we look at 4D object as series of 3D crossections with varying brightness (to distinguish between them). +' +' 4 dimensions also make it possible to rotate object along 6 different axis. +' Interestingly shape of the object changes in 3D space when it is rotated +' along any of the axis that involves 4th dimension. +' +' ' made by Svjatoslav Agejenko ' in 2003.08 ' H-Page: svjatoslav.eu ' E-Mail: svjatoslav@svjatoslav.eu - + DECLARE SUB chlin (x1!, y1!, z1!, q1!, x2!, y2!, z2!, q2!) DECLARE SUB rot (x1!, y1!, z1!, q1!, x4!, y4!, z4!, q4!) DECLARE SUB setpal () @@ -262,4 +272,3 @@ END SUB FUNCTION vahe (x1, y1, z1, q1, x2, y2, z2, q2) vahe = SQR((x1 - x2) ^ 2 + (y1 - y2) ^ 2 + (z1 - z2) ^ 2 + (q1 - q2) ^ 2) END FUNCTION -