MCPcopy Create free account
hub / github.com/pyfa-org/Pyfa / OUT_BOUNCE

Function OUT_BOUNCE

gui/utils/anim_effects.py:61–79  ·  view source on GitHub ↗
(t, b, c, d)

Source from the content-addressed store, hash-verified

59
60
61def OUT_BOUNCE(t, b, c, d):
62 t = float(t)
63 b = float(b)
64 c = float(c)
65 d = float(d)
66
67 t /= d
68
69 if t < (1 / 2.75):
70 return c * (7.5625 * t * t) + b
71 elif t < (2 / 2.75):
72 t -= (1.5 / 2.75)
73 return c * (7.5625 * t * t + .75) + b
74 elif t < (2.5 / 2.75):
75 t -= (2.25 / 2.75)
76 return c * (7.5625 * t * t + .9375) + b
77 else:
78 t -= (2.625 / 2.75)
79 return c * (7.5625 * t * t + .984375) + b
80
81
82def INOUT_EXP(t, b, c, d):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected