Code Monkey home page Code Monkey logo

funnytoys's Introduction

FunnyToys

放一些有趣的code

李峋同款爱心代码(附蝴蝶代码)

  1. 源代码是上面的heart.py 有python环境可以直接运行:python heart.py 默认循环跳动10个周期,可以自己修改代码。没有python环境的朋友自己搜一下安装配置教程吧
  2. heartsignal_oneclick.zip是打包好的exe可执行文件(无需装环境,对小白友好~直接解压双击即可看到李峋同款爱心),右上角绿色按钮可下载,也可访问百度云盘

参考了B站UP主码农高天的视频 另外自己做了改进:

  1. 用numpy实现提高效率
  2. 用opencv来刷新帧,比tkinter要快,避免点过多的时候卡顿
  3. 根据周期调整心形的饱满程度,看起来更像是跳动
  4. 根据周期调整光晕的散点分布,正态分布使其看上去边缘的粒子更像是被振开!
  5. 加了一个蝴蝶曲线
  6. 加上高亮粒子,使其更美观

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.