Skip to content

Commit

Permalink
fix zoom multiplier
Browse files Browse the repository at this point in the history
  • Loading branch information
yashrajbharti committed Jun 12, 2024
1 parent 1ff1a55 commit d945af9
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion js/stream.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const streamWebCamVideo = (isFrontCamera = true) => {

input.oninput = function (event) {
track.applyConstraints({ advanced: [{ zoom: event.target.value }] });
document.querySelector(".slider").style.left = input.value * capabilities.zoom.max + "px";
document.querySelector(".slider").style.left = input.value * 50 + "px";
}
input.hidden = false;
document.querySelector(".range-container").style.visibility = "visible"
Expand Down
1 change: 0 additions & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -227,5 +227,4 @@ video.flip {
.range-container .slider{
position: absolute;
left: 0;
padding: 0 3px;
}

0 comments on commit d945af9

Please sign in to comment.