Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
Cube-J committed Sep 28, 2023
1 parent aca5a4d commit db0f578
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion U-10666/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
</head>
<body>
<button id="btn-open-camera">open camera</button>
<div id="div-ui-container" style="margin-top: 10px;width: 90vw; height: 80vh"></div>
<div
id="div-ui-container"
style="margin-top: 10px; width: 90vw; height: 80vh"
></div>

<!-- Use 'eruda' to show console in mobile phone -->
<script src="//cdn.jsdelivr.net/npm/eruda"></script>
Expand Down Expand Up @@ -43,6 +46,15 @@
await initDCE();
await cameraEnhancer.open();

console.log(
"cameras returned by 'navigator.mediaDevices.enumerateDevices()': "
);
(await navigator.mediaDevices.enumerateDevices()).forEach((device) => {
if (device.kind === "videoinput") {
console.log(JSON.stringify(device));
}
});

isOpening = false;
};
</script>
Expand Down

0 comments on commit db0f578

Please sign in to comment.