from manim import *
import numpy as np
from numpy import array, pi, cos, sin
run_time = 1
data = [[1, 2], [3, 4]]
def dot(pos, **kwargs):
    return Dot(pos, **kwargs)
class N125_02(Scene):
    def construct(self):
        sc = self
        s1 = Square().shift(LEFT * 1.5)
        s2 = Square().shift(RIGHT * 1.5)
        c1 = Circle().shift(LEFT * 1.5)
        c2 = Circle().shift(RIGHT * 1.5)
        t1 = Triangle().shift(LEFT * 1.5)
        t2 = Triangle().shift(RIGHT * 1.5)
        self.play(*[FadeIn(_o) for _o in [s1, s2]], run_time=1.0)
        self.wait(1)
        title1 = Text('TransformFrom Copy', t2g={'Copy': [BLUE, RED, YELLOW]}, font_size=25).next_to(s1, UP)
        title2 = Text('Replacement Transform', t2g={'Replacement': [BLUE, RED, YELLOW]}, font_size=25).next_to(s2, DOWN)
        self.play(*[FadeIn(_o) for _o in [title1, title2]], run_time=1.0)
        self.wait()
        self.play(TransformFromCopy(s1, c1), ReplacementTransform(s2, c2))
        self.wait()
        self.play(TransformFromCopy(c1, t1), ReplacementTransform(c2, t2))
        self.wait(0.5)