I wonder if there is code to copy that would help to capture screens of webcams, not the computer screens on desktop. I don't need individual snapshots, I need the whole dynamic process.
So you want to capture video from an actual camera?
Yes, there are libraries for this. There are also many programs that are under various free licenses that would do the job. You can look at their code and see what they are using (Though many fully fledged projects like that are going to be mixed language, or tend to use GObject which I just find frustrating)
VXL - similar idea to openCV, useful if your program is going to do some heavy processing on each image. Tutorial: Uh, there's an entire book, didn't find a short and simple tut. https://vxl.github.io/
Qt also has a webcam interface if you want video/picture and don't care too much about the overhead of the Qt framework itself. Tutorial: https://www.youtube.com/watch?v=aGubFhk_ALs
probably work better if you search stream capture instead of screen capture :)
a lot of this will be done for you in hardware, I would think.
the process in a nutshell is:
capture a still frame, encode/compress it into a stream
but you should be able to get it as a stream from the device. Once you have the stream, a library should let you make a video file or pass it on as a stream over a network or just display and discard, etc. Are you wanting to post-process or just save/display/forward the stream?
Thank you guys. I really appreciate it. Very helpful. So far I've used MFCaptureD3D project in MS C++ at Github but I really want to do it in Linux. MS C++ is too hard for me :-)