源码:

import cv2 as cv
import numpy as np

def video_demo():
    capture = cv.VideoCapture(0)
    while(True):
        ret, frame = capture.read()
        frame = cv.flip(frame, 1)
        cv.imshow("video", frame)
        c = cv.waitKey(40)
        # ESC Will Break Capture
        if c == 27:
            break

video_demo()
cv.waitKey(0)
cv.destroyAllWindows()

图像:
OpenCV读取UsbCam的图像

相关文章:

  • 2021-12-27
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-13
  • 2021-07-04
  • 2021-07-18
  • 2021-04-04
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-02
  • 2022-12-23
  • 2021-12-01
  • 2021-05-16
相关资源
相似解决方案