MCPcopy Create free account
hub / github.com/MyGUI/mygui / acceleratedMoveFunction

Function acceleratedMoveFunction

MyGUIEngine/include/MyGUI_ActionController.h:40–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38 */
39 template<int N>
40 inline void acceleratedMoveFunction(
41 const IntCoord& _startRect,
42 const IntCoord& _destRect,
43 IntCoord& _result,
44 float _current_time)
45 {
46 float k = std::pow(_current_time, N / 10.f /*3 by default as Accelerated and 0.4 by default as Slowed*/);
47 linearMoveFunction(_startRect, _destRect, _result, k);
48 }
49
50 /** Function for ControllerPosition per frame action : Move with accelerated speed a bit farther than necessary and then return it back */
51 template<int N>

Callers

nothing calls this directly

Calls 1

linearMoveFunctionFunction · 0.85

Tested by

no test coverage detected