Optional
centerA boolean value that indicates whether to crop the video frame from center.
If true, resizeWidth
and resizeHeight
must be specified; then an image
of size [resizeWidth, resizeHeight]
is taken from the center of the frame
without scaling. If false, the entire image is returned (perhaps scaled to
fit in [resizeWidth, resizeHeight]
, if those are provided).
Optional
deviceA string used to request a specific camera. The deviceId can be obtained by
calling mediaDevices.enumerateDevices()
.
Optional
facingA string specifying which camera to use on device. If the value is 'user', it will use front camera. If the value is 'environment', it will use rear camera.
Optional
resizeSpecifies the height of the output tensor. The actual height of the HTMLVideoElement (if provided) can be different and the final image will be resized to match resizeHeight.
Optional
resizeSpecifies the width of the output tensor. The actual width of the HTMLVideoElement (if provided) can be different and the final image will be resized to match resizeWidth.
Generated using TypeDoc
Interface configuring data from webcam video stream.