deepsea 11 months ago
parent
commit
fd53f12e52
1 changed files with 2 additions and 6 deletions
  1. 2 6
      src/store/modules/common/mutations.js

+ 2 - 6
src/store/modules/common/mutations.js

@@ -112,14 +112,10 @@ export default {
         let width = parseFloat(style.width);
         let height = parseFloat(style.height);
 
-        let ratio = devicePixelRatio - (devicePixelRatio / 10);
+        let ratio = 1.8;
         window.renderWidth = width * ratio;
         window.renderHeight = height * ratio;
-        window.sdkInstance.sceneRenderer.updateScreenSize(width, height);
-        element.width = (width * 2) * ratio;
-        element.height = (height * 2) * ratio;
-        element.style.width = (width * ratio)+'px';
-        element.style.height = (height * ratio)+'px';
+        window.sdkInstance.sceneRenderer.updateScreenSize(width * ratio, height * ratio);
         element.style.marginLeft = ((width - (width * ratio)) / 2) + 'px';
         element.style.marginTop = ((height - (height * ratio)) / 2) + 'px';
         let playersmall = document.getElementById('playersmall')