Jelajahi Sumber

feat:调整分辨率

ananzhusen 3 bulan lalu
induk
melakukan
bd5fd068a1
1 mengubah file dengan 2 tambahan dan 2 penghapusan
  1. 2 2
      src/services/common.ts

+ 2 - 2
src/services/common.ts

@@ -191,7 +191,7 @@ export const save = async (
     comData.name = (meta2d.store.active[0] as any).description ||'新建项目';
     let blob: Blob;
     try {
-      blob = dataURLtoBlob(meta2d.activeToPng(10,100) + '');
+      blob = dataURLtoBlob(meta2d.activeToPng(10,512) + '');
     } catch (e) {
       MessagePlugin.error(
         $t('无法下载,宽度不合法,可能没有选中画笔/选中画笔大小超出浏览器最大限制')
@@ -313,7 +313,7 @@ export const save = async (
     }
     let blob: Blob;
     try {
-      blob = dataURLtoBlob(meta2d.toPng(10,undefined,true,100) + '');
+      blob = dataURLtoBlob(meta2d.toPng(0,undefined,true,512) + '');
     } catch (e) {
       MessagePlugin.error(
         $t('无法下载,宽度不合法,画布可能没有画笔/画布大小超出浏览器最大限制')