Hi Jacek, On 7 April 2014 18:46, Jacek Anaszewski <j.anaszewski@xxxxxxxxxxx> wrote: > Prevent decompression of a JPEG 4:2:0 with odd width to > the YUV 4:2:0 compliant formats for Exynos4x12 SoCs and > adjust capture format to RGB565 in such a case. This is > required because the configuration would produce a raw > image with broken luma component. > > Signed-off-by: Jacek Anaszewski <j.anaszewski@xxxxxxxxxxx> > Signed-off-by: Kyungmin Park <kyungmin.park@xxxxxxxxxxx> > --- <snip> > + if (ctx->subsampling == V4L2_JPEG_CHROMA_SUBSAMPLING_420 && > + (ctx->out_q.w & 1) && > + (pix->pixelformat == V4L2_PIX_FMT_NV12 || > + pix->pixelformat == V4L2_PIX_FMT_NV21 || > + pix->pixelformat == V4L2_PIX_FMT_YUV420)) { > + pix->pixelformat = V4L2_PIX_FMT_RGB565; > + fmt = s5p_jpeg_find_format(ctx, pix->pixelformat, > + FMT_TYPE_CAPTURE); > + v4l2_info(&ctx->jpeg->v4l2_dev, > + "Adjusted capture fourcc to RGB565. Decompression\n" > + "of a JPEG file with 4:2:0 subsampling and odd\n" > + "width to the YUV 4:2:0 compliant formats produces\n" > + "a raw image with broken luma component.\n"); This could be made a comment in the code rather than a info message. -- With warm regards, Sachin -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html