显示递增子集

限定名称: manim.animation.creation.ShowIncreasingSubsets

class ShowIncreasingSubsets(mobject=None, *args, use_override=True, **kwargs)[source]

基类: Animation

一次显示一个子对象,同时保留所有之前的子对象在屏幕上显示。

示例

示例: ShowIncreasingSubsetsScene

from manim import *

class ShowIncreasingSubsetsScene(Scene):
    def construct(self):
        p = VGroup(Dot(), Square(), Triangle())
        self.add(p)
        self.play(ShowIncreasingSubsets(p))
        self.wait()
class ShowIncreasingSubsetsScene(Scene):
    def construct(self):
        p = VGroup(Dot(), Square(), Triangle())
        self.add(p)
        self.play(ShowIncreasingSubsets(p))
        self.wait()

方法

interpolate_mobject

根据alpha值对Animation的mobject进行插值。

update_submobject_list

属性

run_time

参数:
  • group (Mobject)

  • suspend_mobject_updating (bool)

  • int_func (可调用对象[[np.ndarray], np.ndarray])

_original__init__(group, suspend_mobject_updating=False, int_func=<ufunc 'floor'>, reverse_rate_function=False, **kwargs)

初始化自身。有关准确签名,请参阅 help(type(self))。

参数:
  • group (Mobject)

  • suspend_mobject_updating (bool)

  • int_func (Callable[[ndarray], ndarray])

返回类型:

interpolate_mobject(alpha)[source]

根据alpha值对Animation的mobject进行插值。

参数:

alpha (float) – 一个介于0到1之间的浮点数,表示动画完成的比例。例如,alpha值为0、0.5和1分别对应动画完成0%、50%和100%。

返回类型: