|
MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
|
|
inlinenoexcept |
Ping-pong (triangle wave): fold x back and forth in [lo, hi].
At x = lo the value is lo. It increases to hi then folds back toward lo. Period is 2 * (hi - lo). Use for oscillating parameters, bounce animations, or any signal that should reverse at the boundary instead of wrapping.
Example: ping_pong(1.3F, 0.F, 1.F) -> 0.7F
Definition at line 153 of file Scalar.hpp.