Tuesday, November 15, 2022

Python Turtle Graphics Drawing - Golden Snail

 Python Turtle Graphics Drawing - Golden Snail

Youtube


Source code:

import turtle as t
import colorsys as cs
from math import sin, radians
t.setup(640, 640)
t.tracer(250)
t.bgcolor('black')
t.hideturtle()

for i in range(1440,0,-1):
    l = 0.5+sin(radians(i+160))*0.2
    t.color(cs.hls_to_rgb(0.090,l,1))
    t.pensize(1+i/200)
    t.circle(i/10)
    t.lt(1)

t.done()

No comments:

Post a Comment

Python Turtle Graphics Drawing - Gigabyte

 Python Turtle Graphics Drawing - Gigabyte Youtube Source code: from turtle import * setup ( 600 , 600 ) color ( '#2D68AE' ) up (...