limits sprite radius to 255
This commit is contained in:
parent
581d7a337d
commit
aabf0f234c
@ -78,7 +78,8 @@
|
||||
if (st['marker-fill-opacity'] !== undefined || st['marker-opacity'] !== undefined) {
|
||||
ctx.globalAlpha = st['marker-fill-opacity'] || st['marker-opacity'];
|
||||
}
|
||||
ctx.drawImage(img, 0, 0, img.width, img.height);
|
||||
var maxSpriteRadius = 255;
|
||||
ctx.drawImage(img, 0, 0, Math.min(img.width, maxSpriteRadius), Math.min(img.height, maxSpriteRadius));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user