Merge pull request #2116 from rvv-bouvet/fix/draw-tiles-without-canvas

fix: avoid crash when setting useCanvas to false
This commit is contained in:
Ian Gilman 2022-03-01 14:03:49 -08:00 committed by GitHub
commit 3e5e12722a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2055,7 +2055,7 @@ function drawTiles( tiledImage, lastDrawn ) {
imageZoom > tiledImage.smoothTileEdgesMinZoom &&
!tiledImage.iOSDevice &&
tiledImage.getRotation(true) % 360 === 0 && // TODO: support tile edge smoothing with tiled image rotation.
$.supportsCanvas) {
$.supportsCanvas && tiledImage.viewer.useCanvas) {
// When zoomed in a lot (>100%) the tile edges are visible.
// So we have to composite them at ~100% and scale them up together.
// Note: Disabled on iOS devices per default as it causes a native crash