0

I am using a Python based script to access a webcam and process with OpenCV:

https://github.com/pageauc/speed-camera

The issue is the images get corrupted and choppy when viewing (see the band at the bottom):

enter image description here

This pixilation gets so bad (this is only a screen shot and it is flickering all over the screen) the OpenCV kicks in and thinks there is movement etc.

This is the webcam:

https://www.logitech.com/en-us/products/webcams/c270-hd-webcam.960-000694.html

Some context to my install:

  • running Debian GNU 10 via parallels on my MacBook Pro
  • the same webcam works fine day to day on my Mac for Teams / Zoom etc.
  • I fully understand this may be an issue with the virtual machine

Any ideas would be apprieciated.

Dan Tappin
  • 2,692
  • 3
  • 37
  • 77
  • camera and/or USB is physically broken, sorry – Christoph Rackwitz Jun 11 '21 at 18:23
  • It's not. I confirmed that in my question. In fact I have two of these exact same cameras and they both exhibit the same issue and work fine on my Mac. – Dan Tappin Jun 11 '21 at 19:27
  • great. now run guvcview or VLC to check if it's OpenCV, or just the "parallels" thingy. by the way, that repository isn't just "a script". it's a huge pile of stuff, involving all kinds of libraries and frameworks and abstraction. use a minimal reproducible example for opencv, which opens a VideoCapture, does imshow and waitKey, and nothing much else (`pip3 install opencv-python` and python code is permissible) – Christoph Rackwitz Jun 11 '21 at 20:25
  • Yes - I was being a bit simplistic in calling it a 'script'. It's not just OpenCV - I opened this webcam with `cheese` can get the same choppy video. I did some more digging and it seems to be just this exact model of webcam that I have (two of). There are bunch of related posts like this: https://stackoverflow.com/questions/42431580/opencv-logitech-p270-giving-corrupt-data#42479823. I suspect I may just try a different camera. – Dan Tappin Jun 11 '21 at 22:39

0 Answers0