diff --git a/src/extensions/scratch3_video_sensing/index.js b/src/extensions/scratch3_video_sensing/index.js index 145a204d4..5fca73e53 100644 --- a/src/extensions/scratch3_video_sensing/index.js +++ b/src/extensions/scratch3_video_sensing/index.js @@ -345,7 +345,7 @@ class Scratch3VideoSensingBlocks { if (args.VIDEO_STATE === 'off' || state === 1) { this.runtime.ioDevices.video.disableVideo(); } else { - this.runtime.ioDevices.video.requestVideo(); + this.runtime.ioDevices.video.enableVideo(); this.runtime.ioDevices.video.mirror = args.VIDEO_STATE === 'on' || state === 2; } } diff --git a/src/io/video.js b/src/io/video.js index 545902f4e..da7e462d9 100644 --- a/src/io/video.js +++ b/src/io/video.js @@ -20,12 +20,6 @@ class Video { */ this._frameCacheTimeout = 16; - /** - * Store each request for video, so when all are released we can disable preview/video feed. - * @type Array. - */ - this._requests = []; - /** * DOM Video element * @private @@ -93,36 +87,15 @@ class Video { * Request video be enabled. Sets up video, creates video skin and enables preview. * * ioDevices.video.requestVideo() - * .then(({ release }) => { - * this.releaseVideo = release; - * }) * - * @return {Promise.} A request object with a "release" property that - * should be called when you are done with the video. + * @return {Promise.