TransformMatchingAbstractBase(mobject=None, *args, use_override=True, **kwargs)¶
Abstract base class for transformations that keep track of matching parts.
Subclasses have to implement the two static methods
Basically, this transformation first maps all submobjects returned by the
get_mobject_partsmethod to certain keys by applying the
get_mobject_keymethod. Then, submobjects with matching keys are transformed into each other.
mobject – The starting
target_mobject – The target
transform_mismatches – Controls whether submobjects without a matching key are transformed into each other by using
fade_transform_mismatches – Controls whether submobjects without a matching key are transformed into each other by using
key_map – Optional. A dictionary mapping keys belonging to some of the starting mobject’s submobjects (i.e., the return values of the
get_mobject_keymethod) to some keys belonging to the target mobject’s submobjects that should be transformed although the keys don’t match.
kwargs – All further keyword arguments are passed to the submobject transformations.
fade_transform_mismatchesare set to
True, submobjects without matching keys in the starting mobject are faded out in the direction of the unmatched submobjects in the target mobject, and unmatched submobjects in the target mobject are faded in from the direction of the unmatched submobjects in the start mobject.
Clean up the
Sceneafter finishing the animation.