[SOLVED] I found a camera. I wonder if I can make it work
Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: openSUSE, Raspbian, Slackware. Previous: MacOS, Red Hat, Coherent, Consensys SVR4.2, Tru64, Solaris
Posts: 2,820
Rep:
Quote:
Originally Posted by hazel
I'll try building wxcam; I just checked its sourceforge page and it doesn't seem to have any major desktop dependencies.
I've had pretty good experience building from sources via the SlackBuild instructions. (Trouble is I don't do it often enough so I'm always running back to the HOWTOs to relearn where things are supposed to go during the process.)
Quote:
I don't want to get involved with zoom.
I completely understand those who don't want to go the Zoom route. I originally started using Zoom it as a means to re-connect with some college friends a few years ago when we all got tired of trekking back to campus to meet up---plus we couldn't meet in-person because of the pandemic. (The meetup arranger used his college faculty account so we could get past the 45m time limit.) I use it now since I'm Windows-free (so no Skype/Teams unless employer supplies a laptop) and need to work with folks via video from time to time on projects Skype-for-Linux, or whatever it was called, was a dud.
Anyhoo... good luck on the SlackBuilding. Let us know how it goes.
I've had pretty good experience building from sources via the SlackBuild instructions. (Trouble is I don't do it often enough so I'm always running back to the HOWTOs to relearn where things are supposed to go during the process.)
They have guvcview as well. I remember using that once (I think on Dragora) and it was small and simple. It's gtk so no desktop dependencies. Maybe I'll try that one.
I thought you were going to use it for podcasts or youtube instructionals, so just as a thank you for your helpful posts and general support, I wouldn't mind donating you.
I never watch videos, but based on what I've heard about them here on LQ, your insights could easily gather a bunch of followers.
If you want anonymity, then all I would need is your paypal for transfer. You can then order yourself.
That is very sweet of you, but I have no intention of going on YouTube. I loathe social media. I think they are responsible for most of what's currently wrong in our society. And YouTube is particularly damaging to the Linux ecosystem. This forum is clogged up with posts from newbies who ran into a mild problem that they could easily have cleared up with a bit of advice from LQ members, but instead they watched and followed YouTube videos. They wrecked their system by doing things they didn't understand, recommended by people who probably don't know any more than they do. And then they come here and expect us to get them off the hook.
To me, this little eyeball (that's what it looks like) is a toy, that's all. I can use it to take the odd photo that I might need. I'm not going to make videos.
I can use it to take the odd photo that I might need. I'm not going to make videos.
That changed the scope of your question completely. Instead of playing back a previously created video and take a screenshot of it, it is possible to grab still images directly from a webcam feed. This way, you'll get a preview feed and pull the images when you are ready.
VLC will let you do this. Use its 'Open Video Capture' feature to run your webcam with, and then use its screenshot feature (the 'Take Snapshots' in VLC) to create your images with. It'll grab a H.264 frame still, turn it into jpg or png, and save it somewhere.
If you're not a fan of VLC, you can try using mpv to run a webcam feed (see teckk's post #7 for that). Upon getting a webcam feed, mpv will grab screenshots using its 's' shortcut. mplayer will also capture screenshots.
I also believe ffmpeg can output to a jpg/png image directly from a webcam feed (I'm most certain that it can) but I don't have a webcam handy to test with so the ffmpeg example below is untested (and it has no preview feed).
Please pardon my bluntness but you went overboard in GIMP in adjusting your image's contrast. There wasn't a whole lot of dynamic range in the image to begin with so it resulted in that overcooked look in your image. It would be better to adjust the exposure of the webcam directly. You did said that your images were white out in sunlight so that indicated to me the webcam's auto exposure was set too high. I realized you've mentioned that it's a toy webcam but perhaps you can manually control its exposure.
Again, I don't have a webcam to play with so I'm unable to test using v4l2-ctl to control its exposures with. It seems to me from my quick online search that one uses v4l2-ctl to adjust the webcam's exposures with. See the beginning of the script at this link for exposure examples: https://gist.github.com/justinledwar...ce611efc00346f
Try starting a live feed from your webcam and then enter in the v4l2-ctl commands to see if you are able to adjust its exposure with. Setting the webcam's ISO to its lowest would be a good start in resolving your overexposure.
Some commands available in default Slackware that I use in a terminal emulator for testing webcams:
Code:
# Show webcam video
mplayer tv://
# or specifying the device
mplayer -tv device=/dev/video0 tv://
# A more sophisticated alternative with access to settings
qv4l2
# Testing recording sound from internal microphone and webcam together
ffmpeg -f pulse -i default -itsoffset 00:00:00 -f video4linux2 -r 25 -i /dev/video0 -t 5 out.avi
I had a netbook that required tweaking with qv4l2 (this is the tool mentioned earlier by SW64) to get acceptable picture quality.
Please pardon my bluntness but you went overboard in GIMP in adjusting your image's contrast.
You needn't apologise. This is exactly the kind of advice I need. I told you at the outset that I know nothing at all about video or how to use a camera. The only one I've ever used was my father's old box camera which had no focus control and only two exposure settings.This one has a ring that you turn to focus but no other physical controls that I can see. It's obviously intended to be controlled entirely from the computer and I didn't have the tools for that.
On your advice, I've just installed alien's vlc and I've also built guvlc from Slackbuilds. That will give me plenty of stuff to experiment with. If I can get a better image, I'll post it.
Distribution: openSUSE, Raspbian, Slackware. Previous: MacOS, Red Hat, Coherent, Consensys SVR4.2, Tru64, Solaris
Posts: 2,820
Rep:
Quote:
Originally Posted by hazel
... but instead they watched and followed YouTube videos.
Ugh! When I'm researching something and the link winds up pointing to a video, my response is "Next link, please!". Most of the links to videos are to awful videos though there some decent ones out there. (I found Jeff Geerling's Ansible videos to be fairly good.)
There are people at work who believe that simply recording a screen session for coworkers to watch constitutes documenting a process (unedited, of course, so that the viewer gets to see all their typos and command line errors). I suspect they do this because they can't write.
I also believe ffmpeg can output to a jpg/png image directly from a webcam feed (I'm most certain that it can) but I don't have a webcam handy to test with so the ffmpeg example below is untested (and it has no preview feed).
Code:
ffmpeg -f v4l2 -i /dev/video0 out.jpg
Yes, that works. But you need to add -frames:v 1 before the output file name. ffmpeg itself told me that. It gives extraordinarily useful error messages, even by Linux standards.
This might also be useful to someone. It's Greek to me; I just copied it from a man page.
Code:
hazel@bigboy.localdomain:~ $ v4l2-ctl -d0 -D
Driver Info:
Driver name : STV06xx
Card type : Camera
Bus info : usb-0000:00:14.0-2
Driver version : 5.15.38
Capabilities : 0x85200001
Video Capture
Read/Write
Streaming
Extended Pix Format
Device Capabilities
Device Caps : 0x05200001
Video Capture
Read/Write
Streaming
Extended Pix Format
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.