|
|
|
RE: Saving YUVY image from V4L2 buffer to file | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
Devin, Many thanks for the quick reply. Yes I'm getting some sort of an image. When I was experimenting I managed to get an image but in grayscale & showing multiple copies of the same image covering the top half of the image. I imagine it was distorted because I was not converting to RGB correctly. All the best, Owen > Date: Wed, 3 Feb 2010 12:54:02 -0500 > Subject: Re: Saving YUVY image from V4L2 buffer to file > From: dheitmueller@xxxxxxxxxxxxxx > To: oo_hehir@xxxxxxxxxxx > CC: video4linux-list@xxxxxxxxxx > > On Wed, Feb 3, 2010 at 12:40 PM, Owen O' Hehir <oo_hehir@xxxxxxxxxxx> wrote: > > > > Hello All, > > > > I'm trying to save a captured image from a USB camera to a file. The capture is based on V4L2 video capture example from the V4L2 API spec. http://v4l2spec.bytesex.org/spec/a16706.htm > > > > The V4L2 set pointers (via mmap) to to the USB image (in YUV 4:2:2 (YUYV)) and as far as I can see the simplest way to save the image in a recognised format is in RGB format, specifically in PPM (Netpbm color image format). > > > > As such I've expanded the process_image function: > > Independent of the conversion function, are you sure you are getting a > valid YUV frame at all? A completely green frame is what you will get > back if you had a buffer which was memset(0). Hence it's possible > that the data you are passing *into* your conversion function is > completely blank. > > Devin > > -- > Devin J. Heitmueller - Kernel Labs > http://www.kernellabs.com _________________________________________________________________ Hotmail: Powerful Free email with security by Microsoft. https://signup.live.com/signup.aspx?id=60969 -- video4linux-list mailing list Unsubscribe mailto:video4linux-list-request@xxxxxxxxxx?subject=unsubscribe https://www.redhat.com/mailman/listinfo/video4linux-list
[Linux Media] [Older V4L] [Linux DVB] [Video Disk Recorder] [Linux Kernel] [Asterisk] [Photo] [DCCP] [Netdev] [Xorg] [Util Linux NG] [Xfree86] [Free Photo Albums] [Fedora Users] [Fedora Women] [ALSA Users] [ALSA Devel] [SSH] [DVB Maintainers] [Linux USB] [Yosemite Information]
![]() |
![]() |