camera.gotoLandmark will not execute the onfinish callback with some probability
Cause: a timing error in 'requestAnimationFrame' causes a small probability of 'elapsed === duration' which prevents' endAnimation 'from executing the next frame
📝 Changelog
Language
Changelog
🇺🇸 English
🇨🇳 Chinese
☑️ Self Check before Merge
[x] Doc is updated/provided or not needed
[x] Demo is updated/provided or not needed
[x] TypeScript definition is updated/provided or not needed
🤔 This is a ...
🔗 Related issue link
💡 Background and solution
camera.gotoLandmark
有一定概率不会执行onfinish
回调函数问题原因:
requestAnimationFrame
计时误差导致小概率情况下elapsed === duration
从而不会执行下一帧而无法执行endAnimation
方法camera.gotoLandmark
will not execute theonfinish
callback with some probabilityCause: a timing error in 'requestAnimationFrame' causes a small probability of 'elapsed === duration' which prevents' endAnimation 'from executing the next frame
📝 Changelog
☑️ Self Check before Merge