Spaces:
Running
Running
Update index.html
Browse files- index.html +9 -8
index.html
CHANGED
|
@@ -141,14 +141,15 @@
|
|
| 141 |
responAudio.currentTime = 0;
|
| 142 |
}).catch(()=>console.log("Audio siap"));
|
| 143 |
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
|
| 147 |
-
}
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
|
|
|
| 152 |
});
|
| 153 |
</script>
|
| 154 |
</body>
|
|
|
|
| 141 |
responAudio.currentTime = 0;
|
| 142 |
}).catch(()=>console.log("Audio siap"));
|
| 143 |
|
| 144 |
+
// Nyalakan Kamera (Versi Ringan)
|
| 145 |
+
const camera = new Camera(videoElement, {
|
| 146 |
+
onFrame: async () => {
|
| 147 |
+
await hands.send({image: videoElement});
|
| 148 |
+
},
|
| 149 |
+
width: 320, // Ubah dari 640 menjadi 320
|
| 150 |
+
height: 240 // Ubah dari 480 menjadi 240
|
| 151 |
+
});
|
| 152 |
+
camera.start();
|
| 153 |
});
|
| 154 |
</script>
|
| 155 |
</body>
|