getCamera function

VideoCapture getCamera(
  1. CameraName name
)

Returns the camera depending on device program is running

Uses cameraNames or cameraIndexes

Implementation

VideoCapture getCamera(CameraName name) => Platform.isWindows
  ? VideoCapture.fromDevice(cameraIndexes[name]!)
  : VideoCapture.fromFile(cameraNames[name]!);