Mercurial > code > home > repos > light9
comparison web/calibrate/Light9Camera.ts @ 2418:9bb0eb587d5b
640x480 camera res
author | drewp@bigasterisk.com |
---|---|
date | Tue, 21 May 2024 11:58:13 -0700 |
parents | ae4b90efb55a |
children | e3af0ac507c8 |
comparison
equal
deleted
inserted
replaced
2417:ae4b90efb55a | 2418:9bb0eb587d5b |
---|---|
74 | 74 |
75 const constraints: MediaStreamConstraints = { | 75 const constraints: MediaStreamConstraints = { |
76 video: { | 76 video: { |
77 facingMode: { ideal: "environment" }, | 77 facingMode: { ideal: "environment" }, |
78 frameRate: { max: 10 }, | 78 frameRate: { max: 10 }, |
79 width: 640, | |
80 height: 480, | |
79 }, | 81 }, |
80 }; | 82 }; |
81 const stream = await navigator.mediaDevices.getUserMedia(constraints); | 83 const stream = await navigator.mediaDevices.getUserMedia(constraints); |
82 const t = stream.getVideoTracks()[0]; | 84 const t = stream.getVideoTracks()[0]; |
83 await t.applyConstraints({ | 85 await t.applyConstraints({ |