Jump to content

Draw a sphere: Difference between revisions

m
Line 1,318:
rem more info: https://www.dostips.com/forum/viewtopic.php?f=3&t=6744
 
rem integer sqrt arithmetic function by Aacini, penpen and penpeneinstein1969
rem source: https://www.dostips.com/forum/viewtopic.php?f=3&t=5819&start=30#p44016
set "sqrt(N)=( M=(N),j=M/(11*1024)+40, j=(M/j+j)>>1, j=(M/j+j)>>1, j=(M/j+j)>>1, j=(M/j+j)>>1, j=(M/j+j)>>1, j+=(M-j*j)>>31 )"
Line 1,379:
set /a "sqrdR=R*R*100*100" %== R*R is mult. by 100*100 ==%
set "k=2" %== k is hardcoded to 2 ==%
set "ambient=%32"
rem start draw line-by-line
for /l %%i in (%negR%, 1, %R%) do (
Cookies help us deliver our services. By using our services, you agree to our use of cookies.