Lines Matching defs:fmtd
854 void *priv, struct v4l2_fmtdesc *fmtd)
856 switch (fmtd->index) {
858 fmtd->pixelformat = V4L2_PIX_FMT_RGB565;
861 fmtd->pixelformat = V4L2_PIX_FMT_RGB565X;
864 fmtd->pixelformat = V4L2_PIX_FMT_UYVY;
867 fmtd->pixelformat = V4L2_PIX_FMT_SBGGR8;
870 fmtd->pixelformat = V4L2_PIX_FMT_YUYV;
919 struct v4l2_format *fmtd, int *idx)
922 switch (fmtd->fmt.pix.pixelformat) {
933 if (fmtd->fmt.pix.width > stk_sizes[i].w)
937 || (abs(fmtd->fmt.pix.width - stk_sizes[i-1].w)
938 < abs(fmtd->fmt.pix.width - stk_sizes[i].w))) {
939 fmtd->fmt.pix.height = stk_sizes[i-1].h;
940 fmtd->fmt.pix.width = stk_sizes[i-1].w;
944 fmtd->fmt.pix.height = stk_sizes[i].h;
945 fmtd->fmt.pix.width = stk_sizes[i].w;
950 fmtd->fmt.pix.field = V4L2_FIELD_NONE;
951 fmtd->fmt.pix.colorspace = V4L2_COLORSPACE_SRGB;
952 if (fmtd->fmt.pix.pixelformat == V4L2_PIX_FMT_SBGGR8)
953 fmtd->fmt.pix.bytesperline = fmtd->fmt.pix.width;
955 fmtd->fmt.pix.bytesperline = 2 * fmtd->fmt.pix.width;
956 fmtd->fmt.pix.sizeimage = fmtd->fmt.pix.bytesperline
957 * fmtd->fmt.pix.height;
962 void *priv, struct v4l2_format *fmtd)
964 return stk_try_fmt_vid_cap(filp, fmtd, NULL);
1004 void *priv, struct v4l2_format *fmtd)
1018 ret = stk_try_fmt_vid_cap(filp, fmtd, &idx);
1022 dev->vsettings.palette = fmtd->fmt.pix.pixelformat;
1024 dev->frame_size = fmtd->fmt.pix.sizeimage;