return buffer

This commit is contained in:
2025-09-18 17:11:53 +09:00
parent cb371dcf6f
commit 97fc2f40db

View File

@ -126,7 +126,7 @@ export async function generateTilesForZoomLevel(uploadDir: string, tileFolder: s
Logger.log('sharping step 2')
if (initialZoomImage) {
await sharp(initialZoomImage.data.buffer)
await sharp(initialZoomImage.data)
.resize({
width: roundUpToNearest(Math.ceil(boundsWidthPixel) + Math.ceil(paddingLeftPixel) + Math.ceil(paddingRightPixel), Math.abs(minX - (maxX + 1))),
height: roundUpToNearest(Math.ceil(boundsHeightPixel) + Math.ceil(paddingTopPixel) + Math.ceil(paddingBottomPixel), Math.abs(minY - (maxY + 1))),