mirror of
https://github.com/3b1b/manim.git
synced 2025-07-31 14:03:59 +08:00
Up to CircularlyPolarizedLight in waves
This commit is contained in:
@ -98,14 +98,18 @@ class CyclicReplace(Transform):
|
||||
class Swap(CyclicReplace):
|
||||
pass #Renaming, more understandable for two entries
|
||||
|
||||
class GrowFromCenter(Transform):
|
||||
def __init__(self, mobject, **kwargs):
|
||||
class GrowFromPoint(Transform):
|
||||
def __init__(self, mobject, point, **kwargs):
|
||||
target = mobject.copy()
|
||||
point = Point(mobject.get_center())
|
||||
mobject.replace(point)
|
||||
mobject.highlight(point.get_color())
|
||||
point_mob = Point(point)
|
||||
mobject.replace(point_mob)
|
||||
mobject.highlight(point_mob.get_color())
|
||||
Transform.__init__(self, mobject, target, **kwargs)
|
||||
|
||||
class GrowFromCenter(GrowFromPoint):
|
||||
def __init__(self, mobject, **kwargs):
|
||||
GrowFromPoint.__init__(self, mobject, mobject.get_center(), **kwargs)
|
||||
|
||||
class SpinInFromNothing(GrowFromCenter):
|
||||
CONFIG = {
|
||||
"path_func" : counterclockwise_path()
|
||||
|
Reference in New Issue
Block a user