diff --git a/src/containers/stage.jsx b/src/containers/stage.jsx index 94d4f092fc4ec64a0b1f838b49ed8e62636aaf05..c5c36c2e68c83479d7390e8ab24ba9dba033f800 100644 --- a/src/containers/stage.jsx +++ b/src/containers/stage.jsx @@ -60,6 +60,9 @@ class Stage extends React.Component { this.renderer = new Renderer(this.canvas); this.props.vm.attachRenderer(this.renderer); + // Only attach a video provider once because it is stateful + this.props.vm.setVideoProvider(new VideoProvider()); + // Calling draw a single time before any project is loaded just makes // the canvas white instead of solid black–needed because it is not // possible to use CSS to style the canvas to have a different @@ -68,7 +71,6 @@ class Stage extends React.Component { } this.props.vm.attachV2SVGAdapter(new V2SVGAdapter()); this.props.vm.attachV2BitmapAdapter(new V2BitmapAdapter()); - this.props.vm.setVideoProvider(new VideoProvider()); } componentDidMount () { this.attachRectEvents();