gemercheung 3 anni fa
parent
commit
069bc95b2c
7 ha cambiato i file con 9476 aggiunte e 1748 eliminazioni
  1. 11 0
      dist/index.css
  2. 54 0
      dist/index.html
  3. 6 6
      dist/js/index.js
  4. 1 1
      dist/js/index.js.map
  5. 7654 0
      package-lock.json
  6. 2 1
      src/main.js
  7. 1748 1740
      yarn.lock

File diff suppressed because it is too large
+ 11 - 0
dist/index.css


+ 54 - 0
dist/index.html

@@ -5,6 +5,7 @@
     <meta http-equiv="X-UA-Compatible" content="IE=edge">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <title>Document</title>
+    <link rel="stylesheet" href="./index.css" />
    
 </head>
 <body>
@@ -94,6 +95,59 @@
 
     </script>
 
+    <div id="root">
+        <div id="canvas">
+
+        </div>
+        <div class="debug_control_btns">
+            <button class="debugger1">Toggle Stats</button>
+            <button class="debugger2">取消低模着色</button>
+            <button class="debugger3">画质:高</button>
+            <button class="font-size-small debugger4" onclick="room.debug.toggleNearbyBreathPoint">Toggle周边呼吸点</button>
+
+            <button class="font-size-small debugger5" onclick="room.debug.toggleTapBreathPoint">Toggle点击呼吸点</button>
+            <button class="font-size-small debugger6" >录制码流(10s)</button>
+        </div>
+   
+    </div>
+    <script type="module">
+        document.querySelector('.debugger1').onclick = ()=>{
+            var y, b;
+                  (y = room.stats) != null && y.isShow
+                    ? room.stats.hide()
+                    : (b = room.stats) == null || b.show();
+        }
+        document.querySelector('.debugger2').onclick = ()=>{
+            room.debug.toggleSceneshading(), r(room.debug.isSceneShading);
+        }
+        document.querySelector('.debugger3').onclick = ()=>{
+            let y = "average";
+                  n === "high"
+                    ? (y = "average")
+                    : n === "average"
+                    ? (y = "low")
+                    : n === "low"
+                    ? (y = "high")
+                    : (y = "average"),
+                    o(y),
+                    room.setPictureQualityLevel(y);
+        }
+        document.querySelector('.debugger4').onclick = ()=>{
+            room.debug.toggleNearbyBreathPoint();
+        }
+        document.querySelector('.debugger5').onclick = ()=>{
+            room.debug.toggleTapBreathPoint();
+        }
+        document.querySelector('.debugger6').onclick = ()=>{
+            room.debug.dumpStream(() => {
+                    //   toast("\u5F55\u5236\u5B8C\u6210");
+                    });
+            // toast("\u5F00\u59CB\u5F55\u5236");
+        }
+
+
+    </script>
+
     <script src="js/index.js"></script>
 </body>
 </html>

+ 6 - 6
dist/js/index.js

@@ -1,9 +1,9 @@
-/**
-* Name: Metaverse
-* Date: 2022/4/8
-* Author: https://www.4dkankan.com
-* Copyright © 2022 4DAGE Co., Ltd. All rights reserved.
-* Licensed under the GLP license
+/**
+* Name: Metaverse
+* Date: 2022/4/8
+* Author: https://www.4dkankan.com
+* Copyright © 2022 4DAGE Co., Ltd. All rights reserved.
+* Licensed under the GLP license
 */
 (function (factory) {
   typeof define === 'function' && define.amd ? define(factory) :

File diff suppressed because it is too large
+ 1 - 1
dist/js/index.js.map


File diff suppressed because it is too large
+ 7654 - 0
package-lock.json


+ 2 - 1
src/main.js

@@ -26,6 +26,7 @@ const l = async()=>{
     }
 
     try {
+
         room = await xverse.joinRoom({
             canvas: f,
             skinId: v,
@@ -43,7 +44,7 @@ const l = async()=>{
             objectFit: b,
             hasAvatar: !0,
             syncToOthers: !0
-        }),
+        })
         u(),
         c(),
         window.room = room,

File diff suppressed because it is too large
+ 1748 - 1740
yarn.lock