In function drawBody(personSegmentation) the context.drawImage(webcamElement, 0, 0); line does not account for various webcam resolutions and the logic fails. This needs the additional arguments: context.drawImage(webcamElement, 0, 0, webcamElement.width, webcamElement.height); to work.
In
function drawBody(personSegmentation)
thecontext.drawImage(webcamElement, 0, 0);
line does not account for various webcam resolutions and the logic fails. This needs the additional arguments:context.drawImage(webcamElement, 0, 0, webcamElement.width, webcamElement.height);
to work.