Pause the animation.
()
| 158 | |
| 159 | /** Pause the animation. */ |
| 160 | pause() { |
| 161 | if (this.animationFrameId !== null) { |
| 162 | cancelAnimationFrame(this.animationFrameId); |
| 163 | this.animationFrameId = null; |
| 164 | this._isPlaying.set(false); |
| 165 | } |
| 166 | } |
| 167 | |
| 168 | /** |
| 169 | * Fast-forward or go back at a specific time. |