Index: openacs-4/packages/proctoring-support/www/resources/proctoring.js =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/proctoring-support/www/resources/Attic/proctoring.js,v diff -u -r1.1.2.21 -r1.1.2.22 --- openacs-4/packages/proctoring-support/www/resources/proctoring.js 26 Jun 2023 10:36:44 -0000 1.1.2.21 +++ openacs-4/packages/proctoring-support/www/resources/proctoring.js 10 Jul 2023 14:12:25 -0000 1.1.2.22 @@ -754,17 +754,15 @@ const ctx = canvas.getContext('2d', {willReadFrequently: true}); ctx.drawImage(video, 0, 0, iWidth, iHeight); - // In the future we might be stricter about black pictures... - // if (this.isCanvasMonochrome(canvas)) { - // throw 'canvas is monochrome'; - // } + if (this.isCanvasMonochrome(canvas)) { + throw 'canvas is monochrome'; + } - // Check that camera does not keep sending the same - // picture over and over. - if (streamName === 'camera' && - prevPicture !== null && + // Check that we are not sending the same picture over and + // over. + if (prevPicture && this.areCanvasEquals(canvas, prevPicture)) { - throw 'Camera is sending the same identical picture twice.'; + throw 'you are sending the same identical picture twice.'; } this.prevPictures[i] = this.cloneCanvas(canvas);