MCPcopy Create free account
hub / github.com/axmolengine/axmol / startWithTarget

Method startWithTarget

core/2d/ActionCatmullRom.cpp:235–246  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

233CardinalSplineTo::CardinalSplineTo() : _points(nullptr), _deltaT(0.f), _tension(0.f) {}
234
235void CardinalSplineTo::startWithTarget(Node* target)
236{
237 ActionInterval::startWithTarget(target);
238
239 // _deltaT = (float) 1 / _points->count();
240
241 // Issue #1441
242 _deltaT = (float)1 / (_points->count() - 1);
243
244 _previousPosition = target->getPosition();
245 _accumulatedDiff.setZero();
246}
247
248CardinalSplineTo* CardinalSplineTo::clone() const
249{

Callers

nothing calls this directly

Calls 3

countMethod · 0.45
getPositionMethod · 0.45
setZeroMethod · 0.45

Tested by

no test coverage detected