诚城的成长 诚城的成长
首页
  • 高数基础
  • 数一

    • 高等数学
    • 线性代数
    • 概率论与数理统计
  • 820

    • 数据结构
    • 计算机操作系统
  • 英一

    • 单词
    • 语法
    • 阅读理解
    • 作文
  • 政治

    • 马克思主义基本原理
    • 毛泽东
    • 近代史
    • 思修
    • 时事
  • openpose
  • html5
  • css3
  • UI

    • Tailwind Css
    • Element-Plus
    • UniApp
  • 框架

    • Vue3
  • 拓展包

    • 包管理工具
    • 包开发
  • 开发语言

    • C语言
    • PHP
    • Phyton
  • 框架

    • Laravel
  • 会计

    • 初级经济法基础
    • 初级会计实务
  • 软考

    • 信息系统项目管理师
  • 博客

    • vitepress
    • vuepress
  • manim
  • git
  • vsCode
  • latex
  • docker
  • axios
  • vim
  • mac
  • Jetbrains

    • phpstorm
    • clion
突发奇想
GitHub (opens new window)

诚城

我有N个梦想……
首页
  • 高数基础
  • 数一

    • 高等数学
    • 线性代数
    • 概率论与数理统计
  • 820

    • 数据结构
    • 计算机操作系统
  • 英一

    • 单词
    • 语法
    • 阅读理解
    • 作文
  • 政治

    • 马克思主义基本原理
    • 毛泽东
    • 近代史
    • 思修
    • 时事
  • openpose
  • html5
  • css3
  • UI

    • Tailwind Css
    • Element-Plus
    • UniApp
  • 框架

    • Vue3
  • 拓展包

    • 包管理工具
    • 包开发
  • 开发语言

    • C语言
    • PHP
    • Phyton
  • 框架

    • Laravel
  • 会计

    • 初级经济法基础
    • 初级会计实务
  • 软考

    • 信息系统项目管理师
  • 博客

    • vitepress
    • vuepress
  • manim
  • git
  • vsCode
  • latex
  • docker
  • axios
  • vim
  • mac
  • Jetbrains

    • phpstorm
    • clion
突发奇想
GitHub (opens new window)
  • introduction
  • animation
    • 原点
    • scence.play
      • class anim.
      • method anim.
    • updateers
      • simple updateers
      • a updateers
      • dt updateers
  • position
  • Color
  • material
  • 数学

  • 视频进度条
  • manim
诚城
2022-01-27
目录

animation原创

manim 官网教程 (opens new window)

# 原点

ORIGIN

# scence.play

self.play(
  # 一个play中可以有多个
  Animation1(mob1,run_time=2), # run_time 必须设置 优先级高
  Animation2(mob2), # 未设置 run_time 时会根据 paly 中的 run_time 执行
  Animation3(mob3,run_time=3),
  Animation4(..., rate_func=func1), # rate_func 动画速率函数
  run_time=5 # 统一设置所有的动画时间,
  rate_func=xxx # 统一设置所有的动画类型
)
# 动画速率函数 类型
# smooth 平滑
# linear 线性
# rush_into
# rush_form
# slow_into
# double_smeeth
# there_and_back
# lingering

# class anim.

经典动画

# Write

手写动画。

self.play(Write(Text("手写动画演示")))

# scale

缩放对象。必须放在self.play()中才能实现。

mob.scale(2) # 以自身中心放大2倍
mob.scale(0.5) # 以自身中心放大0.5倍
mob.scale(2,about_edge=UP) # 以自身上边为基准,放大2倍
mob.scale(2,about_edge=RIGHT) # 以自身右边为基准,放大2倍
mob.scale(2,about_point=np.array([-2,-2,0])) # 以某个点为基准,放大2倍

# rotate

对象旋转

mob.rotate(angle, axis= OUT [, about_point]) // 角度、轴(IN 顺时针, OUT 逆时针)、点(可选参数,默认为自身中心)

# flip

对象翻转。

mob.flip([axis= UP, about_point]) // 轴(默认为自身中心)、点(可选参数,默认为自身中心)

# stretch

拉伸对象。

(factor, dim [, about_point/about_edge]) // factor 拉伸的倍数 dim(dimension) 拉伸的方向(维度)

mob.stretch(factor=2,dim=0) # 沿X轴拉伸2倍
mob.stretch(factor=2,dim=1) # 沿Y轴拉伸2倍
mob.stretch(factor=2,dim=2) # 沿Z轴拉伸2倍
mob.stretch(factor=2,dim=2) # 沿Z轴拉伸2倍

# method anim.

# updateers

# simple updateers

# a updateers

# dt updateers

上次更新: 2022/08/24, 17:50:00
introduction
position

← introduction position→

Theme by Vdoing | Copyright © 2022-2022 carveybunt | MIT License
  • 跟随系统
  • 浅色模式
  • 深色模式
  • 阅读模式
×
×

特别申明:

本站所有内容均为个人理解或转载,如有不当之处,敬请大佬指导!