修复高清画布缩放问题
This commit is contained in:
parent
d4d70e0c9a
commit
bc8148fea8
@ -37,7 +37,7 @@ maps.prototype._resetFloorImages = function () {
|
|||||||
maps.prototype._setHDCanvasSize = function (ctx, width, height) {
|
maps.prototype._setHDCanvasSize = function (ctx, width, height) {
|
||||||
if (main.replayChecking) return
|
if (main.replayChecking) return
|
||||||
ctx.setTransform(1, 0, 0, 1, 0, 0);
|
ctx.setTransform(1, 0, 0, 1, 0, 0);
|
||||||
var ratio = core.domStyle.scale;
|
var ratio = core.domStyle.ratio;
|
||||||
ratio *= devicePixelRatio;
|
ratio *= devicePixelRatio;
|
||||||
if (width != null) ctx.canvas.width = width * ratio;
|
if (width != null) ctx.canvas.width = width * ratio;
|
||||||
if (height != null) ctx.canvas.height = height * ratio;
|
if (height != null) ctx.canvas.height = height * ratio;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user