mirror of
https://github.com/3b1b/manim.git
synced 2025-07-30 05:24:22 +08:00
Up to folding the unit square in wcat
This commit is contained in:
@ -157,16 +157,21 @@ class ShimmerIn(DelayByOrder):
|
||||
class Rotate(ApplyMethod):
|
||||
CONFIG = {
|
||||
"in_place" : False,
|
||||
"about_point" : None,
|
||||
}
|
||||
def __init__(self, mobject, angle = np.pi, axis = OUT, **kwargs):
|
||||
if "path_arc" not in kwargs:
|
||||
kwargs["path_arc"] = angle
|
||||
digest_config(self, kwargs, locals())
|
||||
target = mobject.copy()
|
||||
if self.in_place:
|
||||
method = mobject.rotate_in_place
|
||||
else:
|
||||
method = mobject.rotate
|
||||
ApplyMethod.__init__(self, method, angle, axis, **kwargs)
|
||||
self.about_point = mobject.get_center()
|
||||
target.rotate(
|
||||
angle,
|
||||
axis = axis,
|
||||
about_point = self.about_point,
|
||||
)
|
||||
Transform.__init__(self, mobject, target, **kwargs)
|
||||
|
||||
|
||||
class ApplyPointwiseFunction(ApplyMethod):
|
||||
|
Reference in New Issue
Block a user