mirror of
https://github.com/3b1b/manim.git
synced 2025-08-01 17:29:06 +08:00
Added Mobject.update capabilties, which should be nicer and lighter weight than using ContinualUpdateFromFunc all the time. Also changed the behavior of any Animation having its mobject automatically thrust up to the front of the screen
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
import numpy as np
|
||||
import operator as op
|
||||
import inspect
|
||||
from functools import reduce
|
||||
|
||||
|
||||
@ -16,6 +17,10 @@ def choose(n, r):
|
||||
numer = reduce(op.mul, range(n, n - r, -1), 1)
|
||||
return numer // denom
|
||||
|
||||
|
||||
def get_num_args(function):
|
||||
return len(inspect.signature(function).parameters)
|
||||
|
||||
# Just to have a less heavyweight name for this extremely common operation
|
||||
#
|
||||
# We may wish to have more fine-grained control over division by zero behavior
|
||||
|
Reference in New Issue
Block a user