This is an automatic generated email to let you know that the following patch were queued at the http://git.linuxtv.org/v4l-utils.git tree:
Subject: libv4l1: Move VIDIOCSFBUF into libv4l1 Author: Huzaifa Sidhpurwala <huzai...@fedora-12.(none)> Date: Tue Jun 1 15:07:21 2010 +0530 Move VIDIOCSFBUF into libv4l1 and correct a missing break with the last commit Signed-Off-by: Huzaifa Sidhpurwala <[email protected]> Signed-Off-by: Hans de Goede <[email protected]> lib/libv4l1/libv4l1.c | 32 ++++++++++++++++++++++++++++++++ 1 files changed, 32 insertions(+), 0 deletions(-) --- http://git.linuxtv.org/v4l-utils.git?a=commitdiff;h=503bd7b7f8749fbe2869028ba569a202b9cb8cc6 diff --git a/lib/libv4l1/libv4l1.c b/lib/libv4l1/libv4l1.c index ac3c2d9..fa624b6 100644 --- a/lib/libv4l1/libv4l1.c +++ b/lib/libv4l1/libv4l1.c @@ -847,6 +847,38 @@ int v4l1_ioctl(int fd, unsigned long int request, ...) (buffer->width * buffer->depth + 7) & 7; buffer->bytesperline >>= 3; } + break; + } + + case VIDIOCSFBUF: { + struct video_buffer *buffer = arg; + struct v4l2_framebuffer fbuf = { 0, }; + + fbuf.base = buffer->base; + fbuf.fmt.height = buffer->height; + fbuf.fmt.width = buffer->width; + + switch (buffer->depth) { + case 8: + fbuf.fmt.pixelformat = V4L2_PIX_FMT_RGB332; + break; + case 15: + fbuf.fmt.pixelformat = V4L2_PIX_FMT_RGB555; + break; + case 16: + fbuf.fmt.pixelformat = V4L2_PIX_FMT_RGB565; + break; + case 24: + fbuf.fmt.pixelformat = V4L2_PIX_FMT_BGR24; + break; + case 32: + fbuf.fmt.pixelformat = V4L2_PIX_FMT_BGR32; + break; + } + + fbuf.fmt.bytesperline = buffer->bytesperline; + result = v4l2_ioctl(fd, VIDIOC_S_FBUF, &fbuf); + break; } default: _______________________________________________ linuxtv-commits mailing list [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits
