目录:
- 宝马汽车 Logo
- 奔驰汽车 Logo
- 奥迪汽车 Logo
- 特斯拉汽车 Logo
以下代码中,将向你展示多个使用 Python Turtle 中绘制的豪华汽车 Logo,包括奔驰、宝马、奥迪、特斯拉的汽车 Logo。
宝马汽车 Logo
import turtle as pen
pen.setpos(0,-250)
pen.pensize(8)
pen.fillcolor('black')
pen.begin_fill()
pen.pencolor('gray')
pen.circle(250)
pen.end_fill()pen.pensize(3)
pen.up()
pen.setpos(0,-150)
pen.down()
pen.fillcolor('white')
pen.begin_fill()
pen.circle(150)
pen.end_fill()pen.fillcolor('deepskyblue')
pen.begin_fill()
pen.circle(150, 90)
pen.left(90)
pen.pensize(2)
pen.pencolor('black')
pen.forward(150)
pen.left(90)
pen.forward(150)
pen.end_fill()
pen.up()
pen.setpos(-150,0)
pen.down()
pen.begin_fill()
pen.pensize(3)
pen.pencolor('gray')
pen.circle(150, -90)
pen.left(90)
pen.pensize(2)
pen.pencolor('black')
pen.forward(150)
pen.right(90)
pen.forward(150)
pen.end_fill()pen.pensize(12)
pen.pencolor('white')
pen.up()
pen.setpos(0,0)
pen.right(35)
pen.forward(165)
pen.right(5.2)
pen.down()
pen.forward(64)
pen.right(90)
pen.forward(35)
pen.circle(-16,180)
pen.forward(35)
pen.right(180)
pen.forward(35)
pen.circle(-16,180)
pen.forward(35)pen.up()
pen.setpos(-32,165)
pen.setheading(90)
pen.down()
pen.forward(62)
pen.setpos(0,180)
pen.setpos(32,227)
pen.right(180)
pen.forward(62)pen.up()
pen.setpos(0,0)
pen.setheading(52)
pen.forward(228)
pen.down()
pen.right(170)
pen.forward(65)
pen.left(142)
pen.forward(50)
pen.right(142)
pen.forward(50)
pen.left(142)
pen.forward(65)pen.hideturtle()
pen.done()
奔驰汽车 Logo
import turtle as penpen.shape("turtle")
pen.speed(2)
pen.bgcolor('black')pen.color("#fff")
pen.pensize(12)
pen.circle(154)
pen.left(90)
pen.penup()
pen.pensize(15)
pen.forward(150)
pen.pendown()
pen.forward(150)
pen.penup()
pen.forward(-150)
pen.left(120)
pen.pendown()
pen.forward(150)
pen.penup()
pen.forward(-150)
pen.left(120)
pen.pendown()
pen.forward(150)
pen.penup()
pen.forward(-150)
pen.left(120)
pen.hideturtle()
turtle.done()
奥迪汽车 Logo
import turtle as penpen.pensize(10)
pen.bgcolor("black")
pen.pencolor("#fff")
pen.speed(10)for i in range(4):pen.penup()pen.goto(i*70, 0)pen.pendown()pen.circle(50)pen.color("white")
pen.penup()
pen.goto(77, -40)
pen.pendown()
pen.hideturtle()
pen.done()
特斯拉汽车 Logo
import turtle as penpen.bgcolor("red")
pen.pencolor("black")
pen.speed(10)
pen.color("white")
pen.penup()
pen.goto(-160,160)
pen.pendown()pen.begin_fill()
pen.left(18)
pen.circle(-500,40)
pen.right(90)
pen.forward(17)pen.right(89.5)
pen.circle(500,39)
pen.right(90)
pen.forward(17)
pen.end_fill()pen.penup()
pen.goto(-155,133)
pen.pendown()pen.begin_fill()
pen.right(90.5)
pen.circle(-500,38)
pen.right(70)
pen.circle(-30,80)
pen.left(90)
pen.circle(-20,-70)
pen.right(10)
pen.circle(-300,-15)
pen.right(93)
pen.forward(280)
pen.right(160)
pen.forward(280)
pen.left(80)
pen.circle(300,15)
pen.circle(20,70)
pen.left(80)
pen.circle(30,-80)
pen.end_fill()pen.penup()
pen.goto(-20,155)
pen.pendown()
pen.pencolor("black")
pen.color("red")
pen.begin_fill()
pen.left(30)
pen.forward(60)
pen.left(130)
pen.forward(65)
pen.end_fill()
pen.done()