Skip to content

Commit

Permalink
fix: solve canvas2image.js wrong, make image's size correct
Browse files Browse the repository at this point in the history
  • Loading branch information
linlin committed Dec 6, 2018
1 parent ff87d12 commit 8fbcf7c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libs/canvas2image.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ const Canvas2Image = (function () {

const oSaveCtx = oSaveCanvas.getContext("2d");

oSaveCtx.drawImage(oCanvas, 0, 0, oCanvas.width, oCanvas.height, 0, 0, iWidth, iWidth);
oSaveCtx.drawImage(oCanvas, 0, 0, oCanvas.width, oCanvas.height, 0, 0, iWidth, iHeight);

return oSaveCanvas;
}
Expand Down

0 comments on commit 8fbcf7c

Please sign in to comment.