Commit fb85fc50 authored by wang's avatar wang

乱图 渲染

parent 20423d60
{
"jsdom": "https://esm.sh/jsdom"
}
\ No newline at end of file
This diff is collapsed.
......@@ -318,7 +318,7 @@
},
"node_modules/canvas": {
"version": "2.11.2",
"resolved": "https://registry.npmjs.org/canvas/-/canvas-2.11.2.tgz",
"resolved": "https://registry.npmmirror.com/canvas/-/canvas-2.11.2.tgz",
"integrity": "sha512-ItanGBMrmRV7Py2Z+Xhs7cT+FNt5K0vPL4p9EZ/UX/Mu7hFbkxSjKF2KVtPwX7UYWp7dRKnrTvReflgrItJbdw==",
"hasInstallScript": true,
"dependencies": {
......
......@@ -11,6 +11,5 @@ const ctx = canvas.getContext('2d', {
ctx.drawImage(img, 0,0)
let unint8Array2 = new Uint8Array(90000);
ctx.readPixels(50, 0, 100, 128, 6408, 5121, unint8Array2);
ctx.getImageData(50, 0, 100, 128);
console.log(unint8Array2+'')
\ No newline at end of file
let tt = ctx.getImageData(50, 0, 100, 128);
console.log(tt.data+'')
\ No newline at end of file
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment