Ok, I was wrong:
2008/7/7 Marco Argiolas <[EMAIL PROTECTED]>:
> Well I really don't know,
> I think only Laurent (and those who know what "format 5" is) could help
> you.
>
The program was unable to set format V4L2_BUF_TYPE_VIDEO_CAPTURE, the number
5 was the error stored in "errno"! errno=5 corrisponds to EIO that is an
error in I/O..and I think it is not a good news!! :(
However this is the code where the error should happen:
/* set format in */
memset(&vd->fmt, 0, sizeof(struct v4l2_format));
vd->fmt.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
vd->fmt.fmt.pix.width = vd->width;
vd->fmt.fmt.pix.height = vd->height;
vd->fmt.fmt.pix.pixelformat = vd->formatIn;
vd->fmt.fmt.pix.field = V4L2_FIELD_ANY;
ret = ioctl(vd->fd, VIDIOC_S_FMT, &vd->fmt);
if (ret < 0) {
printf("Unable to set format: %d.\n", errno);
goto fatal;
}
At this point the only suggestion I can give you is to try the following
command with all the resolutions supported with your webcam (you can get a
list with "luvcview -L"):
luvcview -f yuv -s WIDTHxHEIGHT
Your webcam should support the followings:
width = 640, height = 480
width = 160, height = 120
width = 176, height = 144
width = 320, height = 240
width = 352, height = 288
width = 800, height = 600
width = 1024, height = 768
width = 1280, height = 800
width = 1280, height = 960
*width = 1280, height = 1024
Good luck!!!
Marco Argiolas
*
> You should download the sources of luvcview and try to understand what
> happens.
> Unluckly now I have no time for this.
>
> ps.
> please pay attenction in sending email also to UVC mailing list ;)
>
> 2008/7/7 erwin <[EMAIL PROTECTED]>:
>
>> Ok i tried the command luvcview -f yuv and finally i had an image but
>>
>> only a snapshot not a streaming and after 3 times a tried it happened
>> this:
>> [EMAIL PROTECTED]:~$ luvcview -f yuv
>> luvcview version 0.2.1
>> Video driver: x11
>> A window manager is available
>> video /dev/video0
>> Unable to set format: 5.
>> Init v4L2 failed !! exit fatal
>>
>> what do you think about?
>>
>> On Mon, 2008-07-07 at 08:20 +0200, Marco Argiolas wrote:
>> > luvcview -f yuv
>>
>
_______________________________________________
Linux-uvc-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/linux-uvc-devel