whoops, painted masks weren't cleared on new image
This commit is contained in:
parent
20d12b378a
commit
6e9013ade7
1 changed files with 5 additions and 0 deletions
|
@ -225,6 +225,7 @@ function reject(evt) {
|
|||
}
|
||||
|
||||
function newImage(evt) {
|
||||
clearPaintedMask();
|
||||
clearBackupMask();
|
||||
clearTargetMask();
|
||||
clearImgMask();
|
||||
|
@ -291,6 +292,10 @@ function clearImgMask() {
|
|||
imgCtx.clearRect(0, 0, imgCanvas.width, imgCanvas.height);
|
||||
}
|
||||
|
||||
function clearPaintedMask() {
|
||||
maskPaintCtx.clearRect(0, 0, maskPaintCanvas.width, maskPaintCanvas.height);
|
||||
}
|
||||
|
||||
function placeImage() {
|
||||
const img = new Image();
|
||||
img.onload = function () {
|
||||
|
|
Loading…
Reference in a new issue