Fix calculateRotationCenter for SVG skins

This commit is contained in:
adroitwhiz
2019-07-20 17:27:45 -04:00
parent cc5fea803e
commit dce90a3f56

View File

@@ -147,8 +147,9 @@ class SVGSkin extends Skin {
this._maxTextureScale = testScale;
}
if (typeof rotationCenter === 'undefined') rotationCenter = this.calculateRotationCenter();
this.size = this._svgRenderer.size;
if (typeof rotationCenter === 'undefined') rotationCenter = this.calculateRotationCenter();
this._viewOffset = this._svgRenderer.viewOffset;
// Reset rawRotationCenter when we update viewOffset.
this._rawRotationCenter = [NaN, NaN];