%%manim -qm -v WARNING HomotopyAnimationEffect
class HomotopyAnimationEffect(Scene):
def construct(self):
text=Tex("Hello World! GOOD").scale(3)
self.play(Write(text),run_time=2)
self.wait()
FRAME_HEIGHT=10
FRAME_Y_RADIUS=5
def homotopy(x, y, z, t):
alpha = (0.7 * x + FRAME_Y_RADIUS) / (FRAME_HEIGHT)
beta = squish_rate_func(smooth, alpha-0.15, alpha+0.15)(t)
return (x-0.3*np.sin(PI*beta), y,z)
self.play(Homotopy(homotopy=homotopy,mobject=text),run_time=5)
self.wait()
반응형
'html5' 카테고리의 다른 글
html svg animation moving downward (0) | 2024.12.04 |
---|---|
change in demand : animation (1) | 2024.12.01 |
manim graph plot : (0) | 2024.05.29 |
manim ValueTracker class example (0) | 2024.05.28 |
manim linearTransform example (0) | 2024.05.26 |