python画微信表情_python画微信表情
#@project = facepalm
#@file = main
#@author = Maoliang Ran
#@create_time = 2018/8/28 22:57
import turtle
# 画指定的任意圆弧
def arc(sa,ea,x,y,r):#start angle,end angle,circle center,radius
turtle.penup()
turtle.goto(x,y)
turtle.setheading(0)
turtle.left(sa)
turtle.fd(r)
turtle.pendown()
turtle.left(90)
turtle.circle(r,(ea-sa))
return turtle.position()
turtle.hideturtle()
#画脸
turtle.speed(5)
turtle.setup(900,600,200,200)
turtle.pensize(5)
turtle.right(90)
turtle.penup()
turtle.fd(100)
turtle.left(90)
turtle.pendown()
turtle.begin_fill()
turtle.pencolor("#B26A0F")#head side color
turtle.circle(150)
turtle.fillcolor("#F9E549")#face color
turtle.end_fill()
#画嘴
turtle.penup()
turtle.goto(77,20)
turtle.pencolor("#744702")
turtle.goto(0,50)
turtle.right(30)
turtle.fd(110)
turtle.right(90)
turtle.pendown()
turtle.begin_fill()
turtle.fillcolor("#925902")#mouth color
turtle.circle(-97,160)
turtle.goto(92,-3)
turtle.end_fill()
turtle.penup()
turtle.goto(77,-25)
#画牙齿
turtle.pencolor("white")
turtle.begin_fill()
turtle.fillcolor("white")
turtle.goto(77,-24)
turtle.goto(-81,29)
turtle.goto(-70,43)
turtle.goto(77,-8)
turtle.end_fill()
turtle.penup()
turtle.goto(0,-100)
turtle.setheading(0)
turtle.pendown()
#画左边眼泪
turtle.left(90)
turtle.penup()
turtle.fd(150)
turtle.right(60)
turtle.fd(-150)
turtle.pendown()
turtle.left(20)
turtle.pencolor("#155F84")#tear side color
turtle.fd(150)
turtle.right(180)
position1=turtle.position()
turtle.begin_fill()
turtle.fillcolor("#7EB0C8")#tear color
turtle.fd(150)
turtle.right(20)
turtle.left(270)
turtle.circle(-150,18)
turtle.right(52)
turtle.fd(110)
position2=turtle.position()
turtle.goto(-33,90)
turtle.end_fill()
#画右边眼泪
turtle.penup()
turtle.goto(0,0)
turtle.setheading(0)
turtle.left(90)
turtle.fd(50)
turtle.right(150)
turtle.fd(150)
turtle.left(150)
turtle.fd(100)
turtle.pendown()
turtle.begin_fill()
turtle.fd(-100)
turtle.fillcolor("#7EB0C8")#tear color
turtle.right(60)
turtle.circle(150,15)
turtle.left(45)
turtle.fd(66)
turtle.goto(77,20)
turtle.end_fill()
#画眼睛
turtle.penup()
turtle.pencolor("#6C4E00")#eye color
turtle.goto(-65,75)
turtle.setheading(0)
turtle.left(27)
turtle.fd(38)
turtle.pendown()
turtle.begin_fill()
turtle.fillcolor("#6C4E00")#eye color
turtle.left(90)
turtle.circle(38,86)
turtle.goto(position2[0],position2[1])
turtle.goto(position1[0],position1[1])
turtle.end_fill()
#画手
turtle.pencolor("#D57E18")#hand side color
turtle.begin_fill()
turtle.fillcolor("#EFBD3D")#hand color
#第一个手指
arc(-110,10,110,-40,30)
turtle.circle(300,35)
turtle.circle(13,120)
turtle.setheading(-50)
turtle.fd(20)
turtle.setheading(130)
#第二个手指
turtle.circle(200,15)
turtle.circle(12,180)
turtle.fd(40)
turtle.setheading(137)
#第三个手指
turtle.circle(200,16)
turtle.circle(12,160)
turtle.setheading(-35)
turtle.fd(45)
turtle.setheading(140)
#第四个手指
turtle.circle(200,13)
turtle.circle(11,160)
turtle.setheading(-35)
turtle.fd(40)
turtle.setheading(145)
#第五个手指
turtle.circle(200,9)
turtle.circle(10,180)
turtle.setheading(-31)
turtle.fd(50)
#画最后手腕的部分
turtle.setheading(-45)
turtle.pensize(7)
turtle.right(5)
turtle.circle(180,35)
turtle.end_fill()
turtle.begin_fill()
turtle.setheading(-77)
turtle.pensize(5)
turtle.fd(50)
turtle.left(-270)
turtle.fd(7)
turtle.pencolor("#EFBD3D")
turtle.circle(30,180)
turtle.end_fill()
#测试
# res=arc(70,220,90,50,300)
# print(res[0],res[1])
turtle.done()
python画微信表情_python画微信表情相关推荐
- python分配红包程序_Python版微信红包分配算法
Python版微信红包分配算法 发布于 2015-05-08 10:54:23 | 151 次阅读 | 评论: 0 | 来源: 网友投递 Python编程语言Python 是一种面向对象.解释型计算机 ...
- python代码手机壁纸_Python制作微信好友背景墙教程(附完整代码)
引言 前段时间,微信朋友圈开始出现了一种晒照片新形式,微信好友墙,即在一张大图片中展示出自己的所有微信好友的头像. 效果如下图,出于隐私考虑,这里作了模糊处理. 是不是很炫,而且这还是独一无二的,毕竟 ...
- python画樱花树教程_Python画樱花树❀
这篇文章参考了别人的博客<Python:绘制樱花树> 原文作者:Ambitioner_c.他又参考了作者:沙漏在下雨 哈哈-- 一.代码详解 (一)绘制画幕 首先绘制画幕,命令说明如下: ...
- python random库画多彩蟒蛇_python画彩色蟒蛇
小白怎样用python画彩色蟒蛇 相信很多刚学python的小伙伴们知道画蟒蛇这个python中的神例! 但是你们知道怎样画出一条可爱的彩色小蟒蛇吗? 下面我将教你们如何用最简单的代码写出属于你的小蟒 ...
- python画微信表情_python画微信表情符的实例代码
#@project = facepalm #@file = main #@author = Maoliang Ran #@create_time = 2018/8/28 22:57 import tu ...
- 用python画微笑脸表情_python画表情包
python绘表情包 表情包有部分不完美,请读者自行修改! from turtle import* speed(1) pensize(3) setup(400,400) pu() goto(-100, ...
- python编写性别比例_Python分析微信好友性别比例和省份城市分布比例的方法示例【基于itchat模块】...
本文实例讲述了Python分析微信好友性别比例和省份城市分布比例的方法.分享给大家供大家参考,具体如下: 安装itchat pip install itchat 使用 新建wxfx.py,拷贝以下代码 ...
- python画正方形内切圆_python画出三角形外接圆和内切圆的方法
刚看了<最强大脑>中英对决,其中难度最大的项目需要选手先脑补泰森多边形,再找出完全相同的两个泰森多边形.在惊呆且感叹自身头脑愚笨的同时,不免手痒想要借助电脑弄个图出来看看,闲来无事吹吹牛也 ...
- python 微信数据_python 处理微信对账单数据的实例代码
下面一段代码给大家介绍python 处理微信对账单数据,具体代码如下所示: #下载对账单并存储到数据库 @app.route("/bill/",methods=["GET ...
最新文章
- keras 的 example 文件 conv_lstm.py 解析
- Python 爬虫利器 Selenium 从入门到进阶
- javascript 复习内容
- 092_元素的几种宽度和高度
- vb.net如何查询电脑麦克风收到声音_如何正确使用苹果电脑?
- java中oracle.链接,java连接Oracle数据库的方法解析
- Hadoop入门经典:WordCount
- CSS样式属性单词之Left
- string转换成enum
- 吴恩达|机器学习作业8.1.推荐系统(协同过滤算法)
- 大数据时代:如何节省存储成本
- 工商银行支付接口开发Java
- ajax实现读取文件内容打印,javascript结合ajax读取txt文件内容
- 富媒体消息和传统短信有何区别?
- “带花树开花”算法来解非二分图的最大匹配
- Android搭建无线调试环境
- 每日一道SQL题(第N高的薪水)
- 为什么要对数据进行归一化处理
- 利用matlab实现硬币分类,一种硬币计数分类整理机的制作方法
- css动画让箭头上下跳动