diff --git a/lms/static/js/verify_student/views/webcam_photo_view.js b/lms/static/js/verify_student/views/webcam_photo_view.js index 42560a2074..2733ecd215 100644 --- a/lms/static/js/verify_student/views/webcam_photo_view.js +++ b/lms/static/js/verify_student/views/webcam_photo_view.js @@ -55,9 +55,7 @@ if (this.stream) { video = this.getVideo(); canvas = this.getCanvas(); - canvas.width = video.videoWidth; - canvas.height = video.videoHeight; - canvas.getContext('2d').drawImage(video, 0, 0); + canvas.getContext('2d').drawImage(video, 0, 0, canvas.width, canvas.height); video.pause(); return true; }