• Archit Taneja's avatar
    [media] v4l: ti-vpe: enable CSC support for VPE · 30496799
    Archit Taneja authored
    Use the csc library functions to configure the CSC block in VPE.
    
    Some changes are required in try_fmt to handle the pix->colorspace parameter
    more correctly. Previously, we copied the source queue colorspace to the
    destination queue colorspace as we didn't support RGB formats. Now, we configure
    pix->colorspace based on the color format set(and the height of the image if
    it's a YUV format).
    
    Add basic RGB color formats to the list of supported vpe formats.
    
    If the destination format is RGB colorspace, we also need to use the RGB output
    port instead of the Luma and Chroma output ports. This requires configuring the
    output data descriptors differently.
    
    Also, make the default colorspace V4L2_COLORSPACE_SMPTE170M as that resembles
    the Standard Definition colorspace more closely.
    Signed-off-by: default avatarArchit Taneja <archit@ti.com>
    Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
    Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
    30496799
vpe.c 55 KB