Re: [PATCH] drm: Add R10 and R12 FourCC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Simon,

On Thu, Oct 28, 2021 at 09:49:18PM +0000, Simon Ser wrote:
> > +/* 10 bpp Red */
> > +#define DRM_FORMAT_R10		fourcc_code('R', '1', '0', ' ') /* [15:0] x:R 6:10 little endian */
> > +
> > +/* 12 bpp Red */
> > +#define DRM_FORMAT_R12		fourcc_code('R', '1', '2', ' ') /* [15:0] x:R 4:12 little endian */
> 
> Are these codes arbitrary, or are they taken from somewhere else?
> 
> If they are arbitrary, maybe it'd be better to pick XR10 and XR12 instead of
> R10 and R12, to allow a future patch to add other format codes with the padding
> at the end if we ever need that.

They are arbitrary indeed, but modelled after DRM_FORMAT_R8 which used
'R8  '. As you've noticed, XR12 is already taken.

I don't think we'll need a format with padding at that end (with data
aligned to tbe MSB) as that would essentially be DRM_FORMAT_R16.

-- 
Regards,

Laurent Pinchart



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux