From 8441e66e937bf99c369310a018d4b78cc5fc853a Mon Sep 17 00:00:00 2001 From: liangzai <2440983361@qq.com> Date: Wed, 11 Mar 2026 14:55:45 +0800 Subject: [PATCH] f --- resources/qiye.html | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/resources/qiye.html b/resources/qiye.html index f9b0d01..164c786 100644 --- a/resources/qiye.html +++ b/resources/qiye.html @@ -2241,6 +2241,23 @@ restoreBtn(); return; } + // 调试:确认截图是否全白/是否有内容 + try { + var ctx2d = canvas.getContext("2d"); + if (ctx2d) { + var p = ctx2d.getImageData(0, 0, 1, 1).data; + console.info( + "PDF截图信息", + { + w: canvas.width, + h: canvas.height, + firstPixel: Array.prototype.slice.call(p), + }, + ); + } + } catch (e) { + console.warn("读取截图像素失败(可能被跨域资源污染)", e); + } var imgData = canvas.toDataURL( "image/jpeg", 0.95,