better calling

This commit is contained in:
Tonton Th
2026-04-25 10:31:09 +02:00
parent 845a00d476
commit 66ecce1c06

View File

@@ -9,21 +9,22 @@ program spirale
write (0, '(A)') "----[ genplotting spirale ]----" write (0, '(A)') "----[ genplotting spirale ]----"
call genp_init (0, 's.scratch') call genp_init (0, 's.scratch')
call do_spirale (1337) call do_spirale (1337, 0.51, 0.0666, 0.7)
call genp_end (0) call genp_end (0)
contains contains
! --------------------------------------------------------- ! ---------------------------------------------------------
subroutine do_spirale (nbpass) subroutine do_spirale (nbpass, kdist, krad, phy)
integer, intent(in) :: nbpass integer, intent(in) :: nbpass
real, intent(in) :: kdist, krad, phy
integer idx, col integer idx, col
real rad, px, py, dist real rad, px, py, dist
px = 0.0 ; py = 0.0 px = 0.0 ; py = 0.0
call genp_move (px, py) call genp_move (px, py)
do idx=1, nbpass do idx=1, nbpass
dist = real(idx) * 0.51 dist = real(idx) * kdist
rad = real(idx) * 0.0666 rad = (real(idx) * krad) + phy
px = dist * sin(rad) px = dist * sin(rad)
py = dist * cos(rad) py = dist * cos(rad)
col = 3 col = 3