Hello again,
I was using the tweenTo function of TimelineMax to scrub the playhead, but realised it's the only TimelineMax-exclusive function I'm using, so to save some load overhead I thought I could just use TimelineLite and manually tween the progress using a TweenLite instance like this:
var progress = { value: master_tl.time() / master_tl.duration() };
TweenLite.to(progress, 1.5, {value: labels[slideIndex].time/master_tl.duration(), ease: Strong.ease, onUpdate: function() {
master_tl.progress(progress.value);
}
});
From my performance tests using Chrome dev tools there's no real difference in performance, but I'm running the latest Macbook Pro so pretty much everything runs smoothly. Are there any performance optimisations going on in the TimelineMax.tweenTo function or other things I should be aware of?
I tried peeking at the source code and TimelineMax.tweenTo seems to be using TweenLite under the hood but going about it in a different way which I couldn't quite figure out despite the comments .