USB Webcam in Place of the Raspberry Pi Camera Module?

233 views
Skip to first unread message

John Hoppa

unread,
Jul 26, 2019, 3:51:29 PM7/26/19
to Raspberry Pi Film Capture
Has anyone had any experience using a usb webcam with this project?  I'm having difficulty using modified lens with the equipment that I now have.  I'm using a modified dual-8 projector that just has no room to internally mount a modified pi camera.  I've tried using both the V.1 and V.2 cameras externally with macro bellows and 35mm or 55mm lens.  With both lens I am able to record full framed sharp images.  However, lens shading remains an issue.  I've implemented Dominique Galland's calibration correction process and tried many re-calibrations using a couple LED light sources but am unable to completely correct the image.

A few years ago I converted a couple rolls each of 8 and super 8 mm film using this projector with a 2 megapixel USB webcam with a CCD sensor.  I used linux guvcview and a modified mouse to record png images.  This was triggered by breaking the beam of an IR sensor circuit from an old IBM floppy drive.  The results were usable - the quality was what one would expect from a 2 megapixel camera although lighting and color were uniform across the image.  I was able to capture at a rate of 1 image per second.  Post processing was done using GIMP (batch mode), avidemux, virtualdub, and VideoFred's avisynth film restoration scripts (on WINE in Linux).

Before investing both time and funds in another projector I would like to explore modification of the camera.py file to capture the images from a usb camera rather than a pi camera.  My thought is to use fswebcam for the capture and v4lc-ctl (or any other similar program) to set the camera adjustments and still have all the controls that the program now offers.  I have limited basic python programing knowledge.  I can understand a script and make modifications usually after much googling.  I'm 78 years old and have about 30 reels of film that I'd like to convert to pass on to my children.

Has anyone had any experience with using a webcam on the Pi? Any thoughts on this approach and any help identifying the changes that need to be made to the current files would be much appreciated. If this becomes a viable approach using my current modified webcam I will ultimately invest in an 8 Megapixel 4K USB Camera body and use it for my captures.

A big "thank you" to Joe Herman for all his work and to all the folks who have added refinements to this project.  Great ideas here!

John

Aden Beckitt

unread,
May 30, 2020, 9:36:26 PM5/30/20
to Raspberry Pi Film Capture
Hi John, did you get anywhere with this?

John Hoppa

unread,
May 31, 2020, 12:07:05 PM5/31/20
to Raspberry Pi Film Capture
Hi Aden,
After failing a few attempts to redo Joe's code with a webcam and gstreamer on the raspberry pi I gave up on that approach.  However, I am now using Dominique Galland's  yart (https://github.com/dgalland/yart) with good results.  With a version 1 camera, an old 35mm enlarger lens reversed mounted, and Dominique's approach to cropping a region of interest in the center of the frame I'm able to produce 1296x976 images.  I received a new raspberry pi HQ camera yesterday and expect even better results.  Yart also has a very good motor control scheme and allows for image enhancement by applying a Mertens high definition process to the captured images.

In my quest for a webcam solution I came across "CineFrameCatcher" by Wolfgang Kurz at https://uwkurz.de/home/productsEN.html. which may be of some help to you.

All the best - John
Reply all
Reply to author
Forward
0 new messages