You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When executing player.destroy(), the canvas is destroyed. What should I do because I want to use all functions of destroy() without destroying the canvas?
The text was updated successfully, but these errors were encountered:
The canvas element is only removed if it was created by JSMpeg in the first place. If you want to keep the canvas, create it outside of JSMpeg and pass it in as an option. E.g.
<canvasid="video-canvas"></canvas>
varelement=document.getElementById('video-canvas');varplayer=newJSMpeg.Player('file.ts',{canvas: element});// this will not remove the canvas, since it was not created by jsmpegplayer.destroy();
When executing player.destroy(), the canvas is destroyed. What should I do because I want to use all functions of destroy() without destroying the canvas?
The text was updated successfully, but these errors were encountered: