diff --git a/package-lock.json b/package-lock.json index 03900c98..77bd92ca 100644 --- a/package-lock.json +++ b/package-lock.json @@ -25,16 +25,16 @@ "@types/node": "^24.10.1", "@typescript-eslint/eslint-plugin": "^8.47.0", "@typescript-eslint/parser": "^8.47.0", - "@vitest/web-worker": "^4.0.10", + "@vitest/web-worker": "^4.0.12", "eslint": "^9.39.1", "eslint-plugin-unused-imports": "^4.3.0", "globals": "^16.5.0", "jsdom": "^27.2.0", - "rollup": "^4.53.2", + "rollup": "^4.53.3", "tslib": "^2.8.1", "typescript": "^5.9.3", - "vite": "^7.2.2", - "vitest": "^4.0.10", + "vite": "^7.2.4", + "vitest": "^4.0.12", "vitest-webgl-canvas-mock": "^1.1.0", "xml2js": "^0.6.2" }, @@ -189,7 +189,6 @@ } ], "license": "MIT", - "peer": true, "engines": { "node": ">=18" }, @@ -233,7 +232,6 @@ } ], "license": "MIT", - "peer": true, "engines": { "node": ">=18" } @@ -1146,9 +1144,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.53.2.tgz", - "integrity": "sha512-yDPzwsgiFO26RJA4nZo8I+xqzh7sJTZIWQOxn+/XOdPE31lAvLIYCKqjV+lNH/vxE2L2iH3plKxDCRK6i+CwhA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.53.3.tgz", + "integrity": "sha512-mRSi+4cBjrRLoaal2PnqH82Wqyb+d3HsPUN/W+WslCXsZsyHa9ZeQQX/pQsZaVIWDkPcpV6jJ+3KLbTbgnwv8w==", "cpu": [ "arm" ], @@ -1160,9 +1158,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.53.2.tgz", - "integrity": "sha512-k8FontTxIE7b0/OGKeSN5B6j25EuppBcWM33Z19JoVT7UTXFSo3D9CdU39wGTeb29NO3XxpMNauh09B+Ibw+9g==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.53.3.tgz", + "integrity": "sha512-CbDGaMpdE9sh7sCmTrTUyllhrg65t6SwhjlMJsLr+J8YjFuPmCEjbBSx4Z/e4SmDyH3aB5hGaJUP2ltV/vcs4w==", "cpu": [ "arm64" ], @@ -1174,9 +1172,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.53.2.tgz", - "integrity": "sha512-A6s4gJpomNBtJ2yioj8bflM2oogDwzUiMl2yNJ2v9E7++sHrSrsQ29fOfn5DM/iCzpWcebNYEdXpaK4tr2RhfQ==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.53.3.tgz", + "integrity": "sha512-Nr7SlQeqIBpOV6BHHGZgYBuSdanCXuw09hon14MGOLGmXAFYjx1wNvquVPmpZnl0tLjg25dEdr4IQ6GgyToCUA==", "cpu": [ "arm64" ], @@ -1188,9 +1186,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.53.2.tgz", - "integrity": "sha512-e6XqVmXlHrBlG56obu9gDRPW3O3hLxpwHpLsBJvuI8qqnsrtSZ9ERoWUXtPOkY8c78WghyPHZdmPhHLWNdAGEw==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.53.3.tgz", + "integrity": "sha512-DZ8N4CSNfl965CmPktJ8oBnfYr3F8dTTNBQkRlffnUarJ2ohudQD17sZBa097J8xhQ26AwhHJ5mvUyQW8ddTsQ==", "cpu": [ "x64" ], @@ -1202,9 +1200,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.53.2.tgz", - "integrity": "sha512-v0E9lJW8VsrwPux5Qe5CwmH/CF/2mQs6xU1MF3nmUxmZUCHazCjLgYvToOk+YuuUqLQBio1qkkREhxhc656ViA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.53.3.tgz", + "integrity": "sha512-yMTrCrK92aGyi7GuDNtGn2sNW+Gdb4vErx4t3Gv/Tr+1zRb8ax4z8GWVRfr3Jw8zJWvpGHNpss3vVlbF58DZ4w==", "cpu": [ "arm64" ], @@ -1216,9 +1214,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.53.2.tgz", - "integrity": "sha512-ClAmAPx3ZCHtp6ysl4XEhWU69GUB1D+s7G9YjHGhIGCSrsg00nEGRRZHmINYxkdoJehde8VIsDC5t9C0gb6yqA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.53.3.tgz", + "integrity": "sha512-lMfF8X7QhdQzseM6XaX0vbno2m3hlyZFhwcndRMw8fbAGUGL3WFMBdK0hbUBIUYcEcMhVLr1SIamDeuLBnXS+Q==", "cpu": [ "x64" ], @@ -1230,9 +1228,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.53.2.tgz", - "integrity": "sha512-EPlb95nUsz6Dd9Qy13fI5kUPXNSljaG9FiJ4YUGU1O/Q77i5DYFW5KR8g1OzTcdZUqQQ1KdDqsTohdFVwCwjqg==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.53.3.tgz", + "integrity": "sha512-k9oD15soC/Ln6d2Wv/JOFPzZXIAIFLp6B+i14KhxAfnq76ajt0EhYc5YPeX6W1xJkAdItcVT+JhKl1QZh44/qw==", "cpu": [ "arm" ], @@ -1244,9 +1242,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.53.2.tgz", - "integrity": "sha512-BOmnVW+khAUX+YZvNfa0tGTEMVVEerOxN0pDk2E6N6DsEIa2Ctj48FOMfNDdrwinocKaC7YXUZ1pHlKpnkja/Q==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.53.3.tgz", + "integrity": "sha512-vTNlKq+N6CK/8UktsrFuc+/7NlEYVxgaEgRXVUVK258Z5ymho29skzW1sutgYjqNnquGwVUObAaxae8rZ6YMhg==", "cpu": [ "arm" ], @@ -1258,9 +1256,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.53.2.tgz", - "integrity": "sha512-Xt2byDZ+6OVNuREgBXr4+CZDJtrVso5woFtpKdGPhpTPHcNG7D8YXeQzpNbFRxzTVqJf7kvPMCub/pcGUWgBjA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.53.3.tgz", + "integrity": "sha512-RGrFLWgMhSxRs/EWJMIFM1O5Mzuz3Xy3/mnxJp/5cVhZ2XoCAxJnmNsEyeMJtpK+wu0FJFWz+QF4mjCA7AUQ3w==", "cpu": [ "arm64" ], @@ -1272,9 +1270,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.53.2.tgz", - "integrity": "sha512-+LdZSldy/I9N8+klim/Y1HsKbJ3BbInHav5qE9Iy77dtHC/pibw1SR/fXlWyAk0ThnpRKoODwnAuSjqxFRDHUQ==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.53.3.tgz", + "integrity": "sha512-kASyvfBEWYPEwe0Qv4nfu6pNkITLTb32p4yTgzFCocHnJLAHs+9LjUu9ONIhvfT/5lv4YS5muBHyuV84epBo/A==", "cpu": [ "arm64" ], @@ -1286,9 +1284,9 @@ ] }, "node_modules/@rollup/rollup-linux-loong64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.53.2.tgz", - "integrity": "sha512-8ms8sjmyc1jWJS6WdNSA23rEfdjWB30LH8Wqj0Cqvv7qSHnvw6kgMMXRdop6hkmGPlyYBdRPkjJnj3KCUHV/uQ==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.53.3.tgz", + "integrity": "sha512-JiuKcp2teLJwQ7vkJ95EwESWkNRFJD7TQgYmCnrPtlu50b4XvT5MOmurWNrCj3IFdyjBQ5p9vnrX4JM6I8OE7g==", "cpu": [ "loong64" ], @@ -1300,9 +1298,9 @@ ] }, "node_modules/@rollup/rollup-linux-ppc64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.53.2.tgz", - "integrity": "sha512-3HRQLUQbpBDMmzoxPJYd3W6vrVHOo2cVW8RUo87Xz0JPJcBLBr5kZ1pGcQAhdZgX9VV7NbGNipah1omKKe23/g==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.53.3.tgz", + "integrity": "sha512-EoGSa8nd6d3T7zLuqdojxC20oBfNT8nexBbB/rkxgKj5T5vhpAQKKnD+h3UkoMuTyXkP5jTjK/ccNRmQrPNDuw==", "cpu": [ "ppc64" ], @@ -1314,9 +1312,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.53.2.tgz", - "integrity": "sha512-fMjKi+ojnmIvhk34gZP94vjogXNNUKMEYs+EDaB/5TG/wUkoeua7p7VCHnE6T2Tx+iaghAqQX8teQzcvrYpaQA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.53.3.tgz", + "integrity": "sha512-4s+Wped2IHXHPnAEbIB0YWBv7SDohqxobiiPA1FIWZpX+w9o2i4LezzH/NkFUl8LRci/8udci6cLq+jJQlh+0g==", "cpu": [ "riscv64" ], @@ -1328,9 +1326,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.53.2.tgz", - "integrity": "sha512-XuGFGU+VwUUV5kLvoAdi0Wz5Xbh2SrjIxCtZj6Wq8MDp4bflb/+ThZsVxokM7n0pcbkEr2h5/pzqzDYI7cCgLQ==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.53.3.tgz", + "integrity": "sha512-68k2g7+0vs2u9CxDt5ktXTngsxOQkSEV/xBbwlqYcUrAVh6P9EgMZvFsnHy4SEiUl46Xf0IObWVbMvPrr2gw8A==", "cpu": [ "riscv64" ], @@ -1342,9 +1340,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.53.2.tgz", - "integrity": "sha512-w6yjZF0P+NGzWR3AXWX9zc0DNEGdtvykB03uhonSHMRa+oWA6novflo2WaJr6JZakG2ucsyb+rvhrKac6NIy+w==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.53.3.tgz", + "integrity": "sha512-VYsFMpULAz87ZW6BVYw3I6sWesGpsP9OPcyKe8ofdg9LHxSbRMd7zrVrr5xi/3kMZtpWL/wC+UIJWJYVX5uTKg==", "cpu": [ "s390x" ], @@ -1356,9 +1354,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.53.2.tgz", - "integrity": "sha512-yo8d6tdfdeBArzC7T/PnHd7OypfI9cbuZzPnzLJIyKYFhAQ8SvlkKtKBMbXDxe1h03Rcr7u++nFS7tqXz87Gtw==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.53.3.tgz", + "integrity": "sha512-3EhFi1FU6YL8HTUJZ51imGJWEX//ajQPfqWLI3BQq4TlvHy4X0MOr5q3D2Zof/ka0d5FNdPwZXm3Yyib/UEd+w==", "cpu": [ "x64" ], @@ -1370,9 +1368,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.53.2.tgz", - "integrity": "sha512-ah59c1YkCxKExPP8O9PwOvs+XRLKwh/mV+3YdKqQ5AMQ0r4M4ZDuOrpWkUaqO7fzAHdINzV9tEVu8vNw48z0lA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.53.3.tgz", + "integrity": "sha512-eoROhjcc6HbZCJr+tvVT8X4fW3/5g/WkGvvmwz/88sDtSJzO7r/blvoBDgISDiCjDRZmHpwud7h+6Q9JxFwq1Q==", "cpu": [ "x64" ], @@ -1384,9 +1382,9 @@ ] }, "node_modules/@rollup/rollup-openharmony-arm64": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.53.2.tgz", - "integrity": "sha512-4VEd19Wmhr+Zy7hbUsFZ6YXEiP48hE//KPLCSVNY5RMGX2/7HZ+QkN55a3atM1C/BZCGIgqN+xrVgtdak2S9+A==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.53.3.tgz", + "integrity": "sha512-OueLAWgrNSPGAdUdIjSWXw+u/02BRTcnfw9PN41D2vq/JSEPnJnVuBgw18VkN8wcd4fjUs+jFHVM4t9+kBSNLw==", "cpu": [ "arm64" ], @@ -1398,9 +1396,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.53.2.tgz", - "integrity": "sha512-IlbHFYc/pQCgew/d5fslcy1KEaYVCJ44G8pajugd8VoOEI8ODhtb/j8XMhLpwHCMB3yk2J07ctup10gpw2nyMA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.53.3.tgz", + "integrity": "sha512-GOFuKpsxR/whszbF/bzydebLiXIHSgsEUp6M0JI8dWvi+fFa1TD6YQa4aSZHtpmh2/uAlj/Dy+nmby3TJ3pkTw==", "cpu": [ "arm64" ], @@ -1412,9 +1410,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.53.2.tgz", - "integrity": "sha512-lNlPEGgdUfSzdCWU176ku/dQRnA7W+Gp8d+cWv73jYrb8uT7HTVVxq62DUYxjbaByuf1Yk0RIIAbDzp+CnOTFg==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.53.3.tgz", + "integrity": "sha512-iah+THLcBJdpfZ1TstDFbKNznlzoxa8fmnFYK4V67HvmuNYkVdAywJSoteUszvBQ9/HqN2+9AZghbajMsFT+oA==", "cpu": [ "ia32" ], @@ -1426,9 +1424,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-gnu": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.53.2.tgz", - "integrity": "sha512-S6YojNVrHybQis2lYov1sd+uj7K0Q05NxHcGktuMMdIQ2VixGwAfbJ23NnlvvVV1bdpR2m5MsNBViHJKcA4ADw==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.53.3.tgz", + "integrity": "sha512-J9QDiOIZlZLdcot5NXEepDkstocktoVjkaKUtqzgzpt2yWjGlbYiKyp05rWwk4nypbYUNoFAztEgixoLaSETkg==", "cpu": [ "x64" ], @@ -1440,9 +1438,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.53.2.tgz", - "integrity": "sha512-k+/Rkcyx//P6fetPoLMb8pBeqJBNGx81uuf7iljX9++yNBVRDQgD04L+SVXmXmh5ZP4/WOp4mWF0kmi06PW2tA==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.53.3.tgz", + "integrity": "sha512-UhTd8u31dXadv0MopwGgNOBpUVROFKWVQgAg5N1ESyCz8AuBcMqm4AuTjrwgQKGDfoFuz02EuMRHQIw/frmYKQ==", "cpu": [ "x64" ], @@ -1498,7 +1496,6 @@ "integrity": "sha512-GNWcUTRBgIRJD5zj+Tq0fKOJ5XZajIiBroOF0yvj2bSU1WvNdYS/dn9UxwsujGW4JX06dnHyjV2y9rRaybH0iQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "undici-types": "~7.16.0" } @@ -1556,7 +1553,6 @@ "integrity": "sha512-lJi3PfxVmo0AkEY93ecfN+r8SofEqZNGByvHAI3GBLrvt1Cw6H5k1IM02nSzu0RfUafr2EvFSw0wAsZgubNplQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@typescript-eslint/scope-manager": "8.47.0", "@typescript-eslint/types": "8.47.0", @@ -1783,16 +1779,16 @@ } }, "node_modules/@vitest/expect": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.0.10.tgz", - "integrity": "sha512-3QkTX/lK39FBNwARCQRSQr0TP9+ywSdxSX+LgbJ2M1WmveXP72anTbnp2yl5fH+dU6SUmBzNMrDHs80G8G2DZg==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.0.12.tgz", + "integrity": "sha512-is+g0w8V3/ZhRNrRizrJNr8PFQKwYmctWlU4qg8zy5r9aIV5w8IxXLlfbbxJCwSpsVl2PXPTm2/zruqTqz3QSg==", "dev": true, "license": "MIT", "dependencies": { "@standard-schema/spec": "^1.0.0", "@types/chai": "^5.2.2", - "@vitest/spy": "4.0.10", - "@vitest/utils": "4.0.10", + "@vitest/spy": "4.0.12", + "@vitest/utils": "4.0.12", "chai": "^6.2.1", "tinyrainbow": "^3.0.3" }, @@ -1801,13 +1797,13 @@ } }, "node_modules/@vitest/mocker": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.0.10.tgz", - "integrity": "sha512-e2OfdexYkjkg8Hh3L9NVEfbwGXq5IZbDovkf30qW2tOh7Rh9sVtmSr2ztEXOFbymNxS4qjzLXUQIvATvN4B+lg==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.0.12.tgz", + "integrity": "sha512-GsmA/tD5Ht3RUFoz41mZsMU1AXch3lhmgbTnoSPTdH231g7S3ytNN1aU0bZDSyxWs8WA7KDyMPD5L4q6V6vj9w==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/spy": "4.0.10", + "@vitest/spy": "4.0.12", "estree-walker": "^3.0.3", "magic-string": "^0.30.21" }, @@ -1838,9 +1834,9 @@ } }, "node_modules/@vitest/pretty-format": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.0.10.tgz", - "integrity": "sha512-99EQbpa/zuDnvVjthwz5bH9o8iPefoQZ63WV8+bsRJZNw3qQSvSltfut8yu1Jc9mqOYi7pEbsKxYTi/rjaq6PA==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.0.12.tgz", + "integrity": "sha512-R7nMAcnienG17MvRN8TPMJiCG8rrZJblV9mhT7oMFdBXvS0x+QD6S1G4DxFusR2E0QIS73f7DqSR1n87rrmE+g==", "dev": true, "license": "MIT", "dependencies": { @@ -1851,13 +1847,13 @@ } }, "node_modules/@vitest/runner": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.0.10.tgz", - "integrity": "sha512-EXU2iSkKvNwtlL8L8doCpkyclw0mc/t4t9SeOnfOFPyqLmQwuceMPA4zJBa6jw0MKsZYbw7kAn+gl7HxrlB8UQ==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.0.12.tgz", + "integrity": "sha512-hDlCIJWuwlcLumfukPsNfPDOJokTv79hnOlf11V+n7E14rHNPz0Sp/BO6h8sh9qw4/UjZiKyYpVxK2ZNi+3ceQ==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/utils": "4.0.10", + "@vitest/utils": "4.0.12", "pathe": "^2.0.3" }, "funding": { @@ -1865,13 +1861,13 @@ } }, "node_modules/@vitest/snapshot": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.0.10.tgz", - "integrity": "sha512-2N4X2ZZl7kZw0qeGdQ41H0KND96L3qX1RgwuCfy6oUsF2ISGD/HpSbmms+CkIOsQmg2kulwfhJ4CI0asnZlvkg==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.0.12.tgz", + "integrity": "sha512-2jz9zAuBDUSbnfyixnyOd1S2YDBrZO23rt1bicAb6MA/ya5rHdKFRikPIDpBj/Dwvh6cbImDmudegnDAkHvmRQ==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "4.0.10", + "@vitest/pretty-format": "4.0.12", "magic-string": "^0.30.21", "pathe": "^2.0.3" }, @@ -1880,9 +1876,9 @@ } }, "node_modules/@vitest/spy": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.0.10.tgz", - "integrity": "sha512-AsY6sVS8OLb96GV5RoG8B6I35GAbNrC49AO+jNRF9YVGb/g9t+hzNm1H6kD0NDp8tt7VJLs6hb7YMkDXqu03iw==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.0.12.tgz", + "integrity": "sha512-GZjI9PPhiOYNX8Nsyqdw7JQB+u0BptL5fSnXiottAUBHlcMzgADV58A7SLTXXQwcN1yZ6gfd1DH+2bqjuUlCzw==", "dev": true, "license": "MIT", "funding": { @@ -1890,13 +1886,13 @@ } }, "node_modules/@vitest/utils": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.0.10.tgz", - "integrity": "sha512-kOuqWnEwZNtQxMKg3WmPK1vmhZu9WcoX69iwWjVz+jvKTsF1emzsv3eoPcDr6ykA3qP2bsCQE7CwqfNtAVzsmg==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.0.12.tgz", + "integrity": "sha512-DVS/TLkLdvGvj1avRy0LSmKfrcI9MNFvNGN6ECjTUHWJdlcgPDOXhjMis5Dh7rBH62nAmSXnkPbE+DZ5YD75Rw==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "4.0.10", + "@vitest/pretty-format": "4.0.12", "tinyrainbow": "^3.0.3" }, "funding": { @@ -1904,9 +1900,9 @@ } }, "node_modules/@vitest/web-worker": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/@vitest/web-worker/-/web-worker-4.0.10.tgz", - "integrity": "sha512-LHkEcF+976pMym0JEuXQ92vbFKEfcz67sXI3/KXE5d/BxXDe3eAmGmdoQkU/imrewtmrsg4+82PFxdGw7R1nrw==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/@vitest/web-worker/-/web-worker-4.0.12.tgz", + "integrity": "sha512-Ry28B/ZbeHRgrNbJEZMCwgjerOUFESV/u8l8ZPiEZ4SEtevG0qCeG0DDNaxK2PMYmwdjz9JKxEZOPqT6jBRqDw==", "dev": true, "license": "MIT", "dependencies": { @@ -1916,7 +1912,7 @@ "url": "https://opencollective.com/vitest" }, "peerDependencies": { - "vitest": "4.0.10" + "vitest": "4.0.12" } }, "node_modules/acorn": { @@ -1925,7 +1921,6 @@ "integrity": "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==", "dev": true, "license": "MIT", - "peer": true, "bin": { "acorn": "bin/acorn" }, @@ -2383,7 +2378,6 @@ "integrity": "sha512-BhHmn2yNOFA9H9JmmIVKJmd288g9hrVRDkdoIgRCRuSySRUHH7r/DI6aAXW9T1WwUuY3DFgrcaqB+deURBLR5g==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", @@ -3030,7 +3024,6 @@ "integrity": "sha512-454TI39PeRDW1LgpyLPyURtB4Zx1tklSr6+OFOipsxGUH1WMTvk6C65JQdrj455+DP2uJ1+veBEHTGFKWVLFoA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@acemir/cssom": "^0.9.23", "@asamuzakjp/dom-selector": "^6.7.4", @@ -3522,12 +3515,11 @@ } }, "node_modules/rollup": { - "version": "4.53.2", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.53.2.tgz", - "integrity": "sha512-MHngMYwGJVi6Fmnk6ISmnk7JAHRNF0UkuucA0CUW3N3a4KnONPEZz+vUanQP/ZC/iY1Qkf3bwPWzyY84wEks1g==", + "version": "4.53.3", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.53.3.tgz", + "integrity": "sha512-w8GmOxZfBmKknvdXU1sdM9NHcoQejwF/4mNgj2JuEEdRaHwwF12K7e9eXn1nLZ07ad+du76mkVsyeb2rKGllsA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@types/estree": "1.0.8" }, @@ -3539,28 +3531,28 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.53.2", - "@rollup/rollup-android-arm64": "4.53.2", - "@rollup/rollup-darwin-arm64": "4.53.2", - "@rollup/rollup-darwin-x64": "4.53.2", - "@rollup/rollup-freebsd-arm64": "4.53.2", - "@rollup/rollup-freebsd-x64": "4.53.2", - "@rollup/rollup-linux-arm-gnueabihf": "4.53.2", - "@rollup/rollup-linux-arm-musleabihf": "4.53.2", - "@rollup/rollup-linux-arm64-gnu": "4.53.2", - "@rollup/rollup-linux-arm64-musl": "4.53.2", - "@rollup/rollup-linux-loong64-gnu": "4.53.2", - "@rollup/rollup-linux-ppc64-gnu": "4.53.2", - "@rollup/rollup-linux-riscv64-gnu": "4.53.2", - "@rollup/rollup-linux-riscv64-musl": "4.53.2", - "@rollup/rollup-linux-s390x-gnu": "4.53.2", - "@rollup/rollup-linux-x64-gnu": "4.53.2", - "@rollup/rollup-linux-x64-musl": "4.53.2", - "@rollup/rollup-openharmony-arm64": "4.53.2", - "@rollup/rollup-win32-arm64-msvc": "4.53.2", - "@rollup/rollup-win32-ia32-msvc": "4.53.2", - "@rollup/rollup-win32-x64-gnu": "4.53.2", - "@rollup/rollup-win32-x64-msvc": "4.53.2", + "@rollup/rollup-android-arm-eabi": "4.53.3", + "@rollup/rollup-android-arm64": "4.53.3", + "@rollup/rollup-darwin-arm64": "4.53.3", + "@rollup/rollup-darwin-x64": "4.53.3", + "@rollup/rollup-freebsd-arm64": "4.53.3", + "@rollup/rollup-freebsd-x64": "4.53.3", + "@rollup/rollup-linux-arm-gnueabihf": "4.53.3", + "@rollup/rollup-linux-arm-musleabihf": "4.53.3", + "@rollup/rollup-linux-arm64-gnu": "4.53.3", + "@rollup/rollup-linux-arm64-musl": "4.53.3", + "@rollup/rollup-linux-loong64-gnu": "4.53.3", + "@rollup/rollup-linux-ppc64-gnu": "4.53.3", + "@rollup/rollup-linux-riscv64-gnu": "4.53.3", + "@rollup/rollup-linux-riscv64-musl": "4.53.3", + "@rollup/rollup-linux-s390x-gnu": "4.53.3", + "@rollup/rollup-linux-x64-gnu": "4.53.3", + "@rollup/rollup-linux-x64-musl": "4.53.3", + "@rollup/rollup-openharmony-arm64": "4.53.3", + "@rollup/rollup-win32-arm64-msvc": "4.53.3", + "@rollup/rollup-win32-ia32-msvc": "4.53.3", + "@rollup/rollup-win32-x64-gnu": "4.53.3", + "@rollup/rollup-win32-x64-msvc": "4.53.3", "fsevents": "~2.3.2" } }, @@ -3924,8 +3916,7 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", "dev": true, - "license": "0BSD", - "peer": true + "license": "0BSD" }, "node_modules/type-check": { "version": "0.4.0", @@ -3946,7 +3937,6 @@ "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", "dev": true, "license": "Apache-2.0", - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -3973,12 +3963,11 @@ } }, "node_modules/vite": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/vite/-/vite-7.2.2.tgz", - "integrity": "sha512-BxAKBWmIbrDgrokdGZH1IgkIk/5mMHDreLDmCJ0qpyJaAteP8NvMhkwr/ZCQNqNH97bw/dANTE9PDzqwJghfMQ==", + "version": "7.2.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-7.2.4.tgz", + "integrity": "sha512-NL8jTlbo0Tn4dUEXEsUg8KeyG/Lkmc4Fnzb8JXN/Ykm9G4HNImjtABMJgkQoVjOBN/j2WAwDTRytdqJbZsah7w==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "esbuild": "^0.25.0", "fdir": "^6.5.0", @@ -4049,20 +4038,19 @@ } }, "node_modules/vitest": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.0.10.tgz", - "integrity": "sha512-2Fqty3MM9CDwOVet/jaQalYlbcjATZwPYGcqpiYQqgQ/dLC7GuHdISKgTYIVF/kaishKxLzleKWWfbSDklyIKg==", + "version": "4.0.12", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.0.12.tgz", + "integrity": "sha512-pmW4GCKQ8t5Ko1jYjC3SqOr7TUKN7uHOHB/XGsAIb69eYu6d1ionGSsb5H9chmPf+WeXt0VE7jTXsB1IvWoNbw==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@vitest/expect": "4.0.10", - "@vitest/mocker": "4.0.10", - "@vitest/pretty-format": "4.0.10", - "@vitest/runner": "4.0.10", - "@vitest/snapshot": "4.0.10", - "@vitest/spy": "4.0.10", - "@vitest/utils": "4.0.10", + "@vitest/expect": "4.0.12", + "@vitest/mocker": "4.0.12", + "@vitest/pretty-format": "4.0.12", + "@vitest/runner": "4.0.12", + "@vitest/snapshot": "4.0.12", + "@vitest/spy": "4.0.12", + "@vitest/utils": "4.0.12", "debug": "^4.4.3", "es-module-lexer": "^1.7.0", "expect-type": "^1.2.2", @@ -4088,12 +4076,13 @@ }, "peerDependencies": { "@edge-runtime/vm": "*", + "@opentelemetry/api": "^1.9.0", "@types/debug": "^4.1.12", "@types/node": "^20.0.0 || ^22.0.0 || >=24.0.0", - "@vitest/browser-playwright": "4.0.10", - "@vitest/browser-preview": "4.0.10", - "@vitest/browser-webdriverio": "4.0.10", - "@vitest/ui": "4.0.10", + "@vitest/browser-playwright": "4.0.12", + "@vitest/browser-preview": "4.0.12", + "@vitest/browser-webdriverio": "4.0.12", + "@vitest/ui": "4.0.12", "happy-dom": "*", "jsdom": "*" }, @@ -4101,6 +4090,9 @@ "@edge-runtime/vm": { "optional": true }, + "@opentelemetry/api": { + "optional": true + }, "@types/debug": { "optional": true }, @@ -4320,8 +4312,7 @@ "packages/cache": { "name": "@next2d/cache", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/core": { "name": "@next2d/core", @@ -4345,7 +4336,6 @@ "name": "@next2d/display", "version": "*", "license": "MIT", - "peer": true, "peerDependencies": { "@next2d/events": "file:../events", "@next2d/filters": "file:../filters", @@ -4360,26 +4350,22 @@ "packages/events": { "name": "@next2d/events", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/filters": { "name": "@next2d/filters", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/geom": { "name": "@next2d/geom", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/media": { "name": "@next2d/media", "version": "*", "license": "MIT", - "peer": true, "peerDependencies": { "@next2d/display": "file:../display", "@next2d/events": "file:../events", @@ -4390,14 +4376,12 @@ "packages/net": { "name": "@next2d/net", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/render-queue": { "name": "@next2d/render-queue", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/renderer": { "name": "@next2d/renderer", @@ -4427,8 +4411,7 @@ "packages/texture-packer": { "name": "@next2d/texture-packer", "version": "*", - "license": "MIT", - "peer": true + "license": "MIT" }, "packages/ui": { "name": "@next2d/ui", diff --git a/package.json b/package.json index 3d65c6cc..f4420788 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@next2d/player", - "version": "2.10.0", + "version": "2.11.0", "description": "Experience the fast and beautiful anti-aliased rendering of WebGL. You can create rich, interactive graphics, cross-platform applications and games without worrying about browser or device compatibility.", "author": "Toshiyuki Ienaga (https://github.com/ienaga/)", "license": "MIT", @@ -54,16 +54,16 @@ "@types/node": "^24.10.1", "@typescript-eslint/eslint-plugin": "^8.47.0", "@typescript-eslint/parser": "^8.47.0", - "@vitest/web-worker": "^4.0.10", + "@vitest/web-worker": "^4.0.12", "eslint": "^9.39.1", "eslint-plugin-unused-imports": "^4.3.0", "globals": "^16.5.0", "jsdom": "^27.2.0", - "rollup": "^4.53.2", + "rollup": "^4.53.3", "tslib": "^2.8.1", "typescript": "^5.9.3", - "vite": "^7.2.2", - "vitest": "^4.0.10", + "vite": "^7.2.4", + "vitest": "^4.0.12", "vitest-webgl-canvas-mock": "^1.1.0", "xml2js": "^0.6.2" }, diff --git a/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.test.ts b/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.test.ts new file mode 100644 index 00000000..82689930 --- /dev/null +++ b/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.test.ts @@ -0,0 +1,189 @@ +import { describe, expect, it, vi, beforeEach } from "vitest"; + +// Mock modules at the top level +const mockAttachmentObject = { + "frameBuffer": "mockFrameBuffer", + "texture": "mockTexture", + "width": 512, + "height": 1 +}; + +let mockScissorBox = [0, 0, 0, 0]; +let currentAttachment: any = null; +let scissorTestEnabled = false; +let currentScissor = [0, 0, 0, 0]; +let bindCallCount = 0; +let enableCalls: string[] = []; +let disableCalls: string[] = []; +let scissorCalls: number[][] = []; + +vi.mock("../../../WebGLUtil.ts", async (importOriginal) => +{ + const mod = await importOriginal(); + return { + ...mod, + $gl: { + "SCISSOR_TEST": "SCISSOR_TEST", + "SCISSOR_BOX": "SCISSOR_BOX", + "getParameter": vi.fn((param) => + { + if (param === "SCISSOR_BOX") { + return mockScissorBox; + } + return null; + }), + "disable": vi.fn((cap) => + { + disableCalls.push(cap); + scissorTestEnabled = false; + }), + "enable": vi.fn((cap) => + { + enableCalls.push(cap); + scissorTestEnabled = true; + }), + "scissor": vi.fn((x, y, w, h) => + { + currentScissor = [x, y, w, h]; + scissorCalls.push([x, y, w, h]); + }) + }, + $context: { + get currentAttachmentObject() { + return currentAttachment; + }, + "bind": vi.fn(() => + { + bindCallCount++; + }) + } + }; +}); + +vi.mock("../../GradientLUTGenerator.ts", async (importOriginal) => +{ + const mod = await importOriginal(); + return { + ...mod, + $getGradientAttachmentObject: vi.fn(() => mockAttachmentObject), + $getGradientLUTGeneratorMaxLength: vi.fn(() => 10), + $rgbToLinearTable: new Float32Array(256), + $rgbIdentityTable: new Float32Array(256) + }; +}); + +vi.mock("../../../Blend/service/BlendOneZeroService.ts", () => ({ + execute: vi.fn() +})); + +vi.mock("../../../Blend/service/BlendResetService.ts", () => ({ + execute: vi.fn() +})); + +vi.mock("../../Variants/GradientLUT/service/VariantsGradientLUTShaderService.ts", () => ({ + execute: vi.fn(() => ({ + useProgram: vi.fn(), + bindUniform: vi.fn() + })) +})); + +vi.mock("../service/GradientLUTSetUniformService.ts", () => ({ + execute: vi.fn() +})); + +vi.mock("./GradientLUTGeneratorFillTextureUseCase.ts", () => ({ + execute: vi.fn() +})); + +import { execute } from "./GradientLUTGenerateShapeTextureUseCase"; + +describe("GradientLUTGenerateShapeTextureUseCase.js method test", () => +{ + beforeEach(() => + { + vi.clearAllMocks(); + scissorTestEnabled = false; + currentScissor = [0, 0, 0, 0]; + bindCallCount = 0; + enableCalls = []; + disableCalls = []; + scissorCalls = []; + }); + + it("test case - linear interpolation with single stop segment", () => + { + mockScissorBox = [10, 20, 100, 50]; + currentAttachment = mockAttachmentObject; + + // RGB linear interpolation (interpolation = 0) + const stops = [ + 0, 255, 0, 0, 255, // offset=0, R=255, G=0, B=0, A=255 + 255, 0, 255, 0, 255 // offset=255, R=0, G=255, B=0, A=255 + ]; + const interpolation = 0; + + const result = execute(stops, interpolation); + + // シザーテストが無効化され、その後再び有効化されたことを確認 + expect(scissorTestEnabled).toBe(true); + + // シザーボックスが復元されたことを確認 + expect(currentScissor).toEqual(mockScissorBox); + + // 結果のテクスチャが返されることを確認 + expect(result).toBe("mockTexture"); + }); + + it("test case - RGB interpolation with multiple stop segments", () => + { + mockScissorBox = [0, 0, 512, 1]; + currentAttachment = null; + + // RGB interpolation (interpolation = 1) + // 3 stops = 15 values (5 per stop) + const stops = [ + 0, 255, 0, 0, 255, + 127, 0, 255, 0, 255, + 255, 0, 0, 255, 255 + ]; + const interpolation = 1; + + const result = execute(stops, interpolation); + + expect(result).toBe("mockTexture"); + }); + + it("test case - no current attachment (null case)", () => + { + mockScissorBox = [5, 10, 200, 100]; + currentAttachment = null; + + const stops = [0, 255, 0, 0, 255, 255, 0, 255, 0, 255]; + const interpolation = 0; + + const result = execute(stops, interpolation); + + // currentAttachment が null なので、bind は1回だけ呼ばれる(gradientAttachmentObject のみ) + expect(bindCallCount).toBe(1); + expect(result).toBe("mockTexture"); + }); + + it("test case - verifies scissor test is properly restored", () => + { + mockScissorBox = [15, 25, 150, 75]; + currentAttachment = mockAttachmentObject; + + const stops = [0, 255, 0, 0, 255, 255, 0, 255, 0, 255]; + const interpolation = 0; + + execute(stops, interpolation); + + // シザーテストが最初に無効化され、最後に有効化されることを確認 + expect(disableCalls).toContain("SCISSOR_TEST"); + expect(enableCalls).toContain("SCISSOR_TEST"); + + // シザーボックスが元の値で復元されることを確認 + const lastScissorCall = scissorCalls[scissorCalls.length - 1]; + expect(lastScissorCall).toEqual(mockScissorBox); + }); +}); diff --git a/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.ts b/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.ts index 87c1d9e0..dcb51b3b 100644 --- a/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.ts +++ b/packages/webgl/src/Shader/GradientLUTGenerator/usecase/GradientLUTGenerateShapeTextureUseCase.ts @@ -4,7 +4,6 @@ import { execute as blendOneZeroService } from "../../../Blend/service/BlendOneZ import { execute as blendResetService } from "../../../Blend/service/BlendResetService"; import { execute as gradientLUTSetUniformService } from "../service/GradientLUTSetUniformService"; import { execute as gradientLUTGeneratorFillTextureUseCase } from "./GradientLUTGeneratorFillTextureUseCase"; -import { execute as contextBeginNodeRenderingService } from "../../../Context/service/ContextBeginNodeRenderingService"; import { $gl, $context @@ -69,9 +68,9 @@ export const execute = (stops: number[], interpolation: number): ITextureObject $context.bind(currentAttachment); } - contextBeginNodeRenderingService( - scissorBox[0], scissorBox[1], scissorBox[2], scissorBox[3] - ); + // bugfix: @see https://github.com/Next2D/player/issues/234 + $gl.enable($gl.SCISSOR_TEST); + $gl.scissor(scissorBox[0], scissorBox[1], scissorBox[2], scissorBox[3]); return gradientAttachmentObject.texture as NonNullable; }; \ No newline at end of file diff --git a/src/index.ts b/src/index.ts index 2d1c3697..f32eb6f2 100644 --- a/src/index.ts +++ b/src/index.ts @@ -3,7 +3,7 @@ import { Next2D } from "@next2d/core"; if (!("next2d" in window)) { - console.log("%c Next2D Player %c 2.10.0 %c https://next2d.app", + console.log("%c Next2D Player %c 2.11.0 %c https://next2d.app", "color: #fff; background: #5f5f5f", "color: #fff; background: #4bc729", "");