mirror of
https://github.com/netbymatt/ws4kp.git
synced 2026-04-22 11:39:30 -07:00
remove debug timing
This commit is contained in:
@@ -12,7 +12,6 @@ const baseMapImages = new Promise((resolve) => {
|
|||||||
fetchAsBlob('/images/maps/radar.webp').then((blob) => {
|
fetchAsBlob('/images/maps/radar.webp').then((blob) => {
|
||||||
createImageBitmap(blob).then((imageBitmap) => {
|
createImageBitmap(blob).then((imageBitmap) => {
|
||||||
// extract the black pixels to overlay on to the final image (boundaries)
|
// extract the black pixels to overlay on to the final image (boundaries)
|
||||||
console.time('radar-overlay');
|
|
||||||
const canvas = new OffscreenCanvas(imageBitmap.width, imageBitmap.height);
|
const canvas = new OffscreenCanvas(imageBitmap.width, imageBitmap.height);
|
||||||
const context = canvas.getContext('2d');
|
const context = canvas.getContext('2d');
|
||||||
context.drawImage(imageBitmap, 0, 0);
|
context.drawImage(imageBitmap, 0, 0);
|
||||||
@@ -28,7 +27,6 @@ const baseMapImages = new Promise((resolve) => {
|
|||||||
// write the image data back
|
// write the image data back
|
||||||
context.putImageData(imageData, 0, 0);
|
context.putImageData(imageData, 0, 0);
|
||||||
|
|
||||||
console.timeEnd('radar-overlay');
|
|
||||||
resolve({
|
resolve({
|
||||||
fullMap: imageBitmap,
|
fullMap: imageBitmap,
|
||||||
overlay: canvas,
|
overlay: canvas,
|
||||||
|
|||||||
Reference in New Issue
Block a user