MCPcopy Create free account
hub / github.com/GarageGames/Torque3D / updateTransitionNodeTransforms

Method updateTransitionNodeTransforms

Engine/source/ts/tsAnimate.cpp:291–320  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

289}
290
291void TSShapeInstance::updateTransitionNodeTransforms(TSIntegerSet& transitionNodes)
292{
293 // handle transitions
294 transitionNodes.clearAll();
295 transitionNodes.overlap(mTransitionRotationNodes);
296 transitionNodes.overlap(mTransitionTranslationNodes);
297 transitionNodes.overlap(mTransitionScaleNodes);
298 transitionNodes.takeAway(mHandsOffNodes);
299
300 // Decompose transforms for nodes affected by the transition. Only need to do
301 // for blended or scale-animated nodes, as all others are already up to date
302 for (S32 i=transitionNodes.start(); i<MAX_TS_SET_SIZE; transitionNodes.next(i))
303 {
304 if (smNodeLocalTransformDirty.test(i))
305 {
306 if (scaleCurrentlyAnimated())
307 {
308 // @todo:No support for scale yet => need to do proper affine decomposition here
309 smNodeCurrentTranslations[i] = smNodeLocalTransforms[i].getPosition();
310 smNodeCurrentRotations[i].set(smNodeLocalTransforms[i]);
311 }
312 else
313 {
314 // Scale is identity => can do a cheap decomposition
315 smNodeCurrentTranslations[i] = smNodeLocalTransforms[i].getPosition();
316 smNodeCurrentRotations[i].set(smNodeLocalTransforms[i]);
317 }
318 }
319 }
320}
321
322void TSShapeInstance::handleTransitionNodes(S32 a, S32 b)
323{

Callers

nothing calls this directly

Calls 8

takeAwayMethod · 0.80
clearAllMethod · 0.45
overlapMethod · 0.45
startMethod · 0.45
nextMethod · 0.45
testMethod · 0.45
getPositionMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected