Browse Source

原图遮盖:裁切时高度写错了

Michael Wang 4 years ago
parent
commit
9b7938a02f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/features/mark/SheetViewModal.vue

+ 1 - 1
src/features/mark/SheetViewModal.vue

@@ -92,7 +92,7 @@ function getDataUrlForSheetConfig(
 ) {
   const canvas = document.createElement("canvas");
   canvas.width = image.naturalWidth;
-  canvas.height = image.naturalWidth;
+  canvas.height = image.naturalHeight;
   const ctx = canvas.getContext("2d");
   if (!ctx) {
     console.log('canvas.getContext("2d") error');